![]() ![]() This operation consumes too much memory (~90%).You cannot use " hot reload" features with flutter app because the process of deployment/running never finishes, however the package did be installed and running in your emulator, but for any changes in source code, you need re-run the app.VSCode (remote) can detect this connected device, but it cannot deploy correctly to emulator, so it's better to run the app on terminal.It takes a little longer to build/run the app for first time.Android toolchain - develop for Android devices (Android SDK version 29.0.3) Flutter (Channel stable, v1.17.5, on Linux, locale C.UTF-8) = Working with host's adb $ echo "export ADB_SERVER_SOCKET=tcp:192.168.0.29:5037" > ~/.bashrcĭoctor summary (to see all details, run flutter doctor -v): Open another terminal (don't close the previous ones) and run: > adb devices Open another terminal (don't close the previous one) and run: > emulator -avd generic_10 Open a terminal and check the status of port 5037: > netstat -aon|findstr 5037 IP Helper service uses that port (in my case), so I had to stop it. You can use any port with adb and emulator tools, but it is more simple if they manage it by themselves using their default ports. The rest of the steps are the same as in the Creating the emulator on WSL2 section, where ~ points out your home folder in Windows. To install Gradle in Windows, follow the instructions in this page. The steps to follow are basically the same as in the Installing Android SDK on WSL2 section, you can read this page for reference if any doubt. Get Command line tools for Android (Windows) only. ![]() > Get-NetIPAddress -AddressFamily IPv4 -InterfaceAlias Ethernet|findstr IPAddress > Get-ComputerInfo -Property "OsArchitecture" > Get-ComputerInfo -Property "OsBuildNumber" > Get-ComputerInfo -Property "WindowsVersion" = > Get-ComputerInfo -Property "WindowsProductName" $ echo "no" | avdmanager -verbose create avd -force -name "generic_10" -package "system-images android-29 google_apis x86" -tag "google_apis" -abi "x86"Īdd/Modify these lines in ~/.android/avd/generic_10.avd/config.ini file: skin.name=1080x1920Ĭheck emulator created: $ emulator -list-avds $ flutter config -android-sdk $ANDROID_SDK_ROOT $ echo "export PATH=$HOME/Programs/flutter/bin:$PATH" >. $ sdkmanager -install "cmdline-tools latest"Īccept all licenses. $ sdkmanager -install "system-images android-29 google_apis x86" "platform-tools" "platforms android-29" "build-tools 29.0.3" bashrc file: # AndroidĮxport ANDROID_SDK_ROOT=$HOME/Programs/AndroidĮxport PATH=$ANDROID_SDK_ROOT/cmdline-tools/tools:$PATHĮxport PATH=$ANDROID_SDK_ROOT/cmdline-tools/tools/bin:$PATHĮxport PATH=$ANDROID_SDK_ROOT/cmdline-tools/tools/lib:$PATHĮxport PATH=$ANDROID_SDK_ROOT/platform-tools:$PATHĮxport PATH=$ANDROID_SDK_ROOT/emulator:$PATHĮxport JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64 $ rm commandlinetools-linux-6609375_latest.zipĪppend the following lines to. ![]() $ unzip commandlinetools-linux-6609375_latest.zip $ sudo apt install -y lib32z1 default-jdk git unzip zip ![]() Get Command line tools for Android (Linux) only. => Note: The Dart SDK is bundled with Flutter Installing Android SDK $ echo "export PATH=\"/usr/lib/dart/bin:$PATH\"" > ~/.bashrcĭart VM version: 2.8.4 (stable) (Unknown timestamp) on "linux_圆4" $ sudo sh -c 'wget -qO- > /etc/apt//dart_stable.list' $ sudo apt-get install apt-transport-https Installing Dart $ sudo apt-get update & sudo apt-get upgrade It starts installing requirements for Android SDK (without installing Android Studio), Dart and Flutter, and it finalizes running a Flutter app on Windows host. This issue was a headache, so I wish to share my solution. ![]()
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |