forked from sqlcipher/android-database-sqlcipher
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathMakefile
More file actions
108 lines (94 loc) · 3.2 KB
/
Copy pathMakefile
File metadata and controls
108 lines (94 loc) · 3.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
.POSIX:
.PHONY: init clean distclean build-openssl build publish-local-snapshot \
publish-local-release publish-remote-snapshot public-remote-release check
GRADLE = ./gradlew
NATIVE_LIBS_OUT_ROOT = ./android-database-sqlcipher/build/intermediates/stripped_native_libs/release/out
RELEASE_CLASSES_ROOT = ./android-database-sqlcipher/build/intermediates/javac/release/classes
clean:
$(GRADLE) clean
rm -rf lib net *.jar
distclean:
$(GRADLE) distclean \
-PsqlcipherRoot="$(SQLCIPHER_ROOT)"
rm -rf lib net *.jar
build-openssl:
$(GRADLE) buildOpenSSL
check:
$(GRADLE) check
format:
$(GRADLE) editorconfigFormat
build-debug:
$(GRADLE) android-database-sqlcipher:bundleDebugAar \
-PdebugBuild=true \
-PsqlcipherRoot="$(SQLCIPHER_ROOT)" \
-PopensslRoot="$(OPENSSL_ROOT)" \
-PopensslAndroidNativeRoot="$(OPENSSL_ANDROID_LIB_ROOT)" \
-PsqlcipherCFlags="$(SQLCIPHER_CFLAGS)" \
-PsqlcipherAndroidClientVersion="$(SQLCIPHER_ANDROID_VERSION)"
build-release:
$(GRADLE) android-database-sqlcipher:bundleReleaseAar \
-PdebugBuild=false \
-PsqlcipherRoot="$(SQLCIPHER_ROOT)" \
-PopensslRoot="$(OPENSSL_ROOT)" \
-PopensslAndroidNativeRoot="$(OPENSSL_ANDROID_LIB_ROOT)" \
-PsqlcipherCFlags="$(SQLCIPHER_CFLAGS)" \
-PsqlcipherAndroidClientVersion="$(SQLCIPHER_ANDROID_VERSION)"
cp -r $(NATIVE_LIBS_OUT_ROOT)/lib .
cp -r $(RELEASE_CLASSES_ROOT)/net .
jar cf android-database-sqlcipher.jar lib net
publish-local-snapshot:
@ $(collect-signing-info) \
$(GRADLE) \
-PpublishSnapshot=true \
-PpublishLocal=true \
-PsigningKeyId="$$gpgKeyId" \
-PsigningKeyRingFile="$$gpgKeyRingFile" \
-PsigningKeyPassword="$$gpgPassword" \
uploadArchives
publish-local-release:
@ $(collect-signing-info) \
$(GRADLE) \
-PpublishSnapshot=false \
-PpublishLocal=true \
-PsigningKeyId="$$gpgKeyId" \
-PsigningKeyRingFile="$$gpgKeyRingFile" \
-PsigningKeyPassword="$$gpgPassword" \
uploadArchives
publish-remote-snapshot:
@ $(collect-signing-info) \
$(collect-nexus-info) \
$(GRADLE) \
-PpublishSnapshot=true \
-PpublishLocal=false \
-PsigningKeyId="$$gpgKeyId" \
-PsigningKeyRingFile="$$gpgKeyRingFile" \
-PsigningKeyPassword="$$gpgPassword" \
-PnexusUsername="$$nexusUsername" \
-PnexusPassword="$$nexusPassword" \
uploadArchives
publish-remote-release:
@ $(collect-signing-info) \
$(collect-nexus-info) \
$(GRADLE) \
-PpublishSnapshot=false \
-PpublishLocal=false \
-PdebugBuild=false \
-PsigningKeyId="$$gpgKeyId" \
-PsigningKeyRingFile="$$gpgKeyRingFile" \
-PsigningKeyPassword="$$gpgPassword" \
-PnexusUsername="$$nexusUsername" \
-PnexusPassword="$$nexusPassword" \
-PsqlcipherRoot="$(SQLCIPHER_ROOT)" \
-PopensslRoot="$(OPENSSL_ROOT)" \
-PopensslAndroidLibRoot="$(OPENSSL_ANDROID_LIB_ROOT)" \
-PsqlcipherCFlags="$(SQLCIPHER_CFLAGS)" \
-PsqlcipherAndroidClientVersion="$(SQLCIPHER_ANDROID_VERSION)" \
android-database-sqlcipher:publish
collect-nexus-info := \
read -p "Enter Nexus username:" nexusUsername; \
stty -echo; read -p "Enter Nexus password:" nexusPassword; stty echo;
collect-signing-info := \
read -p "Enter GPG signing key id:" gpgKeyId; \
read -p "Enter full path to GPG keyring file \
(possibly ${HOME}/.gnupg/secring.gpg)" gpgKeyRingFile; \
stty -echo; read -p "Enter GPG password:" gpgPassword; stty echo;