mirror of
https://github.com/subsurface/subsurface.git
synced 2024-11-30 22:20:21 +00:00
build-system/iOS: build Kirigami separately for iOS as well
Since the integrated build no longer seems to work, this creates a separate Kirigami build using qmake (as I couldn't make Kirigami's cmake build work). The install target tries to install into the Qt install which may not be possible with a user account, so this instead uses the built library directly. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
320b4a77ef
commit
80b5e7990a
2 changed files with 22 additions and 2 deletions
|
@ -372,6 +372,7 @@ ios {
|
|||
../install-root/ios/lib/libgit2.a \
|
||||
../install-root/ios/lib/libzip.a \
|
||||
../install-root/ios/lib/libxslt.a \
|
||||
../install-root/ios/lib/qml/org/kde/kirigami.2/libkirigamiplugin.a \
|
||||
../googlemaps/build-ios/libqtgeoservices_googlemaps.a \
|
||||
-liconv \
|
||||
-lsqlite3 \
|
||||
|
|
|
@ -125,7 +125,6 @@ for ARCH in $ARCHS; do
|
|||
declare -x CXXFLAGS="$CFLAGS"
|
||||
declare -x LDFLAGS="$CFLAGS -lsqlite3 -lpthread -lc++ -L$SDK_DIR/usr/lib -fembed-bitcode"
|
||||
|
||||
|
||||
# openssl build stuff.
|
||||
export DEVELOPER=$(xcode-select --print-path)\
|
||||
export IPHONEOS_SDK_VERSION=$(xcrun --sdk iphoneos --show-sdk-version)
|
||||
|
@ -261,13 +260,33 @@ if [ "$DEBUGRELEASE" != "Release" ] ; then
|
|||
fi
|
||||
popd
|
||||
|
||||
# build Kirigami
|
||||
mkdir -p "$PARENT_DIR"/kirigami-build
|
||||
pushd "$PARENT_DIR"/kirigami-build
|
||||
"$IOS_QT"/"$QT_VERSION"/ios/bin/qmake "$SUBSURFACE_SOURCE"/mobile-widgets/3rdparty/kirigami/kirigami.pro CONFIG+=release
|
||||
make
|
||||
#make install
|
||||
if [ "$DEBUGRELEASE" != "Release" ] ; then
|
||||
"$IOS_QT"/"$QT_VERSION"/ios/bin/qmake "$SUBSURFACE_SOURCE"/mobile-widgets/3rdparty/kirigami/kirigami.pro CONFIG+=debug
|
||||
make clean
|
||||
make
|
||||
#make install
|
||||
fi
|
||||
# since the install prefix for qmake is rather weirdly implemented, let's copy things by hand into the multiarch destination
|
||||
mkdir -p "$INSTALL_ROOT"/../lib/qml/
|
||||
cp -a org "$INSTALL_ROOT"/../lib/qml/
|
||||
popd
|
||||
|
||||
# now combine the libraries into fat libraries
|
||||
ARCH_ROOT=$PARENT_DIR/install-root/ios
|
||||
cp -a "$ARCH_ROOT"/x86_64/* "$ARCH_ROOT"
|
||||
if [ "$TARGET" = "iphoneos" ] ; then
|
||||
pushd "$ARCH_ROOT"/lib
|
||||
for LIB in $(find . -type f -name \*.a); do
|
||||
lipo "$ARCH_ROOT"/armv7/lib/"$LIB" "$ARCH_ROOT"/arm64/lib/"$LIB" "$ARCH_ROOT"/x86_64/lib/"$LIB" -create -output "$LIB"
|
||||
# libkirigamiplugin is already a fat library
|
||||
if grep -v -q "kirigami" <<< "$LIB" ; then
|
||||
lipo "$ARCH_ROOT"/armv7/lib/"$LIB" "$ARCH_ROOT"/arm64/lib/"$LIB" "$ARCH_ROOT"/x86_64/lib/"$LIB" -create -output "$LIB"
|
||||
fi
|
||||
done
|
||||
popd
|
||||
fi
|
||||
|
|
Loading…
Reference in a new issue