Giter Site home page Giter Site logo

flutter_wayland's Introduction

Flutter Wayland

A Flutter Embedder that talks to Wayland.

Running in Weston

Build Setup Instructions

  • Install the following packages (on Debian Stretch): weston, libwayland-dev, cmake and ninja.
  • From the source root mkdir build and move into the directory.
  • cmake -G Ninja ../. This should check you development environment for required packages, download the Flutter engine artifacts and unpack the same in the build directory.
  • ninja to build the embedder.
  • Run the embedder using ./flutter_wayland. Make sure weston is running. See the instructions on running Flutter applications below.

Running Flutter Applications

Flutter Wayland Embedder
========================

Usage: `flutter_wayland <asset_bundle_path> <flutter_flags>`

This utility runs an instance of a Flutter application and renders using
Wayland core protocols.

The Flutter tools can be obtained at https://flutter.io/

asset_bundle_path: The Flutter application code needs to be snapshotted using
                   the Flutter tools and the assets packaged in the appropriate
                   location. This can be done for any Flutter application by
                   running `flutter build bundle` while in the directory of a
                   valid Flutter project. This should package all the code and
                   assets in the "build/flutter_assets" directory. Specify this
                   directory as the first argument to this utility.

    flutter_flags: Typically empty. These extra flags are passed directly to the
                   Flutter engine. To see all supported flags, run
                   `flutter_tester --help` using the test binary included in the
                   Flutter tools.

flutter_wayland's People

Contributors

chinmaygarde avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

flutter_wayland's Issues

run flutter failed

I have build your project successfully, the flutter_wayland is runing ok, when I add the asset path, the error happened,
flutter doctor with no errors!

Engine run configuration was invalid
Could not launch the engine with configuration.

the weston is running when I do flutter_wayland operation.
any suggestions?

Ideas for better performance

The repo does seem to be a bit outdated when it comes to the latest flutter_embedder.h capability.

I'm wondering what can be done to increase performance with this embedder, such as replacing __FlutterEngineFlushPendingTasksNow with something else I assume?

What is the procedure to support native plugin using flutter_wayland embedder ?

Hello,

As we know that for native plugins, the supported platforms are android, ios, web, linux, macos, and windows.
Can we support native plugins for any other embedded system also ? Because we need to execute apps (with package/plugin like media player etc.) using flutter_wayland embedder so please guide us towards the same as we are new to this.

Thanks,

How do I run release version of flutter apps ?

I would like to measure the memory taken for an Flutter app in release mode.
First verified that debug build works fine, then attempted to build release version of the app, but it failed to run. I think the root cause being kernel_blob.bin is deleted in release mode.

flutter build bundle --release

after this I see that flutter_assets/kernel_blob.bin file is deleted.

wayland embedder fails to run if this file is missing.

error reported
ERROR: ../utils.cc:56: Kernel blob does not exist.
   <Invalid Flutter Asset Bundle>   
Flutter Wayland Embedder
========================
Usage: `wayland_embedder_meson <asset_bundle_path> <flutter_flags>`
This utility runs an instance of a Flutter application and renders using
Wayland core protocols.

The Flutter tools can be obtained at https://flutter.io/

asset_bundle_path: The Flutter application code needs to be snapshotted using
                   the Flutter tools and the assets packaged in the appropriate
                   location. This can be done for any Flutter application by
                   running `flutter build bundle` while in the directory of a
                   valid Flutter project. This should package all the code and
                   assets in the "build/flutter_assets" directory. Specify this
                   directory as the first argument to this utility.

    flutter_flags: Typically empty. These extra flags are passed directly to the
                   Flutter engine. To see all supported flags, run
                   `flutter_tester --help` using the test binary included in the
                   Flutter tools.

Only for 64bits?

Hello,
please confirm me that the project is only for 64bits systems.
I found the download for 64bits machine in CMakeLists:

...
set(FLUTTER_ENGINE_SHA b9523318caa1a99ffde8adaf331212eb879cabc9)

set(FLUTTER_EMBEDDER_ARTIFACTS_ZIP ${CMAKE_BINARY_DIR}/flutter_embedder_${FLUTTER_ENGINE_SHA}.zip)
set(FLUTTER_ARTIFACTS_ZIP          ${CMAKE_BINARY_DIR}/flutter_artifact_${FLUTTER_ENGINE_SHA}.zip)
set(FLUTTER_BUCKET_BASE "https://storage.googleapis.com/flutter_infra/flutter")

# Download and setup the Flutter Engine.
if(NOT EXISTS ${FLUTTER_EMBEDDER_ARTIFACTS_ZIP})
  file(DOWNLOAD
    ${FLUTTER_BUCKET_BASE}/${FLUTTER_ENGINE_SHA}/linux-x64/linux-x64-embedder
    ${FLUTTER_EMBEDDER_ARTIFACTS_ZIP}
...

Is it possible for 32bits machine? (Tinkerboard)
Thanks

"sudo cmake -G Ninja ../" runs forever

Hello,

I've run sudo cmake -G Ninja .. command on my RPi 4 and it probably hunged because it doesn't produce any output for the whole night (I left my RPi4 to process this command for the night = ~8 hours).

Anybody knows what could be wrong?

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.