Skip to content

Commit

Permalink
android build fix
Browse files Browse the repository at this point in the history
  • Loading branch information
nesbox committed Aug 1, 2023
1 parent 059aa7e commit e7fbd51
Show file tree
Hide file tree
Showing 8 changed files with 36 additions and 32 deletions.
31 changes: 28 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -368,7 +368,11 @@ jobs:
- name: Prebuild
run: |
cd vendor/circle-stdlib
cd vendor
git clone --recursive https://github.com/smuehlst/circle-stdlib
cd circle-stdlib
git checkout fdb3c4a948421d47fddab8042a92f980cba43915
git submodule update --recursive
./configure -r 3
make -j$(nproc)
cd libs/circle/addon/vc4/sound/
Expand Down Expand Up @@ -424,7 +428,11 @@ jobs:
- name: Prebuild
run: |
cd vendor/circle-stdlib
cd vendor
git clone --recursive https://github.com/smuehlst/circle-stdlib
cd circle-stdlib
git checkout fdb3c4a948421d47fddab8042a92f980cba43915
git submodule update --recursive
./configure -r 4
make -j$(nproc)
cd libs/circle/addon/vc4/sound/
Expand Down Expand Up @@ -568,20 +576,37 @@ jobs:
# === Android ===
android:
runs-on: ubuntu-latest
container: nesbox/android-tic80:latest

steps:
- uses: actions/checkout@v3
with:
submodules: recursive
fetch-depth: 0

- uses: nttld/setup-ndk@v1
id: setup-ndk
with:
ndk-version: r21e
add-to-path: false
local-cache: true

- name: set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
cache: gradle

- name: Build
run: |
cd build/android
chmod +x gradlew
./gradlew assembleRelease
cp app/build/outputs/apk/release/app-release.apk tic80.apk
env:
ANDROID_NDK_HOME: ${{ steps.setup-ndk.outputs.ndk-path }}

- name: Deploy
uses: actions/upload-artifact@v3
with:
Expand Down
4 changes: 0 additions & 4 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,6 @@
path = vendor/argparse
url = https://github.com/cofyc/argparse.git
shallow = true
[submodule "vendor/circle-stdlib"]
path = vendor/circle-stdlib
url = https://github.com/smuehlst/circle-stdlib.git
shallow = true
[submodule "vendor/libuv"]
path = vendor/libuv
url = https://github.com/libuv/libuv.git
Expand Down
11 changes: 0 additions & 11 deletions build/android/Dockerfile

This file was deleted.

9 changes: 2 additions & 7 deletions build/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,11 @@ android {
externalNativeBuild {
ndkBuild {
arguments "APP_PLATFORM=android-31"
abiFilters 'armeabi-v7a', 'arm64-v8a', 'x86', 'x86_64'
abiFilters "arm64-v8a"
}
cmake {
arguments "-DBUILD_PRO=Off", "-DCMAKE_BUILD_TYPE=MinSizeRel"
arguments "-DBUILD_WITH_MRUBY=Off", "-DBUILD_PRO=Off", "-DCMAKE_BUILD_TYPE=MinSizeRel"
}
// cmake {
// arguments "-DANDROID_APP_PLATFORM=android-16", "-DANDROID_STL=c++_static"
// // abiFilters 'armeabi-v7a', 'arm64-v8a', 'x86', 'x86_64'
// abiFilters 'arm64-v8a'
// }
}
}

Expand Down
6 changes: 3 additions & 3 deletions build/android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@

buildscript {
repositories {
jcenter()
mavenCentral()
google()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.2.0'
classpath 'com.android.tools.build:gradle:7.0.3'

// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
Expand All @@ -15,7 +15,7 @@ buildscript {

allprojects {
repositories {
jcenter()
mavenCentral()
google()
}
}
Expand Down
Binary file modified build/android/gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
6 changes: 3 additions & 3 deletions build/android/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#Mon Oct 23 13:51:26 PDT 2017
#Thu Nov 11 18:20:34 PST 2021
distributionBase=GRADLE_USER_HOME
distributionUrl=https\://services.gradle.org/distributions/gradle-7.3-bin.zip
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.2-all.zip
zipStoreBase=GRADLE_USER_HOME
1 change: 0 additions & 1 deletion vendor/circle-stdlib
Submodule circle-stdlib deleted from fdb3c4

0 comments on commit e7fbd51

Please sign in to comment.