Run Flutter on Termux !
bash -c "$(curl https://raw.githubusercontent.com/mumumusuc/termux-flutter/main/install)"
Important
the script will download latest release assets and clone flutter into your CURRENT directory
Before flutter run
please remember to install these dependencies and set DISPLAY
env.
apt install gtk3 fontconfig xorgproto ninja cmake clang pkg-config
export DISPLAY=:0
termux-x11 :0 >/dev/null 2>&1 &
Now create a project then run it.
flutter create hello_world && cd hello_world
flutter run
Open Termux:X11 and enjoy the flutter on Termux.
-
clone this repo or just download the
install.py
. -
download
dart-sdk.tar.gz
andengine.tar.gz
from release page. -
run
# flutter-3.13.6 as example $ git clone https://github.com/flutter/flutter -b 3.13.6 # install patched engine & dart-sdk $ path/to/install.py --engine path/to/engine.tar.gz --dart-sdk path/to/dart-sdk.tar.gz path/to/flutter # set flutter path $ export PATH=$PATH:$(pwd)/flutter/bin # install dependence $ apt install gtk3 fontconfig xorgproto ninja cmake clang pkg-config # create & run $ flutter create hello_world && cd hello_world $ export DISPLAY=:0 && termux-x11 :0 & $ flutter run
-
a video example using
fish
-
impeller3d
is enabled but it doesn't work withgtk3
currently. You can build aglfw
application usinglibflutter_engine.so
like this demo