Mercurial > 510Connectbot
comparison Makefile @ 493:0a17c6e7cb0f stable-1.9.4-3
improve Makefile
author | Carl Byington <carl@five-ten-sg.com> |
---|---|
date | Tue, 15 Feb 2022 14:07:00 -0800 |
parents | e88d48be89a8 |
children | 3feac274a27b |
comparison
equal
deleted
inserted
replaced
492:e88d48be89a8 | 493:0a17c6e7cb0f |
---|---|
3 | 3 |
4 na=$(shell find . -iname '*.c' -o -iname '*.h' -o -iname '*.cpp') | 4 na=$(shell find . -iname '*.c' -o -iname '*.h' -o -iname '*.cpp') |
5 style:=release | 5 style:=release |
6 dest:=../ASM/Installers | 6 dest:=../ASM/Installers |
7 ver:=$(shell grep versionName app/src/main/AndroidManifest.xml | cut -d'"' -f2) | 7 ver:=$(shell grep versionName app/src/main/AndroidManifest.xml | cut -d'"' -f2) |
8 apk:='app/build/outputs/apk/510Connectbot-$(ver).$(style).apk' | |
9 id:=$(shell hg id --id || echo 1) | 8 id:=$(shell hg id --id || echo 1) |
10 da:=$(shell date '+%Y-%m-%dT%H:%M:%S') | 9 da:=$(shell date '+%Y-%m-%dT%H:%M:%S') |
11 version:=\ | 10 version:=\ |
12 <?xml version=\"1.0\" encoding=\"utf-8\"?>\n\ | 11 <?xml version=\"1.0\" encoding=\"utf-8\"?>\n\ |
13 <resources>\n\ | 12 <resources>\n\ |
14 <string name=\"msg_version\" translatable=\"false\">510Connectbot $(ver) ($(id) $(da))</string>\n\ | 13 <string name=\"msg_version\" translatable=\"false\">510Connectbot $(ver) ($(id) $(da))</string>\n\ |
15 </resources>\n | 14 </resources>\n |
15 apk:=$(dest)/510Connectbot-$(ver).$(style).apk | |
16 signapk:=$(shell cat ~/.signapk) | |
16 | 17 |
17 ifeq ($(style),release) | 18 ifeq ($(style),release) |
18 task:=assembleArmRelease | 19 task:=assembleArmRelease |
19 debug:=0 | 20 debug:=0 |
20 else | 21 else |
21 task:=assembleArmDebug | 22 task:=assembleArmDebug |
22 debug:=1 | 23 debug:=1 |
24 signapk:= | |
23 endif | 25 endif |
24 | 26 |
25 fn:=app/src/main/java/com/five_ten_sg/connectbot/monitor/MonitorService.java | 27 fn:=app/src/main/java/com/five_ten_sg/connectbot/monitor/MonitorService.java |
26 | 28 |
27 all: | 29 all: |
28 hg pull; hg update | 30 make build.asm.packages |
29 make builder | |
30 | 31 |
31 builder: clean prep | 32 builder: clean prep |
32 ANDROID_HOME=/home/carl/Android/Sdk ANDROID_NDK_HOME=/home/carl/Android/Sdk/ndk-bundle ./gradlew $(task) | 33 #ANDROID_HOME=/home/carl/Android/Sdk ANDROID_NDK_HOME=/home/carl/Android/Sdk/ndk-bundle ./gradlew $(task) |
34 echo ./gradlew $(task) | |
35 @echo -e "$(signapk)\n$(signapk)" | ./gradlew $(task) | |
33 mv app/build/outputs/apk/arm/$(style)/app-arm-$(style).apk $(apk) | 36 mv app/build/outputs/apk/arm/$(style)/app-arm-$(style).apk $(apk) |
34 cp $(apk) $(dest) | |
35 ls -al $(dest) | |
36 | 37 |
37 clean: | 38 clean: |
38 rm -rf app/build/* | 39 rm -rf app/build/* |
39 rm -rf app/.externalNativeBuild || true | 40 rm -rf app/.externalNativeBuild || true |
40 | 41 |
119 internaldocs: | 120 internaldocs: |
120 doxygen | 121 doxygen |
121 | 122 |
122 | 123 |
123 build.asm.packages: | 124 build.asm.packages: |
125 make prep | |
124 make builder style=release | 126 make builder style=release |
125 hg revert --no-backup app/src/main/res/values/version.xml | |
126 # | |
127 make builder style=debug | 127 make builder style=debug |
128 hg revert --no-backup app/src/main/res/values/version.xml | |
129 | 128 |
130 # | 129 # |
131 # release procedure | 130 # release procedure |
132 # make any changes | 131 # make any changes |
133 # | |
134 # make prep | |
135 # hg commit -m 'commit message' | 132 # hg commit -m 'commit message' |
136 # make build.asm.packages | 133 # make build.asm.packages |