Update android-*-qt5 to 5.15.1
This commit is contained in:
parent
1340f3ecd7
commit
b61be26214
|
@ -30,7 +30,7 @@ for pkgbuild_file in "${PKGBUILD_DIR:-.}"/*/*/PKGBUILD; do
|
||||||
# skip if version doesn't differ
|
# skip if version doesn't differ
|
||||||
source "$pkgbuild_file"
|
source "$pkgbuild_file"
|
||||||
[[ $version == $pkgver ]] && continue
|
[[ $version == $pkgver ]] && continue
|
||||||
pattern='(android|apple-darwin)-.*'
|
pattern='(apple-darwin-.*|android-.*-(c\+\+utilities|qtutilities|passwordfile|passwordmanager))'
|
||||||
[[ $pkgname =~ $pattern ]] && continue
|
[[ $pkgname =~ $pattern ]] && continue
|
||||||
|
|
||||||
# check if template exists and modify template instead
|
# check if template exists and modify template instead
|
||||||
|
|
|
@ -1,29 +0,0 @@
|
||||||
From dbe68d96e7da8ba5e5484e6ad0bbd78c9b0a8eec Mon Sep 17 00:00:00 2001
|
|
||||||
From: Martchus <martchus@gmx.net>
|
|
||||||
Date: Sun, 9 Dec 2018 14:29:59 +0100
|
|
||||||
Subject: [PATCH] Disable mapboxgl
|
|
||||||
|
|
||||||
---
|
|
||||||
src/plugins/geoservices/geoservices.pro | 9 ---------
|
|
||||||
1 file changed, 9 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/src/plugins/geoservices/geoservices.pro b/src/plugins/geoservices/geoservices.pro
|
|
||||||
index b81ad34a..98308c97 100644
|
|
||||||
--- a/src/plugins/geoservices/geoservices.pro
|
|
||||||
+++ b/src/plugins/geoservices/geoservices.pro
|
|
||||||
@@ -7,12 +7,3 @@ qtConfig(geoservices_mapbox): SUBDIRS += mapbox
|
|
||||||
qtConfig(geoservices_esri): SUBDIRS += esri
|
|
||||||
qtConfig(geoservices_itemsoverlay): SUBDIRS += itemsoverlay
|
|
||||||
qtConfig(geoservices_osm): SUBDIRS += osm
|
|
||||||
-
|
|
||||||
-qtConfig(geoservices_mapboxgl) {
|
|
||||||
- !exists(../../3rdparty/mapbox-gl-native/mapbox-gl-native.pro) {
|
|
||||||
- warning("Submodule mapbox-gl-native does not exist. Run 'git submodule update --init' on qtlocation.")
|
|
||||||
- } else {
|
|
||||||
- SUBDIRS += mapboxgl ../../3rdparty/mapbox-gl-native
|
|
||||||
- mapboxgl.depends = ../../3rdparty/mapbox-gl-native
|
|
||||||
- }
|
|
||||||
-}
|
|
||||||
--
|
|
||||||
2.23.0
|
|
||||||
|
|
|
@ -1,40 +0,0 @@
|
||||||
From 2c8ca36b5f87ccfc039c0b669c80f21205769758 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Martchus <martchus@gmx.net>
|
|
||||||
Date: Sun, 9 Dec 2018 14:28:07 +0100
|
|
||||||
Subject: [PATCH 1/4] Fix clang/libc++ build under Android
|
|
||||||
|
|
||||||
---
|
|
||||||
mkspecs/android-clang/qmake.conf | 7 +++++--
|
|
||||||
1 file changed, 5 insertions(+), 2 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/mkspecs/android-clang/qmake.conf b/mkspecs/android-clang/qmake.conf
|
|
||||||
index 05b7979142..83d030793b 100644
|
|
||||||
--- a/mkspecs/android-clang/qmake.conf
|
|
||||||
+++ b/mkspecs/android-clang/qmake.conf
|
|
||||||
@@ -30,11 +30,12 @@ QMAKE_CFLAGS += -gcc-toolchain $$NDK_TOOLCHAIN_PATH -fno-limit-debug-info
|
|
||||||
QMAKE_LINK = $$QMAKE_CXX $$QMAKE_CFLAGS -Wl,--exclude-libs,libgcc.a -Wl,--exclude-libs,libatomic.a -nostdlib++
|
|
||||||
equals(ANDROID_TARGET_ARCH, armeabi-v7a): QMAKE_LINK += -Wl,--exclude-libs,libunwind.a
|
|
||||||
|
|
||||||
-QMAKE_CFLAGS += -DANDROID_HAS_WSTRING --sysroot=$$NDK_ROOT/sysroot \
|
|
||||||
+QMAKE_CFLAGS += -DANDROID_HAS_WSTRING --sysroot=$$ANDROID_PLATFORM_ROOT_PATH \
|
|
||||||
-isystem $$NDK_ROOT/sysroot/usr/include/$$NDK_TOOLS_PREFIX \
|
|
||||||
-isystem $$NDK_ROOT/sources/cxx-stl/llvm-libc++/include \
|
|
||||||
-isystem $$NDK_ROOT/sources/android/support/include \
|
|
||||||
- -isystem $$NDK_ROOT/sources/cxx-stl/llvm-libc++abi/include
|
|
||||||
+ -isystem $$NDK_ROOT/sources/cxx-stl/llvm-libc++abi/include \
|
|
||||||
+ -isystem $$NDK_ROOT/sysroot/usr/include
|
|
||||||
|
|
||||||
ANDROID_SOURCES_CXX_STL_LIBDIR = $$NDK_ROOT/sources/cxx-stl/llvm-libc++/libs/$$ANDROID_TARGET_ARCH
|
|
||||||
|
|
||||||
@@ -44,6 +45,8 @@ ANDROID_USE_LLVM = true
|
|
||||||
|
|
||||||
exists($$ANDROID_SOURCES_CXX_STL_LIBDIR/libc++.so): \
|
|
||||||
ANDROID_CXX_STL_LIBS = -lc++
|
|
||||||
+else: exists($$ANDROID_SOURCES_CXX_STL_LIBDIR/libc++_shared.so): \
|
|
||||||
+ ANDROID_CXX_STL_LIBS = -lc++_shared
|
|
||||||
else: \
|
|
||||||
ANDROID_CXX_STL_LIBS = $$ANDROID_SOURCES_CXX_STL_LIBDIR/libc++.so.$$replace(ANDROID_PLATFORM, "android-", "")
|
|
||||||
|
|
||||||
--
|
|
||||||
2.23.0
|
|
||||||
|
|
|
@ -1,24 +1,27 @@
|
||||||
From a71a1223328539ee403884a24d1dbc5a685d40dd Mon Sep 17 00:00:00 2001
|
From f21b3b1871deae16696c427ca95ffd0ace0a4f70 Mon Sep 17 00:00:00 2001
|
||||||
From: Martchus <martchus@gmx.net>
|
From: Martchus <martchus@gmx.net>
|
||||||
Date: Sun, 7 Apr 2019 09:54:49 +0200
|
Date: Sun, 7 Apr 2019 09:54:49 +0200
|
||||||
Subject: [PATCH 3/4] Support pkg-config under Android
|
Subject: [PATCH 1/2] Support pkg-config under Android
|
||||||
|
|
||||||
from https://aur.archlinux.org/cgit/aur.git/commit/?h=android-aarch64-qt5&id=d901da324b2ceea2ac99b48137cb82b2bd920c77
|
from https://aur.archlinux.org/cgit/aur.git/commit/?h=android-aarch64-qt5&id=d901da324b2ceea2ac99b48137cb82b2bd920c77
|
||||||
|
|
||||||
|
Change-Id: I68ebfa818ab4eec34a170602ea2c1f4824e80213
|
||||||
---
|
---
|
||||||
mkspecs/android-clang/qmake.conf | 3 +++
|
mkspecs/android-clang/qmake.conf | 3 +++
|
||||||
1 file changed, 3 insertions(+)
|
1 file changed, 3 insertions(+)
|
||||||
|
|
||||||
diff --git a/mkspecs/android-clang/qmake.conf b/mkspecs/android-clang/qmake.conf
|
diff --git a/mkspecs/android-clang/qmake.conf b/mkspecs/android-clang/qmake.conf
|
||||||
index 83d030793b..8f145a2bb7 100644
|
index 5cc5a20f71..c8725f1b6d 100644
|
||||||
--- a/mkspecs/android-clang/qmake.conf
|
--- a/mkspecs/android-clang/qmake.conf
|
||||||
+++ b/mkspecs/android-clang/qmake.conf
|
+++ b/mkspecs/android-clang/qmake.conf
|
||||||
@@ -53,3 +53,6 @@ else: \
|
@@ -113,4 +113,7 @@ x86_64.dir_affix = x86_64
|
||||||
QMAKE_CFLAGS_OPTIMIZE_SIZE = -Oz
|
x86_64.CONFIG = x86_64
|
||||||
|
x86_64.deployment_identifier = x86_64
|
||||||
|
|
||||||
include(../common/android-base-tail.conf)
|
|
||||||
+
|
|
||||||
+QMAKE_PKG_CONFIG = $$[QT_INSTALL_PREFIX]
|
+QMAKE_PKG_CONFIG = $$[QT_INSTALL_PREFIX]
|
||||||
+QMAKE_PKG_CONFIG = android-$$section(QMAKE_PKG_CONFIG, /, 3, 3)-pkg-config
|
+QMAKE_PKG_CONFIG = android-$$section(QMAKE_PKG_CONFIG, /, 3, 3)-pkg-config
|
||||||
|
+
|
||||||
|
load(qt_config)
|
||||||
--
|
--
|
||||||
2.23.0
|
2.28.0
|
||||||
|
|
|
@ -1,34 +0,0 @@
|
||||||
From 996c53a388705a0bbf778faaf7660efad98e1eff Mon Sep 17 00:00:00 2001
|
|
||||||
From: Martchus <martchus@gmx.net>
|
|
||||||
Date: Sun, 9 Dec 2018 14:31:30 +0100
|
|
||||||
Subject: [PATCH 2/4] Fix androiddeployqt search paths
|
|
||||||
|
|
||||||
---
|
|
||||||
src/tools/androiddeployqt/main.cpp | 4 ++--
|
|
||||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/src/tools/androiddeployqt/main.cpp b/src/tools/androiddeployqt/main.cpp
|
|
||||||
index 01c392f8f9..9600d657cb 100644
|
|
||||||
--- a/src/tools/androiddeployqt/main.cpp
|
|
||||||
+++ b/src/tools/androiddeployqt/main.cpp
|
|
||||||
@@ -1721,7 +1721,7 @@ bool scanImports(Options *options, QSet<QString> *usedDependencies)
|
|
||||||
rootPath += QLatin1Char('/');
|
|
||||||
|
|
||||||
QStringList importPaths;
|
|
||||||
- importPaths += shellQuote(options->qtInstallDirectory + QLatin1String("/qml"));
|
|
||||||
+ importPaths += shellQuote(options->qtInstallDirectory + QLatin1String("/lib/qt/qml"));
|
|
||||||
importPaths += shellQuote(rootPath);
|
|
||||||
for (const QString &qmlImportPath : qAsConst(options->qmlImportPaths))
|
|
||||||
importPaths += shellQuote(qmlImportPath);
|
|
||||||
@@ -1857,7 +1857,7 @@ bool readDependencies(Options *options)
|
|
||||||
return false;
|
|
||||||
|
|
||||||
// Jam in the dependencies of the platform plugin, since the application will crash without it
|
|
||||||
- if (!readDependenciesFromElf(options, options->qtInstallDirectory + QLatin1String("/plugins/platforms/android/libqtforandroid.so"), &usedDependencies, &remainingDependencies))
|
|
||||||
+ if (!readDependenciesFromElf(options, options->qtInstallDirectory + QLatin1String("/lib/qt/plugins/platforms/android/libqtforandroid.so"), &usedDependencies, &remainingDependencies))
|
|
||||||
return false;
|
|
||||||
|
|
||||||
while (!remainingDependencies.isEmpty()) {
|
|
||||||
--
|
|
||||||
2.23.0
|
|
||||||
|
|
|
@ -0,0 +1,50 @@
|
||||||
|
From 95b37ab2ddb476326fd803c7b0551ac3b88215b9 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Martchus <martchus@gmx.net>
|
||||||
|
Date: Wed, 16 Sep 2020 18:18:26 +0200
|
||||||
|
Subject: [PATCH 2/2] Force 64-bit atomics usage
|
||||||
|
|
||||||
|
From hipersayan_x's AUR package (added with 5.14.2 update).
|
||||||
|
|
||||||
|
Change-Id: I0c94983b5ddc2897eeabbd6ef4703f455d23f9a2
|
||||||
|
---
|
||||||
|
src/corelib/configure.json | 16 +++-------------
|
||||||
|
1 file changed, 3 insertions(+), 13 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/src/corelib/configure.json b/src/corelib/configure.json
|
||||||
|
index c5e0423273..bd7ef73fe0 100644
|
||||||
|
--- a/src/corelib/configure.json
|
||||||
|
+++ b/src/corelib/configure.json
|
||||||
|
@@ -135,27 +135,17 @@
|
||||||
|
"label": "64 bit atomics",
|
||||||
|
"test": {
|
||||||
|
"tail": [
|
||||||
|
- "void test(volatile std::atomic<std::int64_t> &a)",
|
||||||
|
+ "void test()",
|
||||||
|
"{",
|
||||||
|
- " std::int64_t v = a.load(std::memory_order_acquire);",
|
||||||
|
- " while (!a.compare_exchange_strong(v, v + 1,",
|
||||||
|
- " std::memory_order_acq_rel,",
|
||||||
|
- " std::memory_order_acquire)) {",
|
||||||
|
- " v = a.exchange(v - 1);",
|
||||||
|
- " }",
|
||||||
|
- " a.store(v + 1, std::memory_order_release);",
|
||||||
|
"}"
|
||||||
|
],
|
||||||
|
"main": [
|
||||||
|
- "void *ptr = (void*)0xffffffc0; // any random pointer",
|
||||||
|
- "test(*reinterpret_cast<std::atomic<std::int64_t> *>(ptr));"
|
||||||
|
+ "test();"
|
||||||
|
],
|
||||||
|
"qmake": "CONFIG += c++11"
|
||||||
|
},
|
||||||
|
- "headers": [ "atomic", "cstdint" ],
|
||||||
|
"sources": [
|
||||||
|
- "",
|
||||||
|
- "-latomic"
|
||||||
|
+ ""
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"librt": {
|
||||||
|
--
|
||||||
|
2.28.0
|
||||||
|
|
|
@ -1,24 +0,0 @@
|
||||||
From 9cd435c730949e29104bbfa2bdd82ed2c662ca3d Mon Sep 17 00:00:00 2001
|
|
||||||
From: Martchus <martchus@gmx.net>
|
|
||||||
Date: Sat, 7 Sep 2019 13:21:37 +0200
|
|
||||||
Subject: [PATCH 4/4] Use pkg-config to find libjpeg
|
|
||||||
|
|
||||||
---
|
|
||||||
src/gui/configure.json | 1 +
|
|
||||||
1 file changed, 1 insertion(+)
|
|
||||||
|
|
||||||
diff --git a/src/gui/configure.json b/src/gui/configure.json
|
|
||||||
index 6280b4dfa2..206f83984a 100644
|
|
||||||
--- a/src/gui/configure.json
|
|
||||||
+++ b/src/gui/configure.json
|
|
||||||
@@ -373,6 +373,7 @@
|
|
||||||
},
|
|
||||||
"headers": "jpeglib.h",
|
|
||||||
"sources": [
|
|
||||||
+ { "type": "pkgConfig", "args": "libjpeg" },
|
|
||||||
{ "libs": "-llibjpeg", "condition": "config.msvc" },
|
|
||||||
"-ljpeg"
|
|
||||||
]
|
|
||||||
--
|
|
||||||
2.23.0
|
|
||||||
|
|
|
@ -7,10 +7,12 @@
|
||||||
|
|
||||||
_pkg_arch=aarch64
|
_pkg_arch=aarch64
|
||||||
_android_arch=arm64-v8a
|
_android_arch=arm64-v8a
|
||||||
_android_platform=22
|
_android_min_platform=24
|
||||||
|
_android_api_platform=30
|
||||||
|
_android_ndk_platform=$_android_min_platform
|
||||||
|
|
||||||
pkgname=android-$_pkg_arch-qt5
|
pkgname=android-$_pkg_arch-qt5
|
||||||
pkgver=5.13.1
|
pkgver=5.15.1
|
||||||
pkgrel=1
|
pkgrel=1
|
||||||
pkgdesc="Qt 5 for Android"
|
pkgdesc="Qt 5 for Android"
|
||||||
arch=('x86_64')
|
arch=('x86_64')
|
||||||
|
@ -25,20 +27,23 @@ makedepends=('libgl'
|
||||||
'gperf'
|
'gperf'
|
||||||
'libxslt'
|
'libxslt'
|
||||||
'fontconfig'
|
'fontconfig'
|
||||||
|
'ninja'
|
||||||
'java-environment-openjdk<=8'
|
'java-environment-openjdk<=8'
|
||||||
'android-environment'
|
'android-environment'
|
||||||
'android-pkg-config'
|
'android-pkg-config')
|
||||||
"android-$_pkg_arch-openssl")
|
|
||||||
depends=('java-runtime-headless-openjdk<=8'
|
depends=('java-runtime-headless-openjdk<=8'
|
||||||
'apache-ant'
|
'apache-ant'
|
||||||
'android-ndk'
|
'android-ndk'
|
||||||
"android-platform-$_android_platform"
|
|
||||||
'android-sdk'
|
'android-sdk'
|
||||||
'android-sdk-build-tools'
|
'android-sdk-build-tools'
|
||||||
'android-sdk-platform-tools'
|
'android-sdk-platform-tools'
|
||||||
"android-$_pkg_arch-zlib"
|
'android-platform'
|
||||||
|
"android-$_pkg_arch-libjpeg-turbo"
|
||||||
"android-$_pkg_arch-libpng"
|
"android-$_pkg_arch-libpng"
|
||||||
"android-$_pkg_arch-libjpeg-turbo")
|
"android-$_pkg_arch-libwebp"
|
||||||
|
"android-$_pkg_arch-libtiff"
|
||||||
|
"android-$_pkg_arch-openssl"
|
||||||
|
"android-$_pkg_arch-zlib")
|
||||||
groups=('android-qt5')
|
groups=('android-qt5')
|
||||||
conflicts=("android-qt5-${_android_arch}")
|
conflicts=("android-qt5-${_android_arch}")
|
||||||
replaces=("android-qt5-${_android_arch}")
|
replaces=("android-qt5-${_android_arch}")
|
||||||
|
@ -68,51 +73,47 @@ optdepends+=("android-$_pkg_arch-openssl: SSL support for Qt Network")
|
||||||
options=(!strip !buildflags staticlibs !emptydirs)
|
options=(!strip !buildflags staticlibs !emptydirs)
|
||||||
_pkgfqn="qt-everywhere-src-${pkgver}"
|
_pkgfqn="qt-everywhere-src-${pkgver}"
|
||||||
source=("http://download.qt-project.org/official_releases/qt/${pkgver:0:4}/${pkgver}/single/${_pkgfqn}.tar.xz"
|
source=("http://download.qt-project.org/official_releases/qt/${pkgver:0:4}/${pkgver}/single/${_pkgfqn}.tar.xz"
|
||||||
'0001-Fix-clang-libc-build-under-Android.patch'
|
'0001-Support-pkg-config-under-Android.patch'
|
||||||
'0002-Fix-androiddeployqt-search-paths.patch'
|
'0002-Force-64-bit-atomics-usage.patch')
|
||||||
'0003-Support-pkg-config-under-Android.patch'
|
sha256sums=('44da876057e21e1be42de31facd99be7d5f9f07893e1ea762359bcee0ef64ee9'
|
||||||
'0004-Use-pkg-config-to-find-libjpeg.patch'
|
'435047d2f09baf2e706c86604c944686e71ab6d7678203b68e7d28af7beb5ce8'
|
||||||
'0001-Disable-mapboxgl.patch')
|
'1f0aab5dcf7976285ffbb9069f127087f15d60a23485fadf17312090453d6784')
|
||||||
sha256sums=('adf00266dc38352a166a9739f1a24a1e36f1be9c04bf72e16e142a256436974e'
|
|
||||||
'29bcb93f9c79ad4b0709efa42694ed917b6e4cfce69a805e79a7dc3144be7765'
|
|
||||||
'7a5520311ba2edee2ffcd546cd6e08248c8f73deed33bd8075649577f8cb1446'
|
|
||||||
'5c3f0725f3c27263661ff5ebb4b279e4483de8ed70dee4fe42a84d31b3f2e4a9'
|
|
||||||
'4f3ba22616040a2979bfdf840b44bf105374ea2fac866c42977ad7ec6e87ddcc'
|
|
||||||
'6151b784050f9d4ef3eec22dd33360d3f566d4834592f1171df91a10c95fab77')
|
|
||||||
|
|
||||||
prepare() {
|
prepare() {
|
||||||
export ANDROID_MINIMUM_PLATFORM=${_android_platform}
|
export ANDROID_MINIMUM_PLATFORM=$_android_min_platform
|
||||||
|
export ANDROID_API_VERSION=android-$_android_api_platform
|
||||||
|
export ANDROID_NDK_PLATFORM=android-$_android_ndk_platform
|
||||||
source android-env ${_pkg_arch}
|
source android-env ${_pkg_arch}
|
||||||
|
|
||||||
|
check_ndk_version_ge_than 18.0
|
||||||
|
check_android_platform
|
||||||
|
|
||||||
cd ${_pkgfqn}
|
cd ${_pkgfqn}
|
||||||
|
|
||||||
pushd qtbase
|
pushd qtbase
|
||||||
patch -Np1 -i "../../0001-Fix-clang-libc-build-under-Android.patch"
|
patch -Np1 -i "../../0001-Support-pkg-config-under-Android.patch"
|
||||||
#patch -Np1 -i "../../0002-Fix-androiddeployqt-search-paths.patch"
|
case "$_android_arch" in
|
||||||
patch -Np1 -i "../../0003-Support-pkg-config-under-Android.patch"
|
aarch64 | x86-64)
|
||||||
patch -Np1 -i "../../0004-Use-pkg-config-to-find-libjpeg.patch"
|
patch -Np1 -i "../../0002-Force-64-bit-atomics-usage.patch"
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
;;
|
||||||
|
esac
|
||||||
popd
|
popd
|
||||||
|
|
||||||
pushd qtlocation
|
sed -i "s/android-21/android-$ANDROID_MINIMUM_PLATFORM/g" qtbase/configure.pri
|
||||||
# skip building mapboxgl as it increases compile time significantly and
|
|
||||||
# likely not a lot of people actually using it; if you need it, just remove the
|
|
||||||
# following line:
|
|
||||||
patch -Np1 -i "../../0001-Disable-mapboxgl.patch"
|
|
||||||
popd
|
|
||||||
|
|
||||||
sed -i "s/android-16/android-$ANDROID_MINIMUM_PLATFORM/g" qtbase/mkspecs/features/android/sdk.prf
|
|
||||||
sed -i "s/android-16/android-$ANDROID_MINIMUM_PLATFORM/g" qtbase/src/android/jar/jar.pro
|
|
||||||
sed -i "s/android-16/android-$ANDROID_MINIMUM_PLATFORM/g" qtgamepad/src/plugins/gamepads/android/jar/jar.pro
|
|
||||||
sed -i "s/android-16/android-$ANDROID_MINIMUM_PLATFORM/g" qtbase/configure.pri
|
|
||||||
}
|
}
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
export ANDROID_MINIMUM_PLATFORM=${_android_platform}
|
export ANDROID_MINIMUM_PLATFORM=$_android_min_platform
|
||||||
|
export ANDROID_API_VERSION=android-$_android_api_platform
|
||||||
|
export ANDROID_NDK_PLATFORM=android-$_android_ndk_platform
|
||||||
source android-env ${_pkg_arch}
|
source android-env ${_pkg_arch}
|
||||||
|
|
||||||
unset CC CXX CFLAGS CXXFLAGS LDFLAGS CHOST QMAKESPEC QTDIR CARCH
|
unset CC CXX CFLAGS CXXFLAGS LDFLAGS CHOST QMAKESPEC QTDIR CARCH
|
||||||
|
|
||||||
export PKG_CONFIG=$ANDROID_PKGCONFIG
|
export PKG_CONFIG=$ANDROID_PKGCONFIG
|
||||||
|
export ANDROID_TARGET_ARCH=${ANDROID_ABI}
|
||||||
export PYTHON=/usr/bin/python2
|
export PYTHON=/usr/bin/python2
|
||||||
|
|
||||||
cd ${_pkgfqn}
|
cd ${_pkgfqn}
|
||||||
|
@ -126,24 +127,30 @@ build() {
|
||||||
-xplatform android-clang
|
-xplatform android-clang
|
||||||
-nomake tests
|
-nomake tests
|
||||||
-nomake examples
|
-nomake examples
|
||||||
-android-ndk ${ANDROID_NDK_HOME}
|
|
||||||
-android-sdk ${ANDROID_HOME}
|
-android-sdk ${ANDROID_HOME}
|
||||||
|
-android-ndk ${ANDROID_NDK_HOME}
|
||||||
-android-ndk-host linux-x86_64
|
-android-ndk-host linux-x86_64
|
||||||
-android-toolchain-version 4.9
|
-android-ndk-platform ${ANDROID_NDK_PLATFORM}
|
||||||
|
-android-abis ${ANDROID_ABI}
|
||||||
-skip qtserialport
|
-skip qtserialport
|
||||||
|
-skip qtwebengine
|
||||||
-no-warnings-are-errors
|
-no-warnings-are-errors
|
||||||
-pkg-config
|
-pkg-config
|
||||||
-system-zlib
|
-system-zlib
|
||||||
-system-libpng
|
-system-libpng
|
||||||
-system-libjpeg
|
-system-libjpeg
|
||||||
|
-system-webp
|
||||||
|
-system-tiff
|
||||||
|
-no-feature-geoservices_mapbox
|
||||||
|
-no-feature-geoservices_mapboxgl
|
||||||
-qt-freetype
|
-qt-freetype
|
||||||
-openssl-runtime
|
-openssl-runtime
|
||||||
-android-arch ${ANDROID_ABI}
|
-verbose
|
||||||
-android-ndk-platform ${ANDROID_NDK_PLATFORM}
|
|
||||||
-recheck-all
|
|
||||||
-optimized-qmake
|
-optimized-qmake
|
||||||
-I${ANDROID_PREFIX}/include"
|
-I${ANDROID_PREFIX}/include"
|
||||||
|
|
||||||
|
# note: use -recheck-all and/or -redo to continue
|
||||||
|
|
||||||
[[ $ANDROID_DEBUG_BUILD ]] \
|
[[ $ANDROID_DEBUG_BUILD ]] \
|
||||||
&& configue_opts+=' -debug-and-release' \
|
&& configue_opts+=' -debug-and-release' \
|
||||||
|| configue_opts+=' -release'
|
|| configue_opts+=' -release'
|
||||||
|
@ -165,7 +172,9 @@ build() {
|
||||||
}
|
}
|
||||||
|
|
||||||
package() {
|
package() {
|
||||||
export ANDROID_MINIMUM_PLATFORM=${_android_platform}
|
export ANDROID_MINIMUM_PLATFORM=$_android_min_platform
|
||||||
|
export ANDROID_API_VERSION=android-$_android_api_platform
|
||||||
|
export ANDROID_NDK_PLATFORM=android-$_android_ndk_platform
|
||||||
source android-env ${_pkg_arch}
|
source android-env ${_pkg_arch}
|
||||||
|
|
||||||
cd ${_pkgfqn}
|
cd ${_pkgfqn}
|
||||||
|
|
|
@ -1,29 +0,0 @@
|
||||||
From dbe68d96e7da8ba5e5484e6ad0bbd78c9b0a8eec Mon Sep 17 00:00:00 2001
|
|
||||||
From: Martchus <martchus@gmx.net>
|
|
||||||
Date: Sun, 9 Dec 2018 14:29:59 +0100
|
|
||||||
Subject: [PATCH] Disable mapboxgl
|
|
||||||
|
|
||||||
---
|
|
||||||
src/plugins/geoservices/geoservices.pro | 9 ---------
|
|
||||||
1 file changed, 9 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/src/plugins/geoservices/geoservices.pro b/src/plugins/geoservices/geoservices.pro
|
|
||||||
index b81ad34a..98308c97 100644
|
|
||||||
--- a/src/plugins/geoservices/geoservices.pro
|
|
||||||
+++ b/src/plugins/geoservices/geoservices.pro
|
|
||||||
@@ -7,12 +7,3 @@ qtConfig(geoservices_mapbox): SUBDIRS += mapbox
|
|
||||||
qtConfig(geoservices_esri): SUBDIRS += esri
|
|
||||||
qtConfig(geoservices_itemsoverlay): SUBDIRS += itemsoverlay
|
|
||||||
qtConfig(geoservices_osm): SUBDIRS += osm
|
|
||||||
-
|
|
||||||
-qtConfig(geoservices_mapboxgl) {
|
|
||||||
- !exists(../../3rdparty/mapbox-gl-native/mapbox-gl-native.pro) {
|
|
||||||
- warning("Submodule mapbox-gl-native does not exist. Run 'git submodule update --init' on qtlocation.")
|
|
||||||
- } else {
|
|
||||||
- SUBDIRS += mapboxgl ../../3rdparty/mapbox-gl-native
|
|
||||||
- mapboxgl.depends = ../../3rdparty/mapbox-gl-native
|
|
||||||
- }
|
|
||||||
-}
|
|
||||||
--
|
|
||||||
2.23.0
|
|
||||||
|
|
|
@ -1,40 +0,0 @@
|
||||||
From 2c8ca36b5f87ccfc039c0b669c80f21205769758 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Martchus <martchus@gmx.net>
|
|
||||||
Date: Sun, 9 Dec 2018 14:28:07 +0100
|
|
||||||
Subject: [PATCH 1/4] Fix clang/libc++ build under Android
|
|
||||||
|
|
||||||
---
|
|
||||||
mkspecs/android-clang/qmake.conf | 7 +++++--
|
|
||||||
1 file changed, 5 insertions(+), 2 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/mkspecs/android-clang/qmake.conf b/mkspecs/android-clang/qmake.conf
|
|
||||||
index 05b7979142..83d030793b 100644
|
|
||||||
--- a/mkspecs/android-clang/qmake.conf
|
|
||||||
+++ b/mkspecs/android-clang/qmake.conf
|
|
||||||
@@ -30,11 +30,12 @@ QMAKE_CFLAGS += -gcc-toolchain $$NDK_TOOLCHAIN_PATH -fno-limit-debug-info
|
|
||||||
QMAKE_LINK = $$QMAKE_CXX $$QMAKE_CFLAGS -Wl,--exclude-libs,libgcc.a -Wl,--exclude-libs,libatomic.a -nostdlib++
|
|
||||||
equals(ANDROID_TARGET_ARCH, armeabi-v7a): QMAKE_LINK += -Wl,--exclude-libs,libunwind.a
|
|
||||||
|
|
||||||
-QMAKE_CFLAGS += -DANDROID_HAS_WSTRING --sysroot=$$NDK_ROOT/sysroot \
|
|
||||||
+QMAKE_CFLAGS += -DANDROID_HAS_WSTRING --sysroot=$$ANDROID_PLATFORM_ROOT_PATH \
|
|
||||||
-isystem $$NDK_ROOT/sysroot/usr/include/$$NDK_TOOLS_PREFIX \
|
|
||||||
-isystem $$NDK_ROOT/sources/cxx-stl/llvm-libc++/include \
|
|
||||||
-isystem $$NDK_ROOT/sources/android/support/include \
|
|
||||||
- -isystem $$NDK_ROOT/sources/cxx-stl/llvm-libc++abi/include
|
|
||||||
+ -isystem $$NDK_ROOT/sources/cxx-stl/llvm-libc++abi/include \
|
|
||||||
+ -isystem $$NDK_ROOT/sysroot/usr/include
|
|
||||||
|
|
||||||
ANDROID_SOURCES_CXX_STL_LIBDIR = $$NDK_ROOT/sources/cxx-stl/llvm-libc++/libs/$$ANDROID_TARGET_ARCH
|
|
||||||
|
|
||||||
@@ -44,6 +45,8 @@ ANDROID_USE_LLVM = true
|
|
||||||
|
|
||||||
exists($$ANDROID_SOURCES_CXX_STL_LIBDIR/libc++.so): \
|
|
||||||
ANDROID_CXX_STL_LIBS = -lc++
|
|
||||||
+else: exists($$ANDROID_SOURCES_CXX_STL_LIBDIR/libc++_shared.so): \
|
|
||||||
+ ANDROID_CXX_STL_LIBS = -lc++_shared
|
|
||||||
else: \
|
|
||||||
ANDROID_CXX_STL_LIBS = $$ANDROID_SOURCES_CXX_STL_LIBDIR/libc++.so.$$replace(ANDROID_PLATFORM, "android-", "")
|
|
||||||
|
|
||||||
--
|
|
||||||
2.23.0
|
|
||||||
|
|
|
@ -1,24 +1,27 @@
|
||||||
From a71a1223328539ee403884a24d1dbc5a685d40dd Mon Sep 17 00:00:00 2001
|
From f21b3b1871deae16696c427ca95ffd0ace0a4f70 Mon Sep 17 00:00:00 2001
|
||||||
From: Martchus <martchus@gmx.net>
|
From: Martchus <martchus@gmx.net>
|
||||||
Date: Sun, 7 Apr 2019 09:54:49 +0200
|
Date: Sun, 7 Apr 2019 09:54:49 +0200
|
||||||
Subject: [PATCH 3/4] Support pkg-config under Android
|
Subject: [PATCH 1/2] Support pkg-config under Android
|
||||||
|
|
||||||
from https://aur.archlinux.org/cgit/aur.git/commit/?h=android-aarch64-qt5&id=d901da324b2ceea2ac99b48137cb82b2bd920c77
|
from https://aur.archlinux.org/cgit/aur.git/commit/?h=android-aarch64-qt5&id=d901da324b2ceea2ac99b48137cb82b2bd920c77
|
||||||
|
|
||||||
|
Change-Id: I68ebfa818ab4eec34a170602ea2c1f4824e80213
|
||||||
---
|
---
|
||||||
mkspecs/android-clang/qmake.conf | 3 +++
|
mkspecs/android-clang/qmake.conf | 3 +++
|
||||||
1 file changed, 3 insertions(+)
|
1 file changed, 3 insertions(+)
|
||||||
|
|
||||||
diff --git a/mkspecs/android-clang/qmake.conf b/mkspecs/android-clang/qmake.conf
|
diff --git a/mkspecs/android-clang/qmake.conf b/mkspecs/android-clang/qmake.conf
|
||||||
index 83d030793b..8f145a2bb7 100644
|
index 5cc5a20f71..c8725f1b6d 100644
|
||||||
--- a/mkspecs/android-clang/qmake.conf
|
--- a/mkspecs/android-clang/qmake.conf
|
||||||
+++ b/mkspecs/android-clang/qmake.conf
|
+++ b/mkspecs/android-clang/qmake.conf
|
||||||
@@ -53,3 +53,6 @@ else: \
|
@@ -113,4 +113,7 @@ x86_64.dir_affix = x86_64
|
||||||
QMAKE_CFLAGS_OPTIMIZE_SIZE = -Oz
|
x86_64.CONFIG = x86_64
|
||||||
|
x86_64.deployment_identifier = x86_64
|
||||||
|
|
||||||
include(../common/android-base-tail.conf)
|
|
||||||
+
|
|
||||||
+QMAKE_PKG_CONFIG = $$[QT_INSTALL_PREFIX]
|
+QMAKE_PKG_CONFIG = $$[QT_INSTALL_PREFIX]
|
||||||
+QMAKE_PKG_CONFIG = android-$$section(QMAKE_PKG_CONFIG, /, 3, 3)-pkg-config
|
+QMAKE_PKG_CONFIG = android-$$section(QMAKE_PKG_CONFIG, /, 3, 3)-pkg-config
|
||||||
|
+
|
||||||
|
load(qt_config)
|
||||||
--
|
--
|
||||||
2.23.0
|
2.28.0
|
||||||
|
|
|
@ -1,34 +0,0 @@
|
||||||
From 996c53a388705a0bbf778faaf7660efad98e1eff Mon Sep 17 00:00:00 2001
|
|
||||||
From: Martchus <martchus@gmx.net>
|
|
||||||
Date: Sun, 9 Dec 2018 14:31:30 +0100
|
|
||||||
Subject: [PATCH 2/4] Fix androiddeployqt search paths
|
|
||||||
|
|
||||||
---
|
|
||||||
src/tools/androiddeployqt/main.cpp | 4 ++--
|
|
||||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/src/tools/androiddeployqt/main.cpp b/src/tools/androiddeployqt/main.cpp
|
|
||||||
index 01c392f8f9..9600d657cb 100644
|
|
||||||
--- a/src/tools/androiddeployqt/main.cpp
|
|
||||||
+++ b/src/tools/androiddeployqt/main.cpp
|
|
||||||
@@ -1721,7 +1721,7 @@ bool scanImports(Options *options, QSet<QString> *usedDependencies)
|
|
||||||
rootPath += QLatin1Char('/');
|
|
||||||
|
|
||||||
QStringList importPaths;
|
|
||||||
- importPaths += shellQuote(options->qtInstallDirectory + QLatin1String("/qml"));
|
|
||||||
+ importPaths += shellQuote(options->qtInstallDirectory + QLatin1String("/lib/qt/qml"));
|
|
||||||
importPaths += shellQuote(rootPath);
|
|
||||||
for (const QString &qmlImportPath : qAsConst(options->qmlImportPaths))
|
|
||||||
importPaths += shellQuote(qmlImportPath);
|
|
||||||
@@ -1857,7 +1857,7 @@ bool readDependencies(Options *options)
|
|
||||||
return false;
|
|
||||||
|
|
||||||
// Jam in the dependencies of the platform plugin, since the application will crash without it
|
|
||||||
- if (!readDependenciesFromElf(options, options->qtInstallDirectory + QLatin1String("/plugins/platforms/android/libqtforandroid.so"), &usedDependencies, &remainingDependencies))
|
|
||||||
+ if (!readDependenciesFromElf(options, options->qtInstallDirectory + QLatin1String("/lib/qt/plugins/platforms/android/libqtforandroid.so"), &usedDependencies, &remainingDependencies))
|
|
||||||
return false;
|
|
||||||
|
|
||||||
while (!remainingDependencies.isEmpty()) {
|
|
||||||
--
|
|
||||||
2.23.0
|
|
||||||
|
|
|
@ -0,0 +1,50 @@
|
||||||
|
From 95b37ab2ddb476326fd803c7b0551ac3b88215b9 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Martchus <martchus@gmx.net>
|
||||||
|
Date: Wed, 16 Sep 2020 18:18:26 +0200
|
||||||
|
Subject: [PATCH 2/2] Force 64-bit atomics usage
|
||||||
|
|
||||||
|
From hipersayan_x's AUR package (added with 5.14.2 update).
|
||||||
|
|
||||||
|
Change-Id: I0c94983b5ddc2897eeabbd6ef4703f455d23f9a2
|
||||||
|
---
|
||||||
|
src/corelib/configure.json | 16 +++-------------
|
||||||
|
1 file changed, 3 insertions(+), 13 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/src/corelib/configure.json b/src/corelib/configure.json
|
||||||
|
index c5e0423273..bd7ef73fe0 100644
|
||||||
|
--- a/src/corelib/configure.json
|
||||||
|
+++ b/src/corelib/configure.json
|
||||||
|
@@ -135,27 +135,17 @@
|
||||||
|
"label": "64 bit atomics",
|
||||||
|
"test": {
|
||||||
|
"tail": [
|
||||||
|
- "void test(volatile std::atomic<std::int64_t> &a)",
|
||||||
|
+ "void test()",
|
||||||
|
"{",
|
||||||
|
- " std::int64_t v = a.load(std::memory_order_acquire);",
|
||||||
|
- " while (!a.compare_exchange_strong(v, v + 1,",
|
||||||
|
- " std::memory_order_acq_rel,",
|
||||||
|
- " std::memory_order_acquire)) {",
|
||||||
|
- " v = a.exchange(v - 1);",
|
||||||
|
- " }",
|
||||||
|
- " a.store(v + 1, std::memory_order_release);",
|
||||||
|
"}"
|
||||||
|
],
|
||||||
|
"main": [
|
||||||
|
- "void *ptr = (void*)0xffffffc0; // any random pointer",
|
||||||
|
- "test(*reinterpret_cast<std::atomic<std::int64_t> *>(ptr));"
|
||||||
|
+ "test();"
|
||||||
|
],
|
||||||
|
"qmake": "CONFIG += c++11"
|
||||||
|
},
|
||||||
|
- "headers": [ "atomic", "cstdint" ],
|
||||||
|
"sources": [
|
||||||
|
- "",
|
||||||
|
- "-latomic"
|
||||||
|
+ ""
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"librt": {
|
||||||
|
--
|
||||||
|
2.28.0
|
||||||
|
|
|
@ -1,24 +0,0 @@
|
||||||
From 9cd435c730949e29104bbfa2bdd82ed2c662ca3d Mon Sep 17 00:00:00 2001
|
|
||||||
From: Martchus <martchus@gmx.net>
|
|
||||||
Date: Sat, 7 Sep 2019 13:21:37 +0200
|
|
||||||
Subject: [PATCH 4/4] Use pkg-config to find libjpeg
|
|
||||||
|
|
||||||
---
|
|
||||||
src/gui/configure.json | 1 +
|
|
||||||
1 file changed, 1 insertion(+)
|
|
||||||
|
|
||||||
diff --git a/src/gui/configure.json b/src/gui/configure.json
|
|
||||||
index 6280b4dfa2..206f83984a 100644
|
|
||||||
--- a/src/gui/configure.json
|
|
||||||
+++ b/src/gui/configure.json
|
|
||||||
@@ -373,6 +373,7 @@
|
|
||||||
},
|
|
||||||
"headers": "jpeglib.h",
|
|
||||||
"sources": [
|
|
||||||
+ { "type": "pkgConfig", "args": "libjpeg" },
|
|
||||||
{ "libs": "-llibjpeg", "condition": "config.msvc" },
|
|
||||||
"-ljpeg"
|
|
||||||
]
|
|
||||||
--
|
|
||||||
2.23.0
|
|
||||||
|
|
|
@ -7,10 +7,12 @@
|
||||||
|
|
||||||
_pkg_arch=armv7a-eabi
|
_pkg_arch=armv7a-eabi
|
||||||
_android_arch=armeabi-v7a
|
_android_arch=armeabi-v7a
|
||||||
_android_platform=21
|
_android_min_platform=24
|
||||||
|
_android_api_platform=30
|
||||||
|
_android_ndk_platform=$_android_min_platform
|
||||||
|
|
||||||
pkgname=android-$_pkg_arch-qt5
|
pkgname=android-$_pkg_arch-qt5
|
||||||
pkgver=5.13.1
|
pkgver=5.15.1
|
||||||
pkgrel=1
|
pkgrel=1
|
||||||
pkgdesc="Qt 5 for Android"
|
pkgdesc="Qt 5 for Android"
|
||||||
arch=('x86_64')
|
arch=('x86_64')
|
||||||
|
@ -25,20 +27,23 @@ makedepends=('libgl'
|
||||||
'gperf'
|
'gperf'
|
||||||
'libxslt'
|
'libxslt'
|
||||||
'fontconfig'
|
'fontconfig'
|
||||||
|
'ninja'
|
||||||
'java-environment-openjdk<=8'
|
'java-environment-openjdk<=8'
|
||||||
'android-environment'
|
'android-environment'
|
||||||
'android-pkg-config'
|
'android-pkg-config')
|
||||||
"android-$_pkg_arch-openssl")
|
|
||||||
depends=('java-runtime-headless-openjdk<=8'
|
depends=('java-runtime-headless-openjdk<=8'
|
||||||
'apache-ant'
|
'apache-ant'
|
||||||
'android-ndk'
|
'android-ndk'
|
||||||
"android-platform-$_android_platform"
|
|
||||||
'android-sdk'
|
'android-sdk'
|
||||||
'android-sdk-build-tools'
|
'android-sdk-build-tools'
|
||||||
'android-sdk-platform-tools'
|
'android-sdk-platform-tools'
|
||||||
"android-$_pkg_arch-zlib"
|
'android-platform'
|
||||||
|
"android-$_pkg_arch-libjpeg-turbo"
|
||||||
"android-$_pkg_arch-libpng"
|
"android-$_pkg_arch-libpng"
|
||||||
"android-$_pkg_arch-libjpeg-turbo")
|
"android-$_pkg_arch-libwebp"
|
||||||
|
"android-$_pkg_arch-libtiff"
|
||||||
|
"android-$_pkg_arch-openssl"
|
||||||
|
"android-$_pkg_arch-zlib")
|
||||||
groups=('android-qt5')
|
groups=('android-qt5')
|
||||||
conflicts=("android-qt5-${_android_arch}")
|
conflicts=("android-qt5-${_android_arch}")
|
||||||
replaces=("android-qt5-${_android_arch}")
|
replaces=("android-qt5-${_android_arch}")
|
||||||
|
@ -68,51 +73,47 @@ optdepends+=("android-$_pkg_arch-openssl: SSL support for Qt Network")
|
||||||
options=(!strip !buildflags staticlibs !emptydirs)
|
options=(!strip !buildflags staticlibs !emptydirs)
|
||||||
_pkgfqn="qt-everywhere-src-${pkgver}"
|
_pkgfqn="qt-everywhere-src-${pkgver}"
|
||||||
source=("http://download.qt-project.org/official_releases/qt/${pkgver:0:4}/${pkgver}/single/${_pkgfqn}.tar.xz"
|
source=("http://download.qt-project.org/official_releases/qt/${pkgver:0:4}/${pkgver}/single/${_pkgfqn}.tar.xz"
|
||||||
'0001-Fix-clang-libc-build-under-Android.patch'
|
'0001-Support-pkg-config-under-Android.patch'
|
||||||
'0002-Fix-androiddeployqt-search-paths.patch'
|
'0002-Force-64-bit-atomics-usage.patch')
|
||||||
'0003-Support-pkg-config-under-Android.patch'
|
sha256sums=('44da876057e21e1be42de31facd99be7d5f9f07893e1ea762359bcee0ef64ee9'
|
||||||
'0004-Use-pkg-config-to-find-libjpeg.patch'
|
'435047d2f09baf2e706c86604c944686e71ab6d7678203b68e7d28af7beb5ce8'
|
||||||
'0001-Disable-mapboxgl.patch')
|
'1f0aab5dcf7976285ffbb9069f127087f15d60a23485fadf17312090453d6784')
|
||||||
sha256sums=('adf00266dc38352a166a9739f1a24a1e36f1be9c04bf72e16e142a256436974e'
|
|
||||||
'29bcb93f9c79ad4b0709efa42694ed917b6e4cfce69a805e79a7dc3144be7765'
|
|
||||||
'7a5520311ba2edee2ffcd546cd6e08248c8f73deed33bd8075649577f8cb1446'
|
|
||||||
'5c3f0725f3c27263661ff5ebb4b279e4483de8ed70dee4fe42a84d31b3f2e4a9'
|
|
||||||
'4f3ba22616040a2979bfdf840b44bf105374ea2fac866c42977ad7ec6e87ddcc'
|
|
||||||
'6151b784050f9d4ef3eec22dd33360d3f566d4834592f1171df91a10c95fab77')
|
|
||||||
|
|
||||||
prepare() {
|
prepare() {
|
||||||
export ANDROID_MINIMUM_PLATFORM=${_android_platform}
|
export ANDROID_MINIMUM_PLATFORM=$_android_min_platform
|
||||||
|
export ANDROID_API_VERSION=android-$_android_api_platform
|
||||||
|
export ANDROID_NDK_PLATFORM=android-$_android_ndk_platform
|
||||||
source android-env ${_pkg_arch}
|
source android-env ${_pkg_arch}
|
||||||
|
|
||||||
|
check_ndk_version_ge_than 18.0
|
||||||
|
check_android_platform
|
||||||
|
|
||||||
cd ${_pkgfqn}
|
cd ${_pkgfqn}
|
||||||
|
|
||||||
pushd qtbase
|
pushd qtbase
|
||||||
patch -Np1 -i "../../0001-Fix-clang-libc-build-under-Android.patch"
|
patch -Np1 -i "../../0001-Support-pkg-config-under-Android.patch"
|
||||||
#patch -Np1 -i "../../0002-Fix-androiddeployqt-search-paths.patch"
|
case "$_android_arch" in
|
||||||
patch -Np1 -i "../../0003-Support-pkg-config-under-Android.patch"
|
aarch64 | x86-64)
|
||||||
patch -Np1 -i "../../0004-Use-pkg-config-to-find-libjpeg.patch"
|
patch -Np1 -i "../../0002-Force-64-bit-atomics-usage.patch"
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
;;
|
||||||
|
esac
|
||||||
popd
|
popd
|
||||||
|
|
||||||
pushd qtlocation
|
sed -i "s/android-21/android-$ANDROID_MINIMUM_PLATFORM/g" qtbase/configure.pri
|
||||||
# skip building mapboxgl as it increases compile time significantly and
|
|
||||||
# likely not a lot of people actually using it; if you need it, just remove the
|
|
||||||
# following line:
|
|
||||||
patch -Np1 -i "../../0001-Disable-mapboxgl.patch"
|
|
||||||
popd
|
|
||||||
|
|
||||||
sed -i "s/android-16/android-$ANDROID_MINIMUM_PLATFORM/g" qtbase/mkspecs/features/android/sdk.prf
|
|
||||||
sed -i "s/android-16/android-$ANDROID_MINIMUM_PLATFORM/g" qtbase/src/android/jar/jar.pro
|
|
||||||
sed -i "s/android-16/android-$ANDROID_MINIMUM_PLATFORM/g" qtgamepad/src/plugins/gamepads/android/jar/jar.pro
|
|
||||||
sed -i "s/android-16/android-$ANDROID_MINIMUM_PLATFORM/g" qtbase/configure.pri
|
|
||||||
}
|
}
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
export ANDROID_MINIMUM_PLATFORM=${_android_platform}
|
export ANDROID_MINIMUM_PLATFORM=$_android_min_platform
|
||||||
|
export ANDROID_API_VERSION=android-$_android_api_platform
|
||||||
|
export ANDROID_NDK_PLATFORM=android-$_android_ndk_platform
|
||||||
source android-env ${_pkg_arch}
|
source android-env ${_pkg_arch}
|
||||||
|
|
||||||
unset CC CXX CFLAGS CXXFLAGS LDFLAGS CHOST QMAKESPEC QTDIR CARCH
|
unset CC CXX CFLAGS CXXFLAGS LDFLAGS CHOST QMAKESPEC QTDIR CARCH
|
||||||
|
|
||||||
export PKG_CONFIG=$ANDROID_PKGCONFIG
|
export PKG_CONFIG=$ANDROID_PKGCONFIG
|
||||||
|
export ANDROID_TARGET_ARCH=${ANDROID_ABI}
|
||||||
export PYTHON=/usr/bin/python2
|
export PYTHON=/usr/bin/python2
|
||||||
|
|
||||||
cd ${_pkgfqn}
|
cd ${_pkgfqn}
|
||||||
|
@ -126,24 +127,30 @@ build() {
|
||||||
-xplatform android-clang
|
-xplatform android-clang
|
||||||
-nomake tests
|
-nomake tests
|
||||||
-nomake examples
|
-nomake examples
|
||||||
-android-ndk ${ANDROID_NDK_HOME}
|
|
||||||
-android-sdk ${ANDROID_HOME}
|
-android-sdk ${ANDROID_HOME}
|
||||||
|
-android-ndk ${ANDROID_NDK_HOME}
|
||||||
-android-ndk-host linux-x86_64
|
-android-ndk-host linux-x86_64
|
||||||
-android-toolchain-version 4.9
|
-android-ndk-platform ${ANDROID_NDK_PLATFORM}
|
||||||
|
-android-abis ${ANDROID_ABI}
|
||||||
-skip qtserialport
|
-skip qtserialport
|
||||||
|
-skip qtwebengine
|
||||||
-no-warnings-are-errors
|
-no-warnings-are-errors
|
||||||
-pkg-config
|
-pkg-config
|
||||||
-system-zlib
|
-system-zlib
|
||||||
-system-libpng
|
-system-libpng
|
||||||
-system-libjpeg
|
-system-libjpeg
|
||||||
|
-system-webp
|
||||||
|
-system-tiff
|
||||||
|
-no-feature-geoservices_mapbox
|
||||||
|
-no-feature-geoservices_mapboxgl
|
||||||
-qt-freetype
|
-qt-freetype
|
||||||
-openssl-runtime
|
-openssl-runtime
|
||||||
-android-arch ${ANDROID_ABI}
|
-verbose
|
||||||
-android-ndk-platform ${ANDROID_NDK_PLATFORM}
|
|
||||||
-recheck-all
|
|
||||||
-optimized-qmake
|
-optimized-qmake
|
||||||
-I${ANDROID_PREFIX}/include"
|
-I${ANDROID_PREFIX}/include"
|
||||||
|
|
||||||
|
# note: use -recheck-all and/or -redo to continue
|
||||||
|
|
||||||
[[ $ANDROID_DEBUG_BUILD ]] \
|
[[ $ANDROID_DEBUG_BUILD ]] \
|
||||||
&& configue_opts+=' -debug-and-release' \
|
&& configue_opts+=' -debug-and-release' \
|
||||||
|| configue_opts+=' -release'
|
|| configue_opts+=' -release'
|
||||||
|
@ -165,7 +172,9 @@ build() {
|
||||||
}
|
}
|
||||||
|
|
||||||
package() {
|
package() {
|
||||||
export ANDROID_MINIMUM_PLATFORM=${_android_platform}
|
export ANDROID_MINIMUM_PLATFORM=$_android_min_platform
|
||||||
|
export ANDROID_API_VERSION=android-$_android_api_platform
|
||||||
|
export ANDROID_NDK_PLATFORM=android-$_android_ndk_platform
|
||||||
source android-env ${_pkg_arch}
|
source android-env ${_pkg_arch}
|
||||||
|
|
||||||
cd ${_pkgfqn}
|
cd ${_pkgfqn}
|
||||||
|
|
|
@ -1,29 +0,0 @@
|
||||||
From dbe68d96e7da8ba5e5484e6ad0bbd78c9b0a8eec Mon Sep 17 00:00:00 2001
|
|
||||||
From: Martchus <martchus@gmx.net>
|
|
||||||
Date: Sun, 9 Dec 2018 14:29:59 +0100
|
|
||||||
Subject: [PATCH] Disable mapboxgl
|
|
||||||
|
|
||||||
---
|
|
||||||
src/plugins/geoservices/geoservices.pro | 9 ---------
|
|
||||||
1 file changed, 9 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/src/plugins/geoservices/geoservices.pro b/src/plugins/geoservices/geoservices.pro
|
|
||||||
index b81ad34a..98308c97 100644
|
|
||||||
--- a/src/plugins/geoservices/geoservices.pro
|
|
||||||
+++ b/src/plugins/geoservices/geoservices.pro
|
|
||||||
@@ -7,12 +7,3 @@ qtConfig(geoservices_mapbox): SUBDIRS += mapbox
|
|
||||||
qtConfig(geoservices_esri): SUBDIRS += esri
|
|
||||||
qtConfig(geoservices_itemsoverlay): SUBDIRS += itemsoverlay
|
|
||||||
qtConfig(geoservices_osm): SUBDIRS += osm
|
|
||||||
-
|
|
||||||
-qtConfig(geoservices_mapboxgl) {
|
|
||||||
- !exists(../../3rdparty/mapbox-gl-native/mapbox-gl-native.pro) {
|
|
||||||
- warning("Submodule mapbox-gl-native does not exist. Run 'git submodule update --init' on qtlocation.")
|
|
||||||
- } else {
|
|
||||||
- SUBDIRS += mapboxgl ../../3rdparty/mapbox-gl-native
|
|
||||||
- mapboxgl.depends = ../../3rdparty/mapbox-gl-native
|
|
||||||
- }
|
|
||||||
-}
|
|
||||||
--
|
|
||||||
2.23.0
|
|
||||||
|
|
|
@ -1,40 +0,0 @@
|
||||||
From 2c8ca36b5f87ccfc039c0b669c80f21205769758 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Martchus <martchus@gmx.net>
|
|
||||||
Date: Sun, 9 Dec 2018 14:28:07 +0100
|
|
||||||
Subject: [PATCH 1/4] Fix clang/libc++ build under Android
|
|
||||||
|
|
||||||
---
|
|
||||||
mkspecs/android-clang/qmake.conf | 7 +++++--
|
|
||||||
1 file changed, 5 insertions(+), 2 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/mkspecs/android-clang/qmake.conf b/mkspecs/android-clang/qmake.conf
|
|
||||||
index 05b7979142..83d030793b 100644
|
|
||||||
--- a/mkspecs/android-clang/qmake.conf
|
|
||||||
+++ b/mkspecs/android-clang/qmake.conf
|
|
||||||
@@ -30,11 +30,12 @@ QMAKE_CFLAGS += -gcc-toolchain $$NDK_TOOLCHAIN_PATH -fno-limit-debug-info
|
|
||||||
QMAKE_LINK = $$QMAKE_CXX $$QMAKE_CFLAGS -Wl,--exclude-libs,libgcc.a -Wl,--exclude-libs,libatomic.a -nostdlib++
|
|
||||||
equals(ANDROID_TARGET_ARCH, armeabi-v7a): QMAKE_LINK += -Wl,--exclude-libs,libunwind.a
|
|
||||||
|
|
||||||
-QMAKE_CFLAGS += -DANDROID_HAS_WSTRING --sysroot=$$NDK_ROOT/sysroot \
|
|
||||||
+QMAKE_CFLAGS += -DANDROID_HAS_WSTRING --sysroot=$$ANDROID_PLATFORM_ROOT_PATH \
|
|
||||||
-isystem $$NDK_ROOT/sysroot/usr/include/$$NDK_TOOLS_PREFIX \
|
|
||||||
-isystem $$NDK_ROOT/sources/cxx-stl/llvm-libc++/include \
|
|
||||||
-isystem $$NDK_ROOT/sources/android/support/include \
|
|
||||||
- -isystem $$NDK_ROOT/sources/cxx-stl/llvm-libc++abi/include
|
|
||||||
+ -isystem $$NDK_ROOT/sources/cxx-stl/llvm-libc++abi/include \
|
|
||||||
+ -isystem $$NDK_ROOT/sysroot/usr/include
|
|
||||||
|
|
||||||
ANDROID_SOURCES_CXX_STL_LIBDIR = $$NDK_ROOT/sources/cxx-stl/llvm-libc++/libs/$$ANDROID_TARGET_ARCH
|
|
||||||
|
|
||||||
@@ -44,6 +45,8 @@ ANDROID_USE_LLVM = true
|
|
||||||
|
|
||||||
exists($$ANDROID_SOURCES_CXX_STL_LIBDIR/libc++.so): \
|
|
||||||
ANDROID_CXX_STL_LIBS = -lc++
|
|
||||||
+else: exists($$ANDROID_SOURCES_CXX_STL_LIBDIR/libc++_shared.so): \
|
|
||||||
+ ANDROID_CXX_STL_LIBS = -lc++_shared
|
|
||||||
else: \
|
|
||||||
ANDROID_CXX_STL_LIBS = $$ANDROID_SOURCES_CXX_STL_LIBDIR/libc++.so.$$replace(ANDROID_PLATFORM, "android-", "")
|
|
||||||
|
|
||||||
--
|
|
||||||
2.23.0
|
|
||||||
|
|
|
@ -1,24 +1,27 @@
|
||||||
From a71a1223328539ee403884a24d1dbc5a685d40dd Mon Sep 17 00:00:00 2001
|
From f21b3b1871deae16696c427ca95ffd0ace0a4f70 Mon Sep 17 00:00:00 2001
|
||||||
From: Martchus <martchus@gmx.net>
|
From: Martchus <martchus@gmx.net>
|
||||||
Date: Sun, 7 Apr 2019 09:54:49 +0200
|
Date: Sun, 7 Apr 2019 09:54:49 +0200
|
||||||
Subject: [PATCH 3/4] Support pkg-config under Android
|
Subject: [PATCH 1/2] Support pkg-config under Android
|
||||||
|
|
||||||
from https://aur.archlinux.org/cgit/aur.git/commit/?h=android-aarch64-qt5&id=d901da324b2ceea2ac99b48137cb82b2bd920c77
|
from https://aur.archlinux.org/cgit/aur.git/commit/?h=android-aarch64-qt5&id=d901da324b2ceea2ac99b48137cb82b2bd920c77
|
||||||
|
|
||||||
|
Change-Id: I68ebfa818ab4eec34a170602ea2c1f4824e80213
|
||||||
---
|
---
|
||||||
mkspecs/android-clang/qmake.conf | 3 +++
|
mkspecs/android-clang/qmake.conf | 3 +++
|
||||||
1 file changed, 3 insertions(+)
|
1 file changed, 3 insertions(+)
|
||||||
|
|
||||||
diff --git a/mkspecs/android-clang/qmake.conf b/mkspecs/android-clang/qmake.conf
|
diff --git a/mkspecs/android-clang/qmake.conf b/mkspecs/android-clang/qmake.conf
|
||||||
index 83d030793b..8f145a2bb7 100644
|
index 5cc5a20f71..c8725f1b6d 100644
|
||||||
--- a/mkspecs/android-clang/qmake.conf
|
--- a/mkspecs/android-clang/qmake.conf
|
||||||
+++ b/mkspecs/android-clang/qmake.conf
|
+++ b/mkspecs/android-clang/qmake.conf
|
||||||
@@ -53,3 +53,6 @@ else: \
|
@@ -113,4 +113,7 @@ x86_64.dir_affix = x86_64
|
||||||
QMAKE_CFLAGS_OPTIMIZE_SIZE = -Oz
|
x86_64.CONFIG = x86_64
|
||||||
|
x86_64.deployment_identifier = x86_64
|
||||||
|
|
||||||
include(../common/android-base-tail.conf)
|
|
||||||
+
|
|
||||||
+QMAKE_PKG_CONFIG = $$[QT_INSTALL_PREFIX]
|
+QMAKE_PKG_CONFIG = $$[QT_INSTALL_PREFIX]
|
||||||
+QMAKE_PKG_CONFIG = android-$$section(QMAKE_PKG_CONFIG, /, 3, 3)-pkg-config
|
+QMAKE_PKG_CONFIG = android-$$section(QMAKE_PKG_CONFIG, /, 3, 3)-pkg-config
|
||||||
|
+
|
||||||
|
load(qt_config)
|
||||||
--
|
--
|
||||||
2.23.0
|
2.28.0
|
||||||
|
|
|
@ -1,34 +0,0 @@
|
||||||
From 996c53a388705a0bbf778faaf7660efad98e1eff Mon Sep 17 00:00:00 2001
|
|
||||||
From: Martchus <martchus@gmx.net>
|
|
||||||
Date: Sun, 9 Dec 2018 14:31:30 +0100
|
|
||||||
Subject: [PATCH 2/4] Fix androiddeployqt search paths
|
|
||||||
|
|
||||||
---
|
|
||||||
src/tools/androiddeployqt/main.cpp | 4 ++--
|
|
||||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/src/tools/androiddeployqt/main.cpp b/src/tools/androiddeployqt/main.cpp
|
|
||||||
index 01c392f8f9..9600d657cb 100644
|
|
||||||
--- a/src/tools/androiddeployqt/main.cpp
|
|
||||||
+++ b/src/tools/androiddeployqt/main.cpp
|
|
||||||
@@ -1721,7 +1721,7 @@ bool scanImports(Options *options, QSet<QString> *usedDependencies)
|
|
||||||
rootPath += QLatin1Char('/');
|
|
||||||
|
|
||||||
QStringList importPaths;
|
|
||||||
- importPaths += shellQuote(options->qtInstallDirectory + QLatin1String("/qml"));
|
|
||||||
+ importPaths += shellQuote(options->qtInstallDirectory + QLatin1String("/lib/qt/qml"));
|
|
||||||
importPaths += shellQuote(rootPath);
|
|
||||||
for (const QString &qmlImportPath : qAsConst(options->qmlImportPaths))
|
|
||||||
importPaths += shellQuote(qmlImportPath);
|
|
||||||
@@ -1857,7 +1857,7 @@ bool readDependencies(Options *options)
|
|
||||||
return false;
|
|
||||||
|
|
||||||
// Jam in the dependencies of the platform plugin, since the application will crash without it
|
|
||||||
- if (!readDependenciesFromElf(options, options->qtInstallDirectory + QLatin1String("/plugins/platforms/android/libqtforandroid.so"), &usedDependencies, &remainingDependencies))
|
|
||||||
+ if (!readDependenciesFromElf(options, options->qtInstallDirectory + QLatin1String("/lib/qt/plugins/platforms/android/libqtforandroid.so"), &usedDependencies, &remainingDependencies))
|
|
||||||
return false;
|
|
||||||
|
|
||||||
while (!remainingDependencies.isEmpty()) {
|
|
||||||
--
|
|
||||||
2.23.0
|
|
||||||
|
|
|
@ -0,0 +1,50 @@
|
||||||
|
From 95b37ab2ddb476326fd803c7b0551ac3b88215b9 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Martchus <martchus@gmx.net>
|
||||||
|
Date: Wed, 16 Sep 2020 18:18:26 +0200
|
||||||
|
Subject: [PATCH 2/2] Force 64-bit atomics usage
|
||||||
|
|
||||||
|
From hipersayan_x's AUR package (added with 5.14.2 update).
|
||||||
|
|
||||||
|
Change-Id: I0c94983b5ddc2897eeabbd6ef4703f455d23f9a2
|
||||||
|
---
|
||||||
|
src/corelib/configure.json | 16 +++-------------
|
||||||
|
1 file changed, 3 insertions(+), 13 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/src/corelib/configure.json b/src/corelib/configure.json
|
||||||
|
index c5e0423273..bd7ef73fe0 100644
|
||||||
|
--- a/src/corelib/configure.json
|
||||||
|
+++ b/src/corelib/configure.json
|
||||||
|
@@ -135,27 +135,17 @@
|
||||||
|
"label": "64 bit atomics",
|
||||||
|
"test": {
|
||||||
|
"tail": [
|
||||||
|
- "void test(volatile std::atomic<std::int64_t> &a)",
|
||||||
|
+ "void test()",
|
||||||
|
"{",
|
||||||
|
- " std::int64_t v = a.load(std::memory_order_acquire);",
|
||||||
|
- " while (!a.compare_exchange_strong(v, v + 1,",
|
||||||
|
- " std::memory_order_acq_rel,",
|
||||||
|
- " std::memory_order_acquire)) {",
|
||||||
|
- " v = a.exchange(v - 1);",
|
||||||
|
- " }",
|
||||||
|
- " a.store(v + 1, std::memory_order_release);",
|
||||||
|
"}"
|
||||||
|
],
|
||||||
|
"main": [
|
||||||
|
- "void *ptr = (void*)0xffffffc0; // any random pointer",
|
||||||
|
- "test(*reinterpret_cast<std::atomic<std::int64_t> *>(ptr));"
|
||||||
|
+ "test();"
|
||||||
|
],
|
||||||
|
"qmake": "CONFIG += c++11"
|
||||||
|
},
|
||||||
|
- "headers": [ "atomic", "cstdint" ],
|
||||||
|
"sources": [
|
||||||
|
- "",
|
||||||
|
- "-latomic"
|
||||||
|
+ ""
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"librt": {
|
||||||
|
--
|
||||||
|
2.28.0
|
||||||
|
|
|
@ -1,24 +0,0 @@
|
||||||
From 9cd435c730949e29104bbfa2bdd82ed2c662ca3d Mon Sep 17 00:00:00 2001
|
|
||||||
From: Martchus <martchus@gmx.net>
|
|
||||||
Date: Sat, 7 Sep 2019 13:21:37 +0200
|
|
||||||
Subject: [PATCH 4/4] Use pkg-config to find libjpeg
|
|
||||||
|
|
||||||
---
|
|
||||||
src/gui/configure.json | 1 +
|
|
||||||
1 file changed, 1 insertion(+)
|
|
||||||
|
|
||||||
diff --git a/src/gui/configure.json b/src/gui/configure.json
|
|
||||||
index 6280b4dfa2..206f83984a 100644
|
|
||||||
--- a/src/gui/configure.json
|
|
||||||
+++ b/src/gui/configure.json
|
|
||||||
@@ -373,6 +373,7 @@
|
|
||||||
},
|
|
||||||
"headers": "jpeglib.h",
|
|
||||||
"sources": [
|
|
||||||
+ { "type": "pkgConfig", "args": "libjpeg" },
|
|
||||||
{ "libs": "-llibjpeg", "condition": "config.msvc" },
|
|
||||||
"-ljpeg"
|
|
||||||
]
|
|
||||||
--
|
|
||||||
2.23.0
|
|
||||||
|
|
|
@ -7,10 +7,12 @@
|
||||||
|
|
||||||
_pkg_arch=x86-64
|
_pkg_arch=x86-64
|
||||||
_android_arch=x86_64
|
_android_arch=x86_64
|
||||||
_android_platform=22
|
_android_min_platform=24
|
||||||
|
_android_api_platform=30
|
||||||
|
_android_ndk_platform=$_android_min_platform
|
||||||
|
|
||||||
pkgname=android-$_pkg_arch-qt5
|
pkgname=android-$_pkg_arch-qt5
|
||||||
pkgver=5.13.1
|
pkgver=5.15.1
|
||||||
pkgrel=1
|
pkgrel=1
|
||||||
pkgdesc="Qt 5 for Android"
|
pkgdesc="Qt 5 for Android"
|
||||||
arch=('x86_64')
|
arch=('x86_64')
|
||||||
|
@ -25,20 +27,23 @@ makedepends=('libgl'
|
||||||
'gperf'
|
'gperf'
|
||||||
'libxslt'
|
'libxslt'
|
||||||
'fontconfig'
|
'fontconfig'
|
||||||
|
'ninja'
|
||||||
'java-environment-openjdk<=8'
|
'java-environment-openjdk<=8'
|
||||||
'android-environment'
|
'android-environment'
|
||||||
'android-pkg-config'
|
'android-pkg-config')
|
||||||
"android-$_pkg_arch-openssl")
|
|
||||||
depends=('java-runtime-headless-openjdk<=8'
|
depends=('java-runtime-headless-openjdk<=8'
|
||||||
'apache-ant'
|
'apache-ant'
|
||||||
'android-ndk'
|
'android-ndk'
|
||||||
"android-platform-$_android_platform"
|
|
||||||
'android-sdk'
|
'android-sdk'
|
||||||
'android-sdk-build-tools'
|
'android-sdk-build-tools'
|
||||||
'android-sdk-platform-tools'
|
'android-sdk-platform-tools'
|
||||||
"android-$_pkg_arch-zlib"
|
'android-platform'
|
||||||
|
"android-$_pkg_arch-libjpeg-turbo"
|
||||||
"android-$_pkg_arch-libpng"
|
"android-$_pkg_arch-libpng"
|
||||||
"android-$_pkg_arch-libjpeg-turbo")
|
"android-$_pkg_arch-libwebp"
|
||||||
|
"android-$_pkg_arch-libtiff"
|
||||||
|
"android-$_pkg_arch-openssl"
|
||||||
|
"android-$_pkg_arch-zlib")
|
||||||
groups=('android-qt5')
|
groups=('android-qt5')
|
||||||
conflicts=("android-qt5-${_android_arch}")
|
conflicts=("android-qt5-${_android_arch}")
|
||||||
replaces=("android-qt5-${_android_arch}")
|
replaces=("android-qt5-${_android_arch}")
|
||||||
|
@ -68,51 +73,47 @@ optdepends+=("android-$_pkg_arch-openssl: SSL support for Qt Network")
|
||||||
options=(!strip !buildflags staticlibs !emptydirs)
|
options=(!strip !buildflags staticlibs !emptydirs)
|
||||||
_pkgfqn="qt-everywhere-src-${pkgver}"
|
_pkgfqn="qt-everywhere-src-${pkgver}"
|
||||||
source=("http://download.qt-project.org/official_releases/qt/${pkgver:0:4}/${pkgver}/single/${_pkgfqn}.tar.xz"
|
source=("http://download.qt-project.org/official_releases/qt/${pkgver:0:4}/${pkgver}/single/${_pkgfqn}.tar.xz"
|
||||||
'0001-Fix-clang-libc-build-under-Android.patch'
|
'0001-Support-pkg-config-under-Android.patch'
|
||||||
'0002-Fix-androiddeployqt-search-paths.patch'
|
'0002-Force-64-bit-atomics-usage.patch')
|
||||||
'0003-Support-pkg-config-under-Android.patch'
|
sha256sums=('44da876057e21e1be42de31facd99be7d5f9f07893e1ea762359bcee0ef64ee9'
|
||||||
'0004-Use-pkg-config-to-find-libjpeg.patch'
|
'435047d2f09baf2e706c86604c944686e71ab6d7678203b68e7d28af7beb5ce8'
|
||||||
'0001-Disable-mapboxgl.patch')
|
'1f0aab5dcf7976285ffbb9069f127087f15d60a23485fadf17312090453d6784')
|
||||||
sha256sums=('adf00266dc38352a166a9739f1a24a1e36f1be9c04bf72e16e142a256436974e'
|
|
||||||
'29bcb93f9c79ad4b0709efa42694ed917b6e4cfce69a805e79a7dc3144be7765'
|
|
||||||
'7a5520311ba2edee2ffcd546cd6e08248c8f73deed33bd8075649577f8cb1446'
|
|
||||||
'5c3f0725f3c27263661ff5ebb4b279e4483de8ed70dee4fe42a84d31b3f2e4a9'
|
|
||||||
'4f3ba22616040a2979bfdf840b44bf105374ea2fac866c42977ad7ec6e87ddcc'
|
|
||||||
'6151b784050f9d4ef3eec22dd33360d3f566d4834592f1171df91a10c95fab77')
|
|
||||||
|
|
||||||
prepare() {
|
prepare() {
|
||||||
export ANDROID_MINIMUM_PLATFORM=${_android_platform}
|
export ANDROID_MINIMUM_PLATFORM=$_android_min_platform
|
||||||
|
export ANDROID_API_VERSION=android-$_android_api_platform
|
||||||
|
export ANDROID_NDK_PLATFORM=android-$_android_ndk_platform
|
||||||
source android-env ${_pkg_arch}
|
source android-env ${_pkg_arch}
|
||||||
|
|
||||||
|
check_ndk_version_ge_than 18.0
|
||||||
|
check_android_platform
|
||||||
|
|
||||||
cd ${_pkgfqn}
|
cd ${_pkgfqn}
|
||||||
|
|
||||||
pushd qtbase
|
pushd qtbase
|
||||||
patch -Np1 -i "../../0001-Fix-clang-libc-build-under-Android.patch"
|
patch -Np1 -i "../../0001-Support-pkg-config-under-Android.patch"
|
||||||
#patch -Np1 -i "../../0002-Fix-androiddeployqt-search-paths.patch"
|
case "$_android_arch" in
|
||||||
patch -Np1 -i "../../0003-Support-pkg-config-under-Android.patch"
|
aarch64 | x86-64)
|
||||||
patch -Np1 -i "../../0004-Use-pkg-config-to-find-libjpeg.patch"
|
patch -Np1 -i "../../0002-Force-64-bit-atomics-usage.patch"
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
;;
|
||||||
|
esac
|
||||||
popd
|
popd
|
||||||
|
|
||||||
pushd qtlocation
|
sed -i "s/android-21/android-$ANDROID_MINIMUM_PLATFORM/g" qtbase/configure.pri
|
||||||
# skip building mapboxgl as it increases compile time significantly and
|
|
||||||
# likely not a lot of people actually using it; if you need it, just remove the
|
|
||||||
# following line:
|
|
||||||
patch -Np1 -i "../../0001-Disable-mapboxgl.patch"
|
|
||||||
popd
|
|
||||||
|
|
||||||
sed -i "s/android-16/android-$ANDROID_MINIMUM_PLATFORM/g" qtbase/mkspecs/features/android/sdk.prf
|
|
||||||
sed -i "s/android-16/android-$ANDROID_MINIMUM_PLATFORM/g" qtbase/src/android/jar/jar.pro
|
|
||||||
sed -i "s/android-16/android-$ANDROID_MINIMUM_PLATFORM/g" qtgamepad/src/plugins/gamepads/android/jar/jar.pro
|
|
||||||
sed -i "s/android-16/android-$ANDROID_MINIMUM_PLATFORM/g" qtbase/configure.pri
|
|
||||||
}
|
}
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
export ANDROID_MINIMUM_PLATFORM=${_android_platform}
|
export ANDROID_MINIMUM_PLATFORM=$_android_min_platform
|
||||||
|
export ANDROID_API_VERSION=android-$_android_api_platform
|
||||||
|
export ANDROID_NDK_PLATFORM=android-$_android_ndk_platform
|
||||||
source android-env ${_pkg_arch}
|
source android-env ${_pkg_arch}
|
||||||
|
|
||||||
unset CC CXX CFLAGS CXXFLAGS LDFLAGS CHOST QMAKESPEC QTDIR CARCH
|
unset CC CXX CFLAGS CXXFLAGS LDFLAGS CHOST QMAKESPEC QTDIR CARCH
|
||||||
|
|
||||||
export PKG_CONFIG=$ANDROID_PKGCONFIG
|
export PKG_CONFIG=$ANDROID_PKGCONFIG
|
||||||
|
export ANDROID_TARGET_ARCH=${ANDROID_ABI}
|
||||||
export PYTHON=/usr/bin/python2
|
export PYTHON=/usr/bin/python2
|
||||||
|
|
||||||
cd ${_pkgfqn}
|
cd ${_pkgfqn}
|
||||||
|
@ -126,24 +127,30 @@ build() {
|
||||||
-xplatform android-clang
|
-xplatform android-clang
|
||||||
-nomake tests
|
-nomake tests
|
||||||
-nomake examples
|
-nomake examples
|
||||||
-android-ndk ${ANDROID_NDK_HOME}
|
|
||||||
-android-sdk ${ANDROID_HOME}
|
-android-sdk ${ANDROID_HOME}
|
||||||
|
-android-ndk ${ANDROID_NDK_HOME}
|
||||||
-android-ndk-host linux-x86_64
|
-android-ndk-host linux-x86_64
|
||||||
-android-toolchain-version 4.9
|
-android-ndk-platform ${ANDROID_NDK_PLATFORM}
|
||||||
|
-android-abis ${ANDROID_ABI}
|
||||||
-skip qtserialport
|
-skip qtserialport
|
||||||
|
-skip qtwebengine
|
||||||
-no-warnings-are-errors
|
-no-warnings-are-errors
|
||||||
-pkg-config
|
-pkg-config
|
||||||
-system-zlib
|
-system-zlib
|
||||||
-system-libpng
|
-system-libpng
|
||||||
-system-libjpeg
|
-system-libjpeg
|
||||||
|
-system-webp
|
||||||
|
-system-tiff
|
||||||
|
-no-feature-geoservices_mapbox
|
||||||
|
-no-feature-geoservices_mapboxgl
|
||||||
-qt-freetype
|
-qt-freetype
|
||||||
-openssl-runtime
|
-openssl-runtime
|
||||||
-android-arch ${ANDROID_ABI}
|
-verbose
|
||||||
-android-ndk-platform ${ANDROID_NDK_PLATFORM}
|
|
||||||
-recheck-all
|
|
||||||
-optimized-qmake
|
-optimized-qmake
|
||||||
-I${ANDROID_PREFIX}/include"
|
-I${ANDROID_PREFIX}/include"
|
||||||
|
|
||||||
|
# note: use -recheck-all and/or -redo to continue
|
||||||
|
|
||||||
[[ $ANDROID_DEBUG_BUILD ]] \
|
[[ $ANDROID_DEBUG_BUILD ]] \
|
||||||
&& configue_opts+=' -debug-and-release' \
|
&& configue_opts+=' -debug-and-release' \
|
||||||
|| configue_opts+=' -release'
|
|| configue_opts+=' -release'
|
||||||
|
@ -165,7 +172,9 @@ build() {
|
||||||
}
|
}
|
||||||
|
|
||||||
package() {
|
package() {
|
||||||
export ANDROID_MINIMUM_PLATFORM=${_android_platform}
|
export ANDROID_MINIMUM_PLATFORM=$_android_min_platform
|
||||||
|
export ANDROID_API_VERSION=android-$_android_api_platform
|
||||||
|
export ANDROID_NDK_PLATFORM=android-$_android_ndk_platform
|
||||||
source android-env ${_pkg_arch}
|
source android-env ${_pkg_arch}
|
||||||
|
|
||||||
cd ${_pkgfqn}
|
cd ${_pkgfqn}
|
||||||
|
|
Loading…
Reference in New Issue