Commit 416ebed7 authored by Linus Jahn's avatar Linus Jahn

ci: appimage: Add build job, Drop fuse dependency

By default it now will use /usr as Qt install path. Also the fuse
dependency isn't needed anymore (didn't work in docker); we're just
extracting the image now (thanks to JBB).
parent 892f59f2
Pipeline #3194 passed with stage
in 5 minutes and 24 seconds
linux-appimage:
image: kaidan/ubuntu-trusty
script:
- utils/build-linux-appimage.sh
variables:
QT_LINUX: /opt/qt510
artifacts:
paths:
- "*.AppImage"
expire_in: 1 week
click-xenial: click-xenial:
image: kaidan/ubuntu-touch-xenial image: kaidan/ubuntu-touch-xenial
script: script:
......
...@@ -2,12 +2,11 @@ ...@@ -2,12 +2,11 @@
# NOTE: To use this script, you need to set $QT_LINUX to your Qt for Linux installation # NOTE: To use this script, you need to set $QT_LINUX to your Qt for Linux installation
if [ -z "$QT_LINUX" ]; then # Path to Qt installation
echo "QT_LINUX has to be set" QT_LINUX=${QT_LINUX:-/usr}
exit 1 echo Using Qt installation from $QT_LINUX
fi
# Build type is one of: # Build type is one of:
# Debug, Release, RelWithDebInfo and MinSizeRel # Debug, Release, RelWithDebInfo and MinSizeRel
BUILD_TYPE="${BUILD_TYPE:-Debug}" BUILD_TYPE="${BUILD_TYPE:-Debug}"
...@@ -31,12 +30,6 @@ if [ ! -d "$KAIDAN_SOURCES/3rdparty/qxmpp/.git" ]; then ...@@ -31,12 +30,6 @@ if [ ! -d "$KAIDAN_SOURCES/3rdparty/qxmpp/.git" ]; then
git clone https://github.com/qxmpp-project/qxmpp.git 3rdparty/qxmpp git clone https://github.com/qxmpp-project/qxmpp.git 3rdparty/qxmpp
fi fi
if [ ! -f "$KAIDAN_SOURCES/3rdparty/linuxdeployqt-continuous-x86_64.AppImage" ]; then
echo "Downloading linuxdeployqt"
wget -P $KAIDAN_SOURCES/3rdparty/ https://github.com/probonopd/linuxdeployqt/releases/download/continuous/linuxdeployqt-continuous-x86_64.AppImage
chmod +x $KAIDAN_SOURCES/3rdparty/linuxdeployqt-continuous-x86_64.AppImage
fi
cdnew() { cdnew() {
if [ -d "$1" ]; then if [ -d "$1" ]; then
rm -rf "$1" rm -rf "$1"
...@@ -45,6 +38,17 @@ cdnew() { ...@@ -45,6 +38,17 @@ cdnew() {
cd $1 cd $1
} }
if [ ! -f "$KAIDAN_SOURCES/3rdparty/linuxdeployqt/squashfs-root/AppRun" ]; then
echo "Downloading linuxdeployqt"
wget --continue -P $KAIDAN_SOURCES/3rdparty/ https://github.com/probonopd/linuxdeployqt/releases/download/continuous/linuxdeployqt-continuous-x86_64.AppImage
chmod +x $KAIDAN_SOURCES/3rdparty/linuxdeployqt-continuous-x86_64.AppImage
echo "Extracting linuxdeployqt"
cdnew $KAIDAN_SOURCES/3rdparty/linuxdeployqt
$KAIDAN_SOURCES/3rdparty/linuxdeployqt-continuous-x86_64.AppImage --appimage-extract
cd $KAIDAN_SOURCES
fi
export QT_SELECT=qt5 export QT_SELECT=qt5
if [ ! -f "$QXMPP_BUILD/lib/pkgconfig/qxmpp.pc" ]; then if [ ! -f "$QXMPP_BUILD/lib/pkgconfig/qxmpp.pc" ]; then
...@@ -55,7 +59,7 @@ echo "*****************************************" ...@@ -55,7 +59,7 @@ echo "*****************************************"
cdnew $KAIDAN_SOURCES/3rdparty/qxmpp/build cdnew $KAIDAN_SOURCES/3rdparty/qxmpp/build
cmake .. \ cmake .. \
-DCMAKE_PREFIX_PATH=$QT_LINUX \ -DCMAKE_PREFIX_PATH=$QT_LINUX \
-DBUILD_EXAMPLES=OFF \ -DBUILD_EXAMPLES=OFF -DBUILD_TESTS=OFF \
-DCMAKE_BUILD_TYPE=$BUILD_TYPE -DCMAKE_INSTALL_PREFIX=$QXMPP_BUILD \ -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DCMAKE_INSTALL_PREFIX=$QXMPP_BUILD \
-DCMAKE_INSTALL_LIBDIR=$QXMPP_BUILD/lib -DCMAKE_INSTALL_LIBDIR=$QXMPP_BUILD/lib
...@@ -97,7 +101,7 @@ echo "*****************************************" ...@@ -97,7 +101,7 @@ echo "*****************************************"
-DCMAKE_PREFIX_PATH=$QT_LINUX\;$KIRIGAMI_BUILD\;$QXMPP_BUILD \ -DCMAKE_PREFIX_PATH=$QT_LINUX\;$KIRIGAMI_BUILD\;$QXMPP_BUILD \
-DI18N=1 \ -DI18N=1 \
-DCMAKE_BUILD_TYPE=$BUILD_TYPE -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DCMAKE_INSTALL_PREFIX=/usr
make -j$(nproc) make -j$(nproc)
} }
fi fi
...@@ -119,6 +123,10 @@ echo "*****************************************" ...@@ -119,6 +123,10 @@ echo "*****************************************"
cd $KAIDAN_SOURCES cd $KAIDAN_SOURCES
export LD_LIBRARY_PATH=$QT_LINUX/lib/:$KIRIGAMI_BUILD/lib:$LD_LIBRARY_PATH export LD_LIBRARY_PATH=$QT_LINUX/lib/:$KIRIGAMI_BUILD/lib:$LD_LIBRARY_PATH
export PATH=$QT_LINUX/bin/:$PATH export PATH=$QT_LINUX/bin/:$PATH
$KAIDAN_SOURCES/3rdparty/linuxdeployqt-continuous-x86_64.AppImage $KAIDAN_SOURCES/AppDir/usr/share/applications/kaidan.desktop -qmake=$QT_LINUX/bin/qmake -qmldir=$KAIDAN_SOURCES/src/qml/ -qmlimport=$KIRIGAMI_BUILD/lib/qml/ -appimage -no-copy-copyright-files $KAIDAN_SOURCES/3rdparty/linuxdeployqt/squashfs-root/AppRun \
$KAIDAN_SOURCES/AppDir/usr/share/applications/kaidan.desktop \
-qmldir=$KAIDAN_SOURCES/src/qml/ \
-qmlimport=$(find $KIRIGAMI_BUILD -type d -name qml) \
-appimage -no-copy-copyright-files
} }
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment