Linux (x86_64 or arm64)
The following dependencies are required: setools lzip wine patchelf e2fsprogs aria2 python3 attr
The following components need to be installed using winetricks
: msxml6
The python3 library requests
is used.
Python version ≥ 3.7.
Recommended Use
Ubuntu (You can use WSL2)
Ready to use right out of the box.
Debian (You can use WSL2)
Need to add contrib
sources to the source list to install winetricks.
OpenSUSE (You can use WSL2)
Ready to use right out of the box.
run.sh
will handle all dependencies automatically.
No need to type any commands.
Other Distributions
Install the dependencies manually.
Use the command-line program build.sh
.
cd scripts
./build.sh --help
(optional) to get the usage if you want to use CLI../run.sh
under scripts directory.OpenGApps
Select the OpenGApps variant you like.
MindTheGapps
There is no other variant we can choose.
output
and download
will be generated in the MagiskOnWSALocal
folder. Go to the output
folder. While running the ./run.sh
script in the step 3, if you selected Yes
for Do you want to compress the output?
then in output
folder you will see a compressed file called WSA-with-magisk-stable-MindTheGapps_2207.40000.8.0_x64_Release-Nightly
or else there will be folder with the WSA-with-magisk-stable-MindTheGapps_2207.40000.8.0_x64_Release-Nightly
. If there is a folder open it and skip to step 10. NOTE: The name of compressed file or the folder generated in the output
folder may be different for you. It will be dependent on the choices made when executing ./run.sh
Run.bat
and run it.
%LOCALAPPDATA%\Packages\MicrosoftCorporationII.WindowsSubsystemForAndroid_8wekyb3d8bbwe\LocalCache\userdata.vhdx
before uninstallation and restore it after installation.)Install.ps1
as administrator:
Win+x
and select Windows Terminal (Admin)
cd "{X:\path\to\your\extracted\folder}"
and press enter
, and remember to replace {X:\path\to\your\extracted\folder}
including the {}
, for example cd "D:\wsa"
PowerShell.exe -ExecutionPolicy Bypass -File .\Install.ps1
and press enter
Can I delete the installed folder?
No.
How can I update WSA to a new version?
Delete the download
folder
Rerun the script, replace the content of your previous installation and rerun Install.ps1
. Don't worry, your data will be preserved.
How can I get the logcat from WSA?
%LOCALAPPDATA%\Packages\MicrosoftCorporationII.WindowsSubsystemForAndroid_8wekyb3d8bbwe\LocalState\diagnostics\logcat
How can I update Magisk to a new version?
Do the same as updating WSA
How to pass safetynet?
Like all the other emulators, no way.
Virtualization is not enabled?
Install.ps1
helps you enable it if not enabled. After rebooting, rerun Install.ps1
to install WSA. If it's still not working, you have to enable virtualization in BIOS. That's a long story so ask Google for help.
How to remount the system as read-write?
No way in WSA since it's mounted as read-only by Hyper-V. You can modify the system by making a Magisk module. Or directly modify the system.img. Ask Google for help.
I cannot adb connect localhost:58526
Make sure developer mode is enabled. If the issue persists, check the IP address of WSA on the setting page and try adb connect ip:5555
.
Magisk online module list is empty?
Magisk actively removes the online module repository. You can install the module locally or by adb push module.zip /data/local/tmp
and adb shell su -c magisk --install-module /data/local/tmp/module.zip
.
Can I use Magisk 23.0 stable or a lower version?
No. Magisk has bugs preventing itself from running on WSA. Magisk 24+ has fixed them. So you must use Magisk 24 or higher version.
How can I get rid of Magisk?
Choose none
as the root solution.
How to install custom GApps?
Where can I download MindTheGapps?
You can download from here MindTheGapps (mirror)
Note that there is no x86_64 pre-build, so you need to build it by yourself (Repository).
Or you can download the built package for 12.1-x86_64 from this page.
Can I switch OpenGApps to MindTheGapps and keep user data in a previous build?
No. You should wipe data after changing the GApps brand. Otherwise, you will find that the installed GApps are not recognized.
su
for debugging Magisk IntegrationThe repository is provided as a utility.
Android is a trademark of Google LLC. Windows is a trademark of Microsoft LLC.