Whoa. Apps are running on android. Switched to a static build of OpenSSL 1.1.1t for simplicity.
git-svn-id: https://www.unprompted.com/svn/projects/tildefriends/trunk@4211 ed5197a5-7fde-0310-b194-c3ffbd925b24
This commit is contained in:
18
Makefile
18
Makefile
@ -57,7 +57,9 @@ $(ANDROID_TARGETS): CFLAGS += \
|
||||
$(ANDROID_TARGETS): LDFLAGS += \
|
||||
-target $(ANDROID_NDK_TARGET_TRIPLE)$(ANDROID_NDK_API_VERSION) \
|
||||
-Ldeps/openssl/android/arm64-v8a/usr/local/lib \
|
||||
-llog
|
||||
-llog \
|
||||
-lssl \
|
||||
-lcrypto
|
||||
|
||||
ifeq ($(UNAME_M),x86_64)
|
||||
debug: CFLAGS += -fsanitize=address -fsanitize=undefined -fno-common
|
||||
@ -345,7 +347,6 @@ $(ANDROID_TARGETS): LDFLAGS += \
|
||||
-ldl \
|
||||
-lssl \
|
||||
-lcrypto \
|
||||
-shared \
|
||||
-fPIC
|
||||
|
||||
unix: debug release
|
||||
@ -372,7 +373,13 @@ define build_rules
|
||||
$(1): $(BUILD_DIR)/$(1)/$(if $(filter android%,$(1)),lib)$(PROJECT)$(if $(filter win%,$(1)),.exe)$(if $(filter android%,$(1)),.so)
|
||||
.PHONY: $(1)
|
||||
|
||||
$(BUILD_DIR)/$(1)/$(if $(filter android%,$(1)),lib)$(PROJECT)$(if $(filter win%,$(1)),.exe)$(if $(filter android%,$(1)),.so): $(filter $(BUILD_DIR)/$(1)/%,$(ALL_APP_OBJS))
|
||||
ifeq ($(filter android%,$(1)),$(1))
|
||||
$(BUILD_DIR)/$(1)/lib$(PROJECT).so: $(filter $(BUILD_DIR)/$(1)/%,$(ALL_APP_OBJS))
|
||||
@echo [link] $$@
|
||||
@$$(CC) -o $$@ $$^ $$(LDFLAGS) -shared
|
||||
endif
|
||||
|
||||
$(BUILD_DIR)/$(1)/$(PROJECT)$(if $(filter win%,$(1)),.exe): $(filter $(BUILD_DIR)/$(1)/%,$(ALL_APP_OBJS))
|
||||
@echo [link] $$@
|
||||
@$$(CC) -o $$@ $$^ $$(LDFLAGS)
|
||||
|
||||
@ -417,12 +424,11 @@ PACKAGE_DIRS := \
|
||||
|
||||
RAW_FILES := $(shell find $(PACKAGE_DIRS) -type f)
|
||||
|
||||
out/TildeFriends.unsigned.apk: out/apk/classes.dex out/androiddebug/libtildefriends.so $(RAW_FILES)
|
||||
out/TildeFriends.unsigned.apk: out/apk/classes.dex out/androiddebug/tildefriends out/androiddebug/libtildefriends.so $(RAW_FILES)
|
||||
@mkdir -p $(dir $@) out/apk/lib/arm64-v8a/
|
||||
@echo [aapt] $@
|
||||
@cp out/androiddebug/tildefriends out/apk/lib/arm64-v8a/
|
||||
@cp out/androiddebug/libtildefriends.so out/apk/lib/arm64-v8a/
|
||||
@cp deps/openssl/android/arm64-v8a/usr/local/lib/libssl.so out/apk/lib/arm64-v8a/
|
||||
@cp deps/openssl/android/arm64-v8a/usr/local/lib/libcrypto.so out/apk/lib/arm64-v8a/
|
||||
@$(ANDROID_BUILD_TOOLS)/aapt package -f -M src/android/AndroidManifest.xml -S src/android/res/ -I $(ANDROID_PLATFORM)/android.jar -F $@ out/apk/
|
||||
@zip -u $@ -q -r $(PACKAGE_DIRS)
|
||||
|
||||
|
Reference in New Issue
Block a user