From ef27979df0a0efe4f50cacee73dda5fe47e28a48 Mon Sep 17 00:00:00 2001 From: Camila Date: Tue, 9 Aug 2022 15:19:51 +0200 Subject: [PATCH] Remove libglib-2.0.so.0 and libgobject-2.0.so.0 from Appimage. Patch from contributor at nextcloud/client-building/pull/105. Signed-off-by: Camila --- admin/linux/build-appimage.sh | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/admin/linux/build-appimage.sh b/admin/linux/build-appimage.sh index d9d18143b10b0..ec6ce62c5ef08 100755 --- a/admin/linux/build-appimage.sh +++ b/admin/linux/build-appimage.sh @@ -91,10 +91,12 @@ cp -P /usr/local/lib*/libcrypto.so* ./usr/lib/ cp -P -r /usr/lib/x86_64-linux-gnu/nss ./usr/lib/ # Use linuxdeployqt to deploy -wget --ca-directory=/etc/ssl/certs -c "https://github.com/probonopd/linuxdeployqt/releases/download/continuous/linuxdeployqt-continuous-x86_64.AppImage" -chmod a+x linuxdeployqt*.AppImage -./linuxdeployqt-continuous-x86_64.AppImage --appimage-extract -rm ./linuxdeployqt-continuous-x86_64.AppImage +LINUXDEPLOYQT_VERSION="continuous" +wget -O linuxdeployqt.AppImage --ca-directory=/etc/ssl/certs -c "https://github.com/probonopd/linuxdeployqt/releases/download/${LINUXDEPLOYQT_VERSION}/linuxdeployqt-continuous-x86_64.AppImage" +chmod a+x linuxdeployqt.AppImage +./linuxdeployqt.AppImage --appimage-extract +rm ./linuxdeployqt.AppImage +cp -r ./squashfs-root ./linuxdeployqt-squashfs-root unset QTDIR; unset QT_PLUGIN_PATH ; unset LD_LIBRARY_PATH export LD_LIBRARY_PATH=/usr/lib/ ./squashfs-root/AppRun ${DESKTOP_FILE} -bundle-non-qt-libs -qmldir=${DESKTOP_CLIENT_ROOT}/src/gui @@ -105,6 +107,15 @@ export LD_LIBRARY_PATH=/usr/lib/ # Build AppImage ./squashfs-root/AppRun ${DESKTOP_FILE} -appimage -updateinformation="gh-releases-zsync|nextcloud-releases|desktop|latest|Nextcloud-*-x86_64.AppImage.zsync" +# Workaround issue #103 +rm -rf ./squashfs-root +APPIMAGE=$(ls Nextcloud*.AppImage) +"./${APPIMAGE}" --appimage-extract +rm "./${APPIMAGE}" +rm ./squashfs-root/usr/lib/libglib-2.0.so.0 +rm ./squashfs-root/usr/lib/libgobject-2.0.so.0 +PATH=./linuxdeployqt-squashfs-root/usr/bin:$PATH appimagetool -n ./squashfs-root "$APPIMAGE" + #move AppImage if [ ! -z "$DRONE_COMMIT" ] then