Git Product home page Git Product logo

impeller-cmake-example's Introduction

impeller-cmake Example Project

Supported build environments

This CMake project compiles parts of Flutter Engine, including Impeller's renderer layer and FML. The Flutter Engine codebase only supports building against Clang.

Windows

This repository is tested against the x64 Native Tools Command Prompt for VS 2022.

macOS

This repository is tested against Homebrew Clang 13.0.0, which ships with the homebrew llvm package.

SteamDeck (ArchLinux)

Note: Don't do this unless you're comfortable with restoring if things go wrong.

# Set a password for the user.
passwd

# Disable filesystem read-only mode.
sudo btrfs property set -ts / ro false

# Install archlinux maintainer public keys.
sudo pacman-key --init
sudo pacman-key --populate archlinux

# Install build dependencies.
sudo pacman -Sy cmake
# The following dependencies should already be installed on the SteamDeck,
# but they need to be reinstalled in order to populate missing headers.
sudo pacman -Sy mesa libglvnd xorgproto libxrandr libxinerama libxcursor libxi libxext gcc linux-api-headers libx11 libxrender libxfixes

Fetching dependencies

  1. Clone the repository and fetch submodules:

    git clone [email protected]:bdero/impeller-cmake-example.git --recursive
  2. Fetch non-submodule dependencies:

    cd impeller-cmake-example
    ./deps.sh

Developing with vscode

This repository contains configuration to make working with vscode easy out of the box (.vscode/settings.json and CMakePresets.json).

Note that ubiquitous tools like cmake and clangd do all of the heavy lifting here, and getting a good code completion/navigation experience is possible for any editor with clangd support (Emacs, Sublime, etc).

  1. Get clang:

    • Windows: Install Visual Studio 2022 and open the x64 Native Tools Command Prompt for VS 2022
    • macOS: Download LLVM (homebrew: brew install llvm)
  2. Install recommended vscode extensions:

    • CMake Tools (build using CMake presets)
    • clangd (accurate code completion and navigation)
  3. Open the root directory of this repository in vscode:

    code impeller-cmake-example
  4. Configure CMake (bottom bar).

    1. Select the active configure preset:
      • Windows: Ninja Debug VS2022
      • macOS: Ninja Debug
    2. Set the active build preset to Example debug.
    3. Set the default target to example.
  5. Build/debug/run and enjoy!

impeller-cmake-example's People

Contributors

bdero avatar iamralpht avatar zanderso avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.