Update ccache config (#298)

This commit is contained in:
Kevin Li
2020-03-30 21:29:03 +08:00
committed by GitHub
parent dbace6a779
commit dbdc053db1
2 changed files with 2 additions and 5 deletions

View File

@@ -34,11 +34,6 @@ android {
buildConfigField "String", "MAPBOX_VERSION_STRING", String.format("\"Mapbox/%s\"", project.VERSION_NAME)
buildConfigField "String", "MAPBOX_EVENTS_USER_AGENT", String.format("\"mapbox-maps-android/%s\"", project.VERSION_NAME)
consumerProguardFiles 'proguard-rules.pro'
externalNativeBuild {
cmake {
arguments '-DANDROID_CCACHE=ccache'
}
}
}
// build native libraries

View File

@@ -44,6 +44,8 @@ ext.nativeBuild = { nativeTargets ->
// Enable ccache if the user has installed it.
if (file("/usr/bin/ccache").exists()) {
arguments "-DANDROID_CCACHE=/usr/bin/ccache"
} else if (file("/usr/local/bin/ccache").exists()) {
arguments "-DANDROID_CCACHE=/usr/local/bin/ccache"
}
cFlags "-Qunused-arguments"