1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 12:57:35 +00:00

Meta: Run Android CI via gradle wrapper instead of via CMake

This commit is contained in:
Andrew Kaster 2023-09-03 21:14:12 +02:00 committed by Tim Flynn
parent 0a05440220
commit 4e9dc127ae
3 changed files with 45 additions and 42 deletions

View file

@ -5,11 +5,13 @@ plugins {
id("org.jetbrains.kotlin.android")
}
var cacheDir = System.getenv("SERENITY_CACHE_DIR") ?: "$buildDir/caches"
// FIXME: Move this somewhere nicer, with better behavior (like controlling host compiler)
task<Exec>("buildLagomTools") {
commandLine = listOf("sh", "-c", "cmake -S ../../Meta/Lagom -B $buildDir/lagom-tools " +
" -Dpackage=LagomTools -DCMAKE_INSTALL_PREFIX=$buildDir/lagom-tools-install -GNinja" +
" -DSERENITY_CACHE_DIR=$buildDir/caches;" +
" -DSERENITY_CACHE_DIR=$cacheDir;" +
" ninja -C $buildDir/lagom-tools install")
}
tasks.named("preBuild").dependsOn("buildLagomTools")
@ -31,7 +33,7 @@ android {
cppFlags += "-std=c++20"
arguments += listOf(
"-DLagomTools_DIR=$buildDir/lagom-tools-install/share/LagomTools",
"-DSERENITY_CACHE_DIR=$buildDir/caches"
"-DSERENITY_CACHE_DIR=$cacheDir"
)
}
}