From 9524174d1399065071f052a428a5bfc17496a182 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Janiszewski?= Date: Mon, 11 Mar 2024 20:52:17 +0100 Subject: [PATCH 1/2] Use v14 images in CI Fixes #19409 --- .github/workflows/ci.yml | 18 +++++++++--------- .../app/src/main/CMakeLists.txt | 6 ++---- 2 files changed, 11 insertions(+), 13 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 98bc007a5a..b639e83628 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -156,7 +156,7 @@ jobs: name: Windows (${{ matrix.platform_name }}) using mingw runs-on: ubuntu-latest needs: check-code-formatting - container: openrct2/openrct2-build:13-mingw + container: openrct2/openrct2-build:14-mingw strategy: fail-fast: false matrix: @@ -305,19 +305,19 @@ jobs: # For focal the debug information still takes too much space, so reduce amount of debug info to minimum using `-g1` (`-g` means `-g2`), which is enough for backtraces only. - platform: x86_64 distro: focal - image: openrct2/openrct2-build:13-focal + image: openrct2/openrct2-build:14-focal build_flags: -DCMAKE_POSITION_INDEPENDENT_CODE=on -DCMAKE_CXX_FLAGS="-g1 -gz" -DWITH_TESTS=off - platform: x86_64 distro: jammy - image: openrct2/openrct2-build:13-jammy + image: openrct2/openrct2-build:14-jammy build_flags: -DCMAKE_POSITION_INDEPENDENT_CODE=on -DCMAKE_CXX_FLAGS="-g -gz -fno-var-tracking-assignments" - platform: x86_64 distro: bullseye - image: openrct2/openrct2-build:13-bullseye + image: openrct2/openrct2-build:14-bullseye build_flags: -DCMAKE_POSITION_INDEPENDENT_CODE=on -DCMAKE_CXX_FLAGS="-g -gz -fno-var-tracking-assignments" -DWITH_TESTS=off - platform: i686 distro: focal - image: openrct2/openrct2-build:13-focal32 + image: openrct2/openrct2-build:14-focal32 build_flags: -DFORCE32=ON -DENABLE_SCRIPTING=OFF -DCMAKE_CXX_FLAGS="-m32 -g1 -gz" -DWITH_TESTS=off steps: - name: Checkout @@ -356,7 +356,7 @@ jobs: name: Linux (x86_64, AppImage) runs-on: ubuntu-latest needs: check-code-formatting - container: openrct2/openrct2-build:13-focal + container: openrct2/openrct2-build:14-focal steps: - name: Checkout uses: actions/checkout@v4 @@ -414,7 +414,7 @@ jobs: name: Linux (Debug, [http, network, flac, vorbis OpenGL] disabled) using clang runs-on: ubuntu-latest needs: check-code-formatting - container: openrct2/openrct2-build:13-jammy + container: openrct2/openrct2-build:14-jammy steps: - name: Checkout uses: actions/checkout@v4 @@ -430,7 +430,7 @@ jobs: name: Linux (Debug) using clang, coverage enabled runs-on: ubuntu-latest needs: check-code-formatting - container: openrct2/openrct2-build:13-jammy + container: openrct2/openrct2-build:14-jammy steps: - name: Checkout uses: actions/checkout@v4 @@ -471,7 +471,7 @@ jobs: name: Android runs-on: ubuntu-latest needs: check-code-formatting - container: openrct2/openrct2-build:13-android + container: openrct2/openrct2-build:14-android steps: - name: Checkout uses: actions/checkout@v4 diff --git a/src/openrct2-android/app/src/main/CMakeLists.txt b/src/openrct2-android/app/src/main/CMakeLists.txt index 8c8327e36c..54b77f329c 100644 --- a/src/openrct2-android/app/src/main/CMakeLists.txt +++ b/src/openrct2-android/app/src/main/CMakeLists.txt @@ -198,7 +198,5 @@ target_include_directories(openrct2-ui PRIVATE "${ORCT2_ROOT}/src") target_include_directories(openrct2-ui SYSTEM PRIVATE "${ORCT2_ROOT}/src/thirdparty") target_include_directories(openrct2-cli PRIVATE "${ORCT2_ROOT}/src") -# Header-only nlohmann library is installed in CI images at /nlohmann. -# To be tiny bit more specific, use '/nlohmann/../' instead of just '/' -target_include_directories(openrct2 PRIVATE "/nlohmann/../") -target_include_directories(openrct2-ui PRIVATE "/nlohmann/../") +target_include_directories(openrct2 PRIVATE "/opt/openrct2/include/nlohmann/../") +target_include_directories(openrct2-ui PRIVATE "/opt/openrct2/include/nlohmann/../") From 5c00047bd15d14ff19853406972809c0ec6f50a5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Janiszewski?= Date: Mon, 11 Mar 2024 20:59:03 +0100 Subject: [PATCH 2/2] Sync android project with docker build image --- src/openrct2-android/app/build.gradle | 4 ++-- src/openrct2-android/build.gradle | 2 +- src/openrct2-android/gradle.properties | 3 ++- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/openrct2-android/app/build.gradle b/src/openrct2-android/app/build.gradle index 5e8073f5e1..fbd7d4b853 100644 --- a/src/openrct2-android/app/build.gradle +++ b/src/openrct2-android/app/build.gradle @@ -1,13 +1,13 @@ apply plugin: 'com.android.application' android { - compileSdkVersion 31 + compileSdk 34 buildToolsVersion "34.0.0" ndkVersion "26.2.11394342" // Latest r26c (LTS), to be synced with CI container image namespace "io.openrct2" defaultConfig { applicationId 'io.openrct2' - minSdkVersion 19 + minSdkVersion 21 targetSdkVersion 28 versionCode 2 diff --git a/src/openrct2-android/build.gradle b/src/openrct2-android/build.gradle index d748ef16df..01f316eecb 100644 --- a/src/openrct2-android/build.gradle +++ b/src/openrct2-android/build.gradle @@ -6,7 +6,7 @@ buildscript { google() } dependencies { - classpath 'com.android.tools.build:gradle:8.3.0-alpha10' + classpath 'com.android.tools.build:gradle:8.3.0' // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files diff --git a/src/openrct2-android/gradle.properties b/src/openrct2-android/gradle.properties index fa2c20f971..e37f08064c 100644 --- a/src/openrct2-android/gradle.properties +++ b/src/openrct2-android/gradle.properties @@ -16,6 +16,7 @@ # This option should only be used with decoupled projects. More details, visit # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects # org.gradle.parallel=true -android.enableJetifier=true +android.enableJetifier=false android.useAndroidX=true +org.gradle.configuration-cache=true org.gradle.jvmargs=-Xmx4096m