Page MenuHome GnuPG

No OneTemporary

diff --git a/src/appimage/appimage.mk.in b/src/appimage/appimage.mk.in
index 4213363c..09106bc0 100644
--- a/src/appimage/appimage.mk.in
+++ b/src/appimage/appimage.mk.in
@@ -1,400 +1,401 @@
# appimage.m4.in - Makefile for building AppImage of Kleopatra. -*- makefile -*-
# Copyright (C) 2005, 2009, 2021 g10 Code GmbH
#
# Software engineering by Ingo Klöcker <dev@ingo-kloecker.de>
#
# This file is part of Gpg4win.
#
# Gpg4win is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# Gpg4win is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, see <https://www.gnu.org/licenses/>.
#
# SPDX-License-Identifier: GPL-2.0+
# No servicable parts below this line :)
# We collect the names of all pkg files used.
pkg_files =
# Frob the name $1 by converting all '-' and '+' characters to '_'.
define FROB_macro
$(subst +,_,$(subst -,_,$(1)))
endef
# Get the variable $(1) (which may contain '-' and '+' characters).
define GETVAR
$($(call FROB_macro,$(1)))
endef
# Set a couple of common variables.
# Most of them describe package specific directories and are derived
# from the the macros set in the Makefile.am.
define SETVARS
set -e; \
set -o pipefail; \
pkg="$(call GETVAR,appimage_pkg_$(1))"; \
pkg_version="$(1)-$(call GETVAR,appimage_pkg_$(1)_version)"; \
pkglogdir="$(logdir)/$$$${pkg_version}"; \
pkgsdir="$(bdir)/$$$${pkg_version}"; \
pkgbdir="$(bdir)/$$$${pkg_version}-build"; \
pkgpatdir="$(patdir)/$$$${pkg_version}"; \
pkgpatbdir="$(patdir)/$(1)"; \
pkgidir="$(ipdir)/$$$${pkg_version}"; \
pkginstallroot="/tmp/$$$${pkg_version}"; \
pkgbladir="/tmp/$$$${pkg_version}/$(idir)"; \
pkgcfg="$(call GETVAR,appimage_pkg_$(1)_configure)"; \
pkgextracflags="$(call GETVAR,appimage_pkg_$(1)_extracflags)"; \
pkgmkargs="$(call GETVAR,appimage_pkg_$(1)_make_args)"; \
pkgmkargs_inst="$(call GETVAR,appimage_pkg_$(1)_make_args_inst)";\
pkgmkdir="$(call GETVAR,appimage_pkg_$(1)_make_dir)"; \
pkgmkdir_inst="$(call GETVAR,appimage_pkg_$(1)_make_dir)"; \
pkgrsyncfilter="$(rsyncfilterdir)/$(1).rsync-filter"; \
pkg_conf_subdir="$(call GETVAR,appimage_pkg_$(1)_conf_subdir)"; \
export PKG_CONFIG_PATH="$(idir)/lib/pkgconfig:$(idir)/lib64/pkgconfig"; \
export FREETYPE_DIR="$(idir)" \
export PATH="$(idir)/bin:$${PATH}"
endef
# Support macro. Unpack the archive $(1).
define DEFLATE_macro
rm -rf $$$${pkgsdir}; \
case "$(1)" in \
*/qtbase*.*.tar.xz) \
$(TAR) -xJ --transform='s,^qtbase-everywhere-src,qtbase,' -f "$(1)" ;; \
*/qttools*.*.tar.xz) \
$(TAR) -xJ --transform='s,^qttools-everywhere-src,qttools,' -f "$(1)" ;; \
*/qtx11extras*.*.tar.xz) \
$(TAR) -xJ --transform='s,^qtx11extras-everywhere-src,qtx11extras,' -f "$(1)" ;; \
*/qtwayland*.*.tar.xz) \
$(TAR) -xJ --transform='s,^qtwayland-everywhere-src,qtwayland,' -f "$(1)" ;; \
*/qtsvg*.*.tar.xz) \
$(TAR) -xJ --transform='s,^qtsvg-everywhere-src,qtsvg,' -f "$(1)" ;; \
*/qttranslations*.*.tar.xz) \
$(TAR) -xJ --transform='s,^qttranslations-everywhere-src,qttranslations,' -f "$(1)" ;; \
*/sqlite*.*.tar.gz) \
$(TAR) -xz --transform='s,^sqlite-autoconf-3270200,sqlite-3.27.2,' -f "$(1)" ;; \
*.tar.gz | *.tgz) \
$(TAR) xzf "$(1)" ;; \
*.tar.bz2 | *.tbz2 | *.tbz) \
$(TAR) xjf "$(1)" ;; \
*.tar.xz ) \
$(TAR) xJf "$(1)" ;; \
*.exe ) \
cp "$(1)" . ;; \
*.zip) \
$(UNZIP) -o "$(1)" ;; \
esac
endef
# Support macro. Strip all exe files below $(1).
define STRIP_macro
if test -z '$(DEBUG)'; then \
(cd $(1); \
for f in `find . -name \*.exe -o -name \*.dll`; do \
echo Calling $(STRIP) "$$$${pkg_version}/$$$${f}"; \
$(STRIP) "$$$${f}"; done); \
fi
endef
define GETDEPS
$(addprefix $(stampdir)/stamp-final-, $(call GETVAR,appimage_pkg_$(1)_deps))
endef
# Template for source packages.
define SPKG_template_
pkg_files += $(call GETVAR,appimage_pkg_$(1))
$(stampdir)/stamp-$(1)-00-unpack: $(stampdir)/stamp-directories $(call GETDEPS,$(1))
(cd $(bdir); \
$(call SETVARS,$(1)); \
$(call DEFLATE_macro,$$$${pkg}))
touch $(stampdir)/stamp-$(1)-00-unpack
$(stampdir)/stamp-$(1)-01-patch: $(stampdir)/stamp-$(1)-00-unpack
(shopt -s nullglob; \
$(call SETVARS,$(1)); \
for pfile in "$$$${pkgpatbdir}"/*.patch "$$$${pkgpatdir}"/*.patch ; do \
(cd "$$$${pkgsdir}"; /bin/sh "$$$${pfile}") \
done)
touch $(stampdir)/stamp-$(1)-01-patch
$(stampdir)/stamp-$(1)-02-configure: $(stampdir)/stamp-$(1)-01-patch
($(call SETVARS,$(1)); \
set -x; \
mkdir -p "$$$${pkglogdir}"; \
mkdir -p "$$$${pkgbdir}"; \
cd "$$$${pkgbdir}"; \
eval "../$$$${pkg_version}/configure" \
--prefix="$$$${pkgidir}" \
$$$${pkgcfg} \
CFLAGS=\"$$$${pkgextracflags}\" | \
tee "$$$${pkglogdir}/configure.log"; \
shopt -s nullglob; \
for pfile in "$$$${pkgpatbdir}"/*.postcfg \
"$$$${pkgpatdir}"/*.postcfg ; do \
(cd "$$$${pkgsdir}"; "$$$${pfile}") \
done; \
for pfile in "$$$${pkgpatbdir}"/*.postcfg-build \
"$$$${pkgpatdir}"/*.postcfg-build ; do \
(cd "$$$${pkgbdir}"; "$$$${pfile}") \
done)
touch $(stampdir)/stamp-$(1)-02-configure
$(stampdir)/stamp-$(1)-03-make: $(stampdir)/stamp-$(1)-02-configure
($(call SETVARS,$(1)); \
cd "$$$${pkgbdir}"; \
test -n "$$$${pkgmkdir}" && cd "$$$${pkgmkdir}"; \
$(MAKE) $(AM_MAKEFLAGS) $(GPG4WIN_PARALLEL) $$$${pkgmkargs})
touch $(stampdir)/stamp-$(1)-03-make
# Note that post_install must come last because it may be empty and
# "; ;" is a syntax error.
$(stampdir)/stamp-$(1)-04-install: $(stampdir)/stamp-$(1)-03-make
($(call SETVARS,$(1)); \
cd "$$$${pkgbdir}"; \
cd "$$$${pkgmkdir_inst}"; \
$(MAKE) $(AM_MAKEFLAGS) $$$${pkgmkargs_inst} install; \
$(call STRIP_macro,"$$$${pkgidir}"); \
rm -f "$$$${pkgidir}/share/info/dir"; \
$(call appimage_pkg_$(call FROB_macro,$(1))_post_install))
touch $(stampdir)/stamp-$(1)-04-install
$(stampdir)/stamp-$(1)-05-rsync: $(stampdir)/stamp-$(1)-04-install
($(call SETVARS,$(1)); \
set -x; \
$(RSYNC) -a --link-dest="$$$${pkgidir}/" "$$$${pkgidir}/" "$(idir)/"; \
for pc in "$(idir)"/lib/pkgconfig/*.pc; do \
sed -i "s;$$$${pkgidir};$(idir);" "$$$${pc}"; \
done )
touch $(stampdir)/stamp-$(1)-05-rsync
$(stampdir)/stamp-$(1)-06-copy-to-appdir: $(stampdir)/stamp-$(1)-05-rsync
($(call SETVARS,$(1)); \
set -x; \
if test -f "$$$${pkgrsyncfilter}"; then \
cp "$$$${pkgrsyncfilter}" "$$$${pkgidir}/.rsync-filter"; \
$(RSYNC) -av -FF --omit-dir-times --link-dest="$$$${pkgidir}/" "$$$${pkgidir}/" "$(appdir)/usr/"; \
fi )
touch $(stampdir)/stamp-$(1)-06-copy-to-appdir
$(stampdir)/stamp-final-$(1): $(stampdir)/stamp-$(1)-06-copy-to-appdir
touch $(stampdir)/stamp-final-$(1)
$(1): $(stampdir)/stamp-final-$(1)
.PHONY : clean-$(1)
clean-$(1):
($(call SETVARS,$(1)); \
(cd $(ipdir) && \
(rm -fR "$$$${pkg_version}")); \
rm -fR "$$$${pkgsdir}" "$$$${pkgbdir}")
rm -f $(stampdir)/stamp-final-$(1) $(stampdir)/stamp-$(1)-*
endef
define SPKG_template
$(if $(filter-out no, $(call GETVAR,appimage_pkg_$(1))),
$(call SPKG_template_,$1))
endef
# Template for binary packages.
define BPKG_template_
pkg_files += $(call GETVAR,appimage_pkg_$(1))
$(stampdir)/stamp-$(1)-00-install: $(stampdir)/stamp-directories $(call GETDEPS,$(1))
($(call SETVARS,$(1)); \
set -x; \
test -d "$$$${pkgidir}" || $(MKDIR) "$$$${pkgidir}";\
cd $$$${pkgidir}; \
$(call DEFLATE_macro,$$$${pkg}); \
$(call appimage_pkg_$(call FROB_macro,$(1))_post_install))
touch $(stampdir)/stamp-$(1)-00-install
$(stampdir)/stamp-$(1)-01-rsync: $(stampdir)/stamp-$(1)-00-install
($(call SETVARS,$(1)); \
set -x; \
$(RSYNC) -a --link-dest="$$$${pkgidir}/" "$$$${pkgidir}/" "$(idir)/" )
touch $(stampdir)/stamp-$(1)-01-rsync
$(stampdir)/stamp-$(1)-02-copy-to-appdir: $(stampdir)/stamp-$(1)-01-rsync
($(call SETVARS,$(1)); \
set -x; \
if test -f "$$$${pkgrsyncfilter}"; then \
cp "$$$${pkgrsyncfilter}" "$$$${pkgidir}/.rsync-filter"; \
$(RSYNC) -av -FF --omit-dir-times --link-dest="$$$${pkgidir}/" "$$$${pkgidir}/" "$(appdir)/usr/"; \
fi )
touch $(stampdir)/stamp-$(1)-02-copy-to-appdir
$(stampdir)/stamp-final-$(1): $(stampdir)/stamp-$(1)-02-copy-to-appdir
touch $(stampdir)/stamp-final-$(1)
$(1): $(stampdir)/stamp-final-$(1)
.PHONY : clean-$(1)
clean-$(1):
($(call SETVARS,$(1)); \
cd $(ipdir) && \
(rm -fR "$$$${pkg_version}"))
rm -f $(stampdir)/stamp-final-$(1) $(stampdir)/stamp-$(1)-*
endef
define BPKG_template
$(if $(filter-out no, $(call GETVAR,appimage_pkg_$(1))),
$(call BPKG_template_,$1))
endef
# Template for KDE packages.
define KDEPKG_template_
pkg_files += $(call GETVAR,appimage_pkg_$(1))
$(stampdir)/stamp-$(1)-00-unpack: $(stampdir)/stamp-directories $(call GETDEPS,$(1))
(cd $(bdir); \
$(call SETVARS,$(1)); \
$(call DEFLATE_macro,$$$${pkg}))
touch $(stampdir)/stamp-$(1)-00-unpack
$(stampdir)/stamp-$(1)-01-patch: $(stampdir)/stamp-$(1)-00-unpack
(set -x; \
shopt -s nullglob; \
$(call SETVARS,$(1)); \
cd "$$$${pkgsdir}"; \
if [ -e "CMakeLists.txt" ]; then \
sed -i 's/set(KF_MIN_VERSION.*)/set(KF_MIN_VERSION "6.20.0")/' CMakeLists.txt; \
sed -i 's/find_package(ECM .* NO_MODULE)/find_package(ECM 6.20.0 NO_MODULE)/' CMakeLists.txt; \
sed -i 's/set(KF_DEP_VERSION.*)/set(KF_DEP_VERSION "6.20.0")/' CMakeLists.txt; \
sed -i 's/set(KMIME_VERSION.*)/set(KMIME_VERSION "6.5.0")/' CMakeLists.txt; \
sed -i 's/set(KPIM_MIME_VERSION.*)/set(KPIM_MIME_VERSION "6.5.0")/' CMakeLists.txt; \
sed -i 's/set(KPIM_MBOX_VERSION.*)/set(KPIM_MBOX_VERSION "6.5.0")/' CMakeLists.txt; \
sed -i 's/set(MIMETREEPARSER_VERSION.*)/set(MIMETREEPARSER_VERSION "6.5.0")/' CMakeLists.txt; \
fi; \
for pfile in "$$$${pkgpatbdir}"/*.patch "$$$${pkgpatdir}"/*.patch ; do \
(cd "$$$${pkgsdir}"; /bin/sh "$$$${pfile}") \
done)
touch $(stampdir)/stamp-$(1)-01-patch
$(stampdir)/stamp-$(1)-02-configure: $(stampdir)/stamp-$(1)-01-patch
(set -x; \
$(call SETVARS,$(1)); \
mkdir -p "$$$${pkglogdir}"; \
mkdir -p "$$$${pkgbdir}"; \
cd "$$$${pkgbdir}"; \
$(CMAKE) \
-DCMAKE_INSTALL_PREFIX="$$$${pkgidir}" \
+ -DCMAKE_INSTALL_LIBDIR=lib \
-DCMAKE_PREFIX_PATH="$(idir)" \
-DKDE_INSTALL_DATADIR="$$$${pkgidir}/share" \
-DBUILD_TESTING=False \
-DBUILD_PYTHON_BINDINGS=OFF \
$$$${pkgcfg} $$$${pkgextracflags} \
"../$$$${pkg_version}$$$${pkg_conf_subdir}" | \
tee "$$$${pkglogdir}/configure.log")
touch $(stampdir)/stamp-$(1)-02-configure
$(stampdir)/stamp-$(1)-03-make: $(stampdir)/stamp-$(1)-02-configure
($(call SETVARS,$(1)); \
cd "$$$${pkgbdir}"; \
test -n "$$$${pkgmkdir}" && cd "$$$${pkgmkdir}"; \
export LD_LIBRARY_PATH=$(idir)/lib; \
$(MAKE) $(AM_MAKEFLAGS) $(GPG4WIN_PARALLEL) $$$${pkgmkargs})
touch $(stampdir)/stamp-$(1)-03-make
# Note that post_install must come last because it may be empty and
# "; ;" is a syntax error.
$(stampdir)/stamp-$(1)-04-install: $(stampdir)/stamp-$(1)-03-make
($(call SETVARS,$(1)); \
cd "$$$${pkgbdir}"; \
cd "$$$${pkgmkdir_inst}"; \
$(MAKE) $(AM_MAKEFLAGS) $$$${pkgmkargs_inst} install; \
$(call STRIP_macro,"$$$${pkgidir}"); \
$(call appimage_pkg_$(call FROB_macro,$(1))_post_install))
touch $(stampdir)/stamp-$(1)-04-install
$(stampdir)/stamp-$(1)-05-rsync: $(stampdir)/stamp-$(1)-04-install
($(call SETVARS,$(1)); \
set -x; \
$(RSYNC) -a --link-dest="$$$${pkgidir}/" "$$$${pkgidir}/" "$(idir)/"; \
for pc in "$(idir)"/lib/pkgconfig/*.pc; do \
sed -i "s;$$$${pkgidir};$(idir);" "$$$${pc}"; \
done )
touch $(stampdir)/stamp-$(1)-05-rsync
$(stampdir)/stamp-$(1)-06-copy-to-appdir: $(stampdir)/stamp-$(1)-05-rsync
($(call SETVARS,$(1)); \
set -x; \
if test -f "$$$${pkgrsyncfilter}"; then \
cp "$$$${pkgrsyncfilter}" "$$$${pkgidir}/.rsync-filter"; \
$(RSYNC) -av -FF --omit-dir-times --link-dest="$$$${pkgidir}/" "$$$${pkgidir}/" "$(appdir)/usr/"; \
fi )
touch $(stampdir)/stamp-$(1)-06-copy-to-appdir
$(stampdir)/stamp-final-$(1): $(stampdir)/stamp-$(1)-06-copy-to-appdir
touch $(stampdir)/stamp-final-$(1)
$(1): $(stampdir)/stamp-final-$(1)
.PHONY : clean-$(1)
clean-$(1):
($(call SETVARS,$(1)); \
(cd $(ipdir) && \
(rm -fR "$$$${pkg_version}")); \
rm -fR "$$$${pkgsdir}" "$$$${pkgbdir}")
rm -f $(stampdir)/stamp-final-$(1) $(stampdir)/stamp-$(1)-*
endef
define KDEPKG_template
$(if $(filter-out no, $(call GETVAR,appimage_pkg_$(1))),
$(call KDEPKG_template_,$1))
endef
# Insert the template for each source package.
$(foreach spkg, $(appimage_spkgs), $(eval $(call SPKG_template,$(spkg))))
# Insert the template for each binary package.
$(foreach bpkg, $(appimage_bpkgs), $(eval $(call BPKG_template,$(bpkg))))
# Insert the template for Qt packages.
$(foreach qtpkg, $(appimage_qtpkgs), $(eval $(call QTPKG_template,$(qtpkg))))
# Insert the template for KDE packages.
$(foreach kdepkg, $(appimage_kdepkgs), $(eval $(call KDEPKG_template,$(kdepkg))))
$(stampdir)/stamp-final: $(stampdir)/stamp-directories
$(stampdir)/stamp-final: $(addprefix $(stampdir)/stamp-final-,$(appimage_build_list))
touch $(stampdir)/stamp-final
$(bdir)/versioninfo.txt: $(stampdir)/stamp-final
touch $(bdir)/versioninfo.txt
all-appimage: $(stampdir)/stamp-final
# Just to check if we catched all stamps.
clean-stamps:
$(RM) -fR $(stampdir)
clean-appimage:
$(RM) -fR $(bdir) $(idir) $(stampdir) $(logdir) $(appdir)
.PHONY : all-appimage clean-stamps clean-appimage
# @emacs_local_vars_begin@
# @emacs_local_vars_read_only@
# @emacs_local_vars_end@
diff --git a/src/appimage/build-appimage.sh b/src/appimage/build-appimage.sh
index 530ae83b..7545bc19 100755
--- a/src/appimage/build-appimage.sh
+++ b/src/appimage/build-appimage.sh
@@ -1,200 +1,200 @@
#!/bin/sh
# Build an AppImage of GnuPG (VS-)Desktop
# Copyright (C) 2021, 2024 g10 Code GmbH
#
# Software engineering by: Ingo Klöcker <dev@ingo-kloecker.de>
# Andre Heinecke <aheinecke@gnupg.org>
# This file is part of GnuPG.
#
# GnuPG is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
#
# GnuPG is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, see <https://www.gnu.org/licenses/>.
#
# SPDX-License-Identifier: GPL-3.0+
set -e
BUILDROOT=/build
SRCDIR=/src
APPDIR=${BUILDROOT}/AppDir
INSTDIR=${BUILDROOT}/install
VSD_DIR=${SRCDIR}/src/gnupg-vsd
# Check for the buildtype and existence of required files
# early
BUILDTYPE=$(cat ${SRCDIR}/packages/BUILDTYPE || echo default)
if [ $BUILDTYPE != default ] && [ ! -f ${VSD_DIR}/custom.mk ]; then
echo "ERROR: Non default build without custom file."
echo "Check that ${VSD_DIR}/custom.mk exists or "
echo "change the BUILDTYPE in ${SRCDIR}/packages/BUILDTYPE"
exit 2
fi
if [ $BUILDTYPE = vsd ] && \
[ ! -f ${VSD_DIR}/Standard/VERSION ]; then
echo "No VERSION file in Standard dir."
exit 2
fi
if [ $BUILDTYPE = gpd ] && \
[ ! -f ${VSD_DIR}/Desktop/VERSION ]; then
echo "No VERSION file in Desktop dir."
exit 2
fi
# The actual build
cd ${BUILDROOT}
source /opt/rh/gcc-toolset-14/enable
${SRCDIR}/configure --enable-appimage --with-playground=${BUILDROOT}
make TOPSRCDIR=${SRCDIR} PLAYGROUND=${BUILDROOT}
echo 'rootdir = $APPDIR/usr' >${APPDIR}/usr/bin/gpgconf.ctl
if [ $BUILDTYPE = vsd ]; then
echo 'sysconfdir = /etc/gnupg-vsd' >>${APPDIR}/usr/bin/gpgconf.ctl
else
echo 'sysconfdir = /etc/gnupg' >>${APPDIR}/usr/bin/gpgconf.ctl
fi
# Copy the start-shell helper for use AppRun
cp ${SRCDIR}/src/appimage/start-shell ${APPDIR}/
chmod +x ${APPDIR}/start-shell
# Copy standard global configuration
if [ $BUILDTYPE = vsd ]; then
mkdir -p ${APPDIR}/usr/share/gnupg/conf/gnupg-vsd
rsync -aLv --delete --omit-dir-times \
${VSD_DIR}/Standard/etc/gnupg/ \
${APPDIR}/usr/share/gnupg/conf/gnupg-vsd/
fi
export PATH=/opt/linuxdeploy/usr/bin:$PATH
-export LD_LIBRARY_PATH=${INSTDIR}/lib:${INSTDIR}/lib64
+export LD_LIBRARY_PATH=${INSTDIR}/lib
# tell the linuxdeploy qt-plugin where to find qmake
export QMAKE=${INSTDIR}/bin/qmake
# create plugin directories expected by linuxdeploy qt-plugin
# workaround for
# [qt/stdout] Deploy[qt/stderr] terminate called after throwing an instance of 'boost::filesystem::filesystem_error'
# [qt/stderr] what(): boost::filesystem::directory_iterator::construct: No such file or directory: "/build/AppDir/usr/plugins/sqldrivers"
# ERROR: Failed to run plugin: qt (exit code: 6)
mkdir -p ${INSTDIR}/plugins/sqldrivers
# copy KDE plugins to ${APPDIR}/usr/lib/plugins/
# copying the plugins to a subfolder of ${APPDIR}/usr/lib (instead of to
# ${APPDIR}/usr/plugins/ as linuxdeploy does for the Qt plugins) ensures that
# linuxdeploy copies the dependencies of the plugins to APPDIR so that
# we don't have to take care of this ourselves
mkdir -p ${APPDIR}/usr/lib/plugins
for d in kf6 kiconthemes6 styles; do
- rsync -av --delete --omit-dir-times ${INSTDIR}/lib64/plugins/${d}/ ${APPDIR}/usr/lib/plugins/${d}/
+ rsync -av --delete --omit-dir-times ${INSTDIR}/lib/plugins/${d}/ ${APPDIR}/usr/lib/plugins/${d}/
done
-rsync -av --delete --omit-dir-times ${INSTDIR}/lib64/plugins/okular_generators/okularGenerator_poppler.so ${APPDIR}/usr/lib/plugins/okular_generators/
+rsync -av --delete --omit-dir-times ${INSTDIR}/lib/plugins/okular_generators/okularGenerator_poppler.so ${APPDIR}/usr/lib/plugins/okular_generators/
cd /build
# Remove existing AppRun and wrapped AppRun, that may be left over
# from a previous run of linuxdeploy, to ensure that our custom AppRun
# is deployed
rm -f ${APPDIR}/AppRun ${APPDIR}/AppRun.wrapped 2>/dev/null
# Remove existing translations that may be left over from a previous
# run of linuxdeploy
rm -rf ${APPDIR}/usr/translations
# Remove the version files to make sure that only one will be created.
rm -f ${APPDIR}/GnuPG-VS-Desktop-VERSION 2>/dev/null
rm -f ${APPDIR}/GnuPG-Desktop-VERSION 2>/dev/null
rm -f ${APPDIR}/Gpg4win-VERSION 2>/dev/null
myversion=$(grep PACKAGE_VERSION ${BUILDROOT}/config.h|sed -n 's/.*"\(.*\)"$/\1/p')
if [ $BUILDTYPE = vsd ]; then
OUTPUT=gnupg-vs-desktop-${myversion}-x86_64.AppImage
echo "Packaging GnuPG VS-Desktop Appimage: $myversion"
echo $myversion >${APPDIR}/GnuPG-VS-Desktop-VERSION
cp ${VSD_DIR}/Standard/VERSION* ${APPDIR}/usr/
echo "Packaging help files"
mkdir -p ${APPDIR}/usr/share/doc/gnupg-vsd
cp ${VSD_DIR}/help/*.pdf ${APPDIR}/usr/share/doc/gnupg-vsd
if [ -f ${VSD_DIR}/Standard/kleopatrarc ]; then
echo "Packaging kleopatrarc"
mkdir -p ${APPDIR}/usr/etc/xdg
cp ${VSD_DIR}/Standard/kleopatrarc ${APPDIR}/usr/etc/xdg
fi
kleopatra_icon=${SRCDIR}/src/icons/kleopatra-vsd.svg
elif [ $BUILDTYPE = gpd ]; then
OUTPUT=gnupg-desktop-${myversion}-x86_64.AppImage
echo "Packaging GnuPG Desktop Appimage: $myversion"
echo $myversion >${APPDIR}/GnuPG-Desktop-VERSION
cp ${VSD_DIR}/Desktop/VERSION* ${APPDIR}/usr/
echo "Packaging help files"
mkdir -p ${APPDIR}/usr/share/doc/gnupg-vsd
cp ${VSD_DIR}/help/*.pdf ${APPDIR}/usr/share/doc/gnupg-vsd
if [ -f ${VSD_DIR}/Desktop/kleopatrarc ]; then
echo "Packaging kleopatrarc"
mkdir -p ${APPDIR}/usr/etc/xdg
cp ${VSD_DIR}/Desktop/kleopatrarc ${APPDIR}/usr/etc/xdg
fi
kleopatra_icon=${SRCDIR}/src/icons/gpd/sc-apps-kleopatra.svg
else
OUTPUT=gpg4win-${myversion}-x86_64.AppImage
echo "Packaging Gpg4win Appimage: $myversion"
echo $myversion >${APPDIR}/Gpg4win-VERSION
fi
export OUTPUT
if [ -n "${kleopatra_icon}" ]; then
# Replace Breeze icons for kleopatra with our icon
find ${APPDIR}/usr/share/icons/breeze -name 'kleopatra*.svg' -delete
find ${APPDIR}/usr/share/icons/breeze-dark -name 'kleopatra*.svg' -delete
cp -av ${kleopatra_icon} ${APPDIR}/usr/share/icons/breeze/apps/22/kleopatra-symbolic.svg
cp -av ${kleopatra_icon} ${APPDIR}/usr/share/icons/breeze/apps/48/kleopatra.svg
cp -av ${kleopatra_icon} ${APPDIR}/usr/share/icons/breeze-dark/apps/22/kleopatra-symbolic.svg
cp -av ${kleopatra_icon} ${APPDIR}/usr/share/icons/breeze-dark/apps/48/kleopatra.svg
else
# Restore the Breeze icons that may have been replaced in a previous build
for f in breeze/apps/22/kleopatra-symbolic.svg breeze/apps/48/kleopatra.svg \
breeze-dark/apps/22/kleopatra-symbolic.svg breeze-dark/apps/48/kleopatra.svg; do
# copy files only if they are not hard-linked; otherwise, cp complains that the files are the same file
test ${INSTDIR}/share/icons/$f -ef ${APPDIR}/usr/share/icons/$f \
|| cp -av ${INSTDIR}/share/icons/$f ${APPDIR}/usr/share/icons/$f
done
fi
# Hack around that linuxdeploy does not know libexec
for f in dirmngr_ldap gpg-check-pattern \
gpg-preset-passphrase gpg-protect-tool \
gpg-wks-client scdaemon \
keyboxd gpg-pair-tool; do
# Ignore errors because some files might not exist depending
# on GnuPG Version
/opt/linuxdeploy/usr/bin/patchelf --debug \
--set-rpath '$ORIGIN/../lib' ${APPDIR}/usr/libexec/$f || true
done
# linuxdeploy also doesn't know about non-Qt plugins
for f in $(find ${APPDIR}/usr/lib/plugins/ -mindepth 2 -maxdepth 2 -type f); do
/opt/linuxdeploy/usr/bin/patchelf --debug --set-rpath '$ORIGIN/../..' $f
done
for f in $(find ${APPDIR}/usr/lib/plugins/ -mindepth 3 -maxdepth 3 -type f); do
/opt/linuxdeploy/usr/bin/patchelf --debug --set-rpath '$ORIGIN/../../..' $f
done
for f in $(find ${APPDIR}/usr/lib/plugins/ -mindepth 4 -maxdepth 4 -type f); do
/opt/linuxdeploy/usr/bin/patchelf --debug --set-rpath '$ORIGIN/../../../..' $f
done
# Fix up everything and build the file system
linuxdeploy --appdir ${APPDIR} \
--desktop-file ${APPDIR}/usr/share/applications/org.kde.kleopatra.desktop \
--icon-file ${APPDIR}/usr/share/icons/hicolor/256x256/apps/kleopatra.png \
--custom-apprun ${SRCDIR}/src/appimage/AppRun \
--plugin qt \
--output appimage \
2>&1 | tee /build/logs/linuxdeploy-gnupg-desktop.log
echo ready
exit 0

File Metadata

Mime Type
text/x-diff
Expires
Thu, Feb 5, 9:49 PM (6 m, 38 s)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
a3/d5/4f5e6437792f1208c4b0c304a94e

Event Timeline