-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
37 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
#!/bin/bash | ||
if [ ! -d /app/godot/android/ ] | ||
then | ||
echo "Checkout godot android" | ||
git clone https://github.com/decentraland/godot-explorer-android-template /app/godot/android | ||
fi | ||
|
||
echo "Build for Linux x86_64" | ||
cd /app/rust/xtask | ||
cargo run -- install | ||
cargo run -- run --only-build | ||
|
||
echo "Copy export templates" | ||
mkdir -p /root/.local/share/godot/export_templates/4.2.stable/ | ||
|
||
|
||
echo "Build for Android" | ||
cd /app/rust/decentraland-godot-lib | ||
./android-build.sh | ||
|
||
echo "Setup Android Debug Keys" | ||
cd /opt/ | ||
keytool -keyalg RSA -genkeypair -alias androiddebugkey \ | ||
-keypass android -keystore debug.keystore -storepass android \ | ||
-dname "CN=Android Debug,O=Android,C=US" -validity 9999 -deststoretype pkcs12 | ||
|
||
export GODOT_ANDROID_KEYSTORE_DEBUG_PATH=/opt/debug.keystore | ||
export GODOT_ANDROID_KEYSTORE_DEBUG_USER=androiddebugkey | ||
export GODOT_ANDROID_KEYSTORE_DEBUG_PASSWORD=android | ||
|
||
echo "Export Godot APK" | ||
cd /app/godot/ | ||
/app/.bin/godot/godot4_bin \ | ||
-e --headless --rendering-driver opengl3 --headless \ | ||
--export-debug Android /app/android.apk | ||
|
||
ls -la | grep android.apk |