File tree Expand file tree Collapse file tree 4 files changed +17
-14
lines changed
android-database-sqlcipher Expand file tree Collapse file tree 4 files changed +17
-14
lines changed Original file line number Diff line number Diff line change 77 $(GRADLE ) clean
88
99distclean :
10- $(GRADLE ) distclean
10+ $(GRADLE ) distclean \
11+ -PsqlcipherRoot=" $( SQLCIPHER_ROOT) "
1112
1213build-openssl :
1314 $(GRADLE ) buildOpenSSL
@@ -18,16 +19,19 @@ check:
1819format :
1920 $(GRADLE ) editorconfigFormat
2021
21- build-debug : check
22+ build-debug :
2223 $(GRADLE ) android-database-sqlcipher:bundleDebugAar \
23- -PdebugBuild=true
24+ -PdebugBuild=true \
25+ -PsqlcipherRoot=" $( SQLCIPHER_ROOT) " \
26+ -PopensslRoot=" $( OPENSSL_ROOT) " \
27+ -PsqlcipherCFlags=" $( SQLCIPHER_CFLAGS) " \
28+ -PsqlcipherAndroidClientVersion=" $( SQLCIPHER_ANDROID_VERSION) "
2429
2530build-release :
2631 $(GRADLE ) android-database-sqlcipher:bundleReleaseAar \
2732 -PdebugBuild=false \
2833 -PsqlcipherRoot=" $( SQLCIPHER_ROOT) " \
2934 -PopensslRoot=" $( OPENSSL_ROOT) " \
30- -PopensslAndroidLibRoot=" $( OPENSSL_ANDROID_LIB_ROOT) " \
3135 -PsqlcipherCFlags=" $( SQLCIPHER_CFLAGS) " \
3236 -PsqlcipherAndroidClientVersion=" $( SQLCIPHER_ANDROID_VERSION) "
3337
Original file line number Diff line number Diff line change @@ -144,7 +144,6 @@ SQLCIPHER_ROOT=/some/path/to/sqlcipher-folder \
144144OPENSSL_ROOT=/some/path/to/openssl-folder \
145145SQLCIPHER_ANDROID_VERSION="4.4.3" \
146146SQLCIPHER_CFLAGS="-DSQLITE_HAS_CODEC" \
147- OPENSSL_ANDROID_LIB_ROOT=/some/path/for/android/native/lib/creation \
148147make build-release
149148```
150149
Original file line number Diff line number Diff line change @@ -11,6 +11,10 @@ task buildOpenSSL() {
1111 return ! armNativeFile. exists()
1212 }
1313 doLast {
14+ def nativeRootDirectory = new File (" ${ androidNativeRootDir} " )
15+ if (! nativeRootDirectory. exists()){
16+ nativeRootDirectory. mkdirs()
17+ }
1418 exec {
1519 workingDir " ${ projectDir} "
1620 commandLine " ./build-openssl-libraries.sh" ,
@@ -79,13 +83,13 @@ task buildNative() {
7983}
8084
8185task cleanOpenSSL () {
82- description " Clean the OpenSSL source "
86+ description " Clean the OpenSSL native libraries "
8387 doLast {
84- logger. info " Cleaning OpenSSL source "
88+ logger. info " Cleaning OpenSSL native libraries "
8589 exec {
86- workingDir " ${ opensslDir } "
90+ workingDir " ${ androidNativeRootDir } "
8791 ignoreExitValue true
88- commandLine " make " , " clean "
92+ commandLine " rm " , " -rf "
8993 }
9094 }
9195}
Original file line number Diff line number Diff line change 6767 if (project. hasProperty(' sqlcipherRoot' )) {
6868 sqlcipherDir = " ${ sqlcipherRoot} "
6969 }
70- if (project. hasProperty(' opensslAndroidLibRoot' )) {
71- androidNativeRootDir = " ${ opensslAndroidLibRoot} "
72- } else {
73- androidNativeRootDir = " ${ nativeRootOutputDir} /external/android-libs"
74- }
70+ androidNativeRootDir = " ${ nativeRootOutputDir} /external/android-libs"
7571 if (project. hasProperty(' opensslRoot' )) {
7672 opensslDir = " ${ opensslRoot} "
7773 }
You can’t perform that action at this time.
0 commit comments