diff --git a/docs/CrossCompile.md b/docs/CrossCompile.md new file mode 100644 index 0000000000..49a2774b04 --- /dev/null +++ b/docs/CrossCompile.md @@ -0,0 +1,10 @@ +# Cross Compile + +## ARM64 + +A painless guide for cross compilation (or to test NCE) from a x86_64 system without polluting your main. + +- Install QEMU: `sudo pkg install qemu` +- Download Debian 13: `wget https://cdimage.debian.org/debian-cd/current/arm64/iso-cd/debian-13.0.0-arm64-netinst.iso` +- Create a system disk: `qemu-img create -f qcow2 debian-13-arm64-ci.qcow2 30G` +- Run the VM: `qemu-system-aarch64 -M virt -m 2G -cpu max -bios /usr/local/share/qemu/edk2-aarch64-code.fd -drive if=none,file=debian-13.0.0-arm64-netinst.iso,format=raw,id=cdrom -device scsi-cd,drive=cdrom -drive if=none,file=debian-13-arm64-ci.qcow2,id=hd0,format=qcow2 -device virtio-blk-device,drive=hd0 -device virtio-gpu-pci -device usb-ehci -device usb-kbd -device intel-hda -device hda-output -nic user,model=virtio-net-pci` diff --git a/docs/README.md b/docs/README.md index e0c3054b71..9ce0857563 100644 --- a/docs/README.md +++ b/docs/README.md @@ -3,6 +3,7 @@ This contains documentation created by developers. This contains build instructions, guidelines, instructions/layouts for [cool stuff we made](./CPMUtil), and more. - **[General Build Instructions](Build.md)** +- **[Cross Compiling](CrossCompile.md)** - **[Development Guidelines](Development.md)** - **[Dependencies](Deps.md)** - **[Debug Guidelines](./Debug.md)** diff --git a/docs/build/Android.md b/docs/build/Android.md index f511f71370..5805ed2797 100644 --- a/docs/build/Android.md +++ b/docs/build/Android.md @@ -35,6 +35,8 @@ Eden by default will be cloned into - 6. To build the optimised build use `./gradlew assembleGenshinSpoofRelWithDebInfo`. 7. You can pass extra variables to cmake via `-PYUZU_ANDROID_ARGS="-D..."` +Remember to have a Java SDK installed if not already, on Debian and similar this is done with `sudo apt install openjdk-17-jdk`. + ### Script A convenience script for building is provided in `.ci/android/build.sh`. The built APK can be put into an `artifacts` directory via `.ci/android/package.sh`. On Windows, these must be done in the Git Bash or MinGW terminal.