diff options
author | Igor Cota <igor@openbook.hr> | 2020-08-28 11:09:58 +0200 |
---|---|---|
committer | Igor Cota <igor@openbook.hr> | 2021-03-21 22:33:27 +0100 |
commit | ebfb10cb75adb704418d08197681c1e742e63bd5 (patch) | |
tree | 8260d1138285ca49119ebad91f079a77cd487d99 /src/Makefile.qt.include | |
parent | d2a78ee9288e4d3bace9125bcfae6b7747f85982 (diff) |
Qt: add Android packaging support
Introduce an android directory under qt and allow one to package bitcoin-qt for Android by running make apk.
Add bitcoin-qt Android build instructions.
Diffstat (limited to 'src/Makefile.qt.include')
-rw-r--r-- | src/Makefile.qt.include | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/Makefile.qt.include b/src/Makefile.qt.include index 59cfdb9839..399a8430ef 100644 --- a/src/Makefile.qt.include +++ b/src/Makefile.qt.include @@ -378,6 +378,20 @@ bitcoin_qt_clean: FORCE bitcoin_qt : qt/bitcoin-qt$(EXEEXT) +APK_LIB_DIR = qt/android/libs/$(ANDROID_ARCH) +QT_BASE_PATH = $(shell find ../depends/sources/ -maxdepth 1 -type f -regex ".*qtbase.*\.tar.xz") +QT_BASE_TLD = $(shell tar tf $(QT_BASE_PATH) --exclude='*/*') + +bitcoin_qt_apk: FORCE + mkdir -p $(APK_LIB_DIR) + cp $(dir $(CC))../sysroot/usr/lib/$(host_alias)/libc++_shared.so $(APK_LIB_DIR) + tar xf $(QT_BASE_PATH) -C qt/android/src/ $(QT_BASE_TLD)src/android/jar/src --strip-components=5 + tar xf $(QT_BASE_PATH) -C qt/android/src/ $(QT_BASE_TLD)src/android/java/src --strip-components=5 + tar xf $(QT_BASE_PATH) -C qt/android/res/ $(QT_BASE_TLD)src/android/java/res --strip-components=5 + cp qt/bitcoin-qt $(APK_LIB_DIR)/libbitcoin-qt.so + cd qt/android && gradle wrapper --gradle-version=6.6.1 + cd qt/android && ./gradlew build + ui_%.h: %.ui @test -f $(UIC) @$(MKDIR_P) $(@D) |