build-system: remove Grantlee references from legacy scripts

I debated about this commit... we don't use these scripts any more, but it
seems like it would be worse to leave the Grantlee references in them. Yet of
course this is all no longer tested. Maybe it is time to delete the scripts
from the tree.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2020-10-07 12:46:06 -07:00
parent ec7422feb5
commit b40c8de35b
6 changed files with 6 additions and 38 deletions

View file

@ -22,9 +22,8 @@ export QT_DEBUG_PLUGINS=1
# set up the appdir # set up the appdir
mkdir -p appdir/usr/plugins/ mkdir -p appdir/usr/plugins/
# mv googlemaps and Grantlee plugins into place # mv googlemaps plugins into place
mv appdir/usr/usr/local/Qt/5.12.4/gcc_64/plugins/* appdir/usr/plugins # the usr/usr is not a typo, that's where it ends up mv appdir/usr/usr/local/Qt/5.12.4/gcc_64/plugins/* appdir/usr/plugins # the usr/usr is not a typo, that's where it ends up
mv appdir/usr/lib/grantlee/ appdir/usr/plugins/
rm -rf appdir/usr/home/ appdir/usr/include/ appdir/usr/share/man/ # No need to ship developer and man files as part of the AppImage rm -rf appdir/usr/home/ appdir/usr/include/ appdir/usr/share/man/ # No need to ship developer and man files as part of the AppImage
rm -rf appdir/usr/usr appdir/usr/lib/cmake appdir/usr/lib/pkgconfig rm -rf appdir/usr/usr appdir/usr/lib/cmake appdir/usr/lib/pkgconfig
cp /ssllibs/libssl.so appdir/usr/lib/libssl.so.1.1 cp /ssllibs/libssl.so appdir/usr/lib/libssl.so.1.1

View file

@ -33,9 +33,8 @@ grep -A1 RESULT\ :\ TestParsePerformance subsurface/build/tests/Testing/Temporar
# set up the appdir # set up the appdir
mkdir -p appdir/usr/plugins/ mkdir -p appdir/usr/plugins/
# mv googlemaps and Grantlee plugins into place # mv googlemaps plugins into place
mv appdir/usr/usr/local/Qt*/plugins/* appdir/usr/plugins # the usr/usr is not a typo - that's where it ends up mv appdir/usr/usr/local/Qt*/plugins/* appdir/usr/plugins # the usr/usr is not a typo - that's where it ends up
mv appdir/usr/lib/grantlee/ appdir/usr/plugins/
rm -rf appdir/usr/home/ appdir/usr/include/ appdir/usr/share/man/ # No need to ship developer and man files as part of the AppImage rm -rf appdir/usr/home/ appdir/usr/include/ appdir/usr/share/man/ # No need to ship developer and man files as part of the AppImage
rm -rf appdir/usr/usr appdir/usr/lib/cmake appdir/usr/lib/pkgconfig rm -rf appdir/usr/usr appdir/usr/lib/cmake appdir/usr/lib/pkgconfig
@ -65,8 +64,6 @@ cp -f subsurface/smtk-import/smtk2ssrf.desktop smtk2ssrf_appdir/
cp -f install-root/bin/smtk2ssrf smtk2ssrf_appdir/usr/bin/ cp -f install-root/bin/smtk2ssrf smtk2ssrf_appdir/usr/bin/
cp -f install-root/lib/libdivecomputer.so.0 smtk2ssrf_appdir/usr/lib/ cp -f install-root/lib/libdivecomputer.so.0 smtk2ssrf_appdir/usr/lib/
cp -f install-root/lib/libgit2* smtk2ssrf_appdir/usr/lib/ cp -f install-root/lib/libgit2* smtk2ssrf_appdir/usr/lib/
# Why is Grantlee needed? We have built subsurface without printing support!!!
cp -f install-root/lib/libGrantlee* smtk2ssrf_appdir/usr/lib/
cp -rf appdir/usr/plugins/{bearer,iconengines,imageformats,platforms,xcbglintegrations} smtk2ssrf_appdir/usr/plugins cp -rf appdir/usr/plugins/{bearer,iconengines,imageformats,platforms,xcbglintegrations} smtk2ssrf_appdir/usr/plugins
./linuxdeployqt*.AppImage ./smtk2ssrf_appdir/smtk2ssrf.desktop -bundle-non-qt-libs -verbose=2 ./linuxdeployqt*.AppImage ./smtk2ssrf_appdir/smtk2ssrf.desktop -bundle-non-qt-libs -verbose=2

View file

@ -30,8 +30,10 @@ make export-html
LIBRARY_PATH=${DIR}/install-root/lib make -j2 install LIBRARY_PATH=${DIR}/install-root/lib make -j2 install
# now adjust a few references that macdeployqt appears to miss # now adjust a few references that macdeployqt appears to miss
# there used to be more - having the for-loop for just one seems overkill, but I
# wouldn't be surprised if there will be more again in the future, so leave it for now
EXECUTABLE=Subsurface.app/Contents/MacOS/Subsurface EXECUTABLE=Subsurface.app/Contents/MacOS/Subsurface
for i in libgit2 libGrantlee_TextDocument.dylib libGrantlee_Templates.dylib; do for i in libgit2 ; do
OLD=$(otool -L ${EXECUTABLE} | grep $i | cut -d\ -f1 | tr -d "\t") OLD=$(otool -L ${EXECUTABLE} | grep $i | cut -d\ -f1 | tr -d "\t")
if [[ ! -z ${OLD} && ! -f Subsurface.app/Contents/Frameworks/$(basename ${OLD}) ]] ; then if [[ ! -z ${OLD} && ! -f Subsurface.app/Contents/Frameworks/$(basename ${OLD}) ]] ; then
# copy the library into the bundle and make sure its id and the reference to it are correct # copy the library into the bundle and make sure its id and the reference to it are correct
@ -48,22 +50,3 @@ for i in ${RPATH}; do
install_name_tool -change @rpath/$i @executable_path/../Frameworks/$i ${EXECUTABLE} install_name_tool -change @rpath/$i @executable_path/../Frameworks/$i ${EXECUTABLE}
done done
# next deal with libGrantlee
LIBG=$(ls Subsurface.app/Contents/Frameworks/libGrantlee_Templates*dylib)
for i in QtScript.framework/Versions/5/QtScript QtCore.framework/Versions/5/QtCore ; do
install_name_tool -change @rpath/$i @executable_path/../Frameworks/$i ${LIBG}
done
# clean up shared library dependency in the Grantlee plugins
for i in Subsurface.app/Contents/PlugIns/grantlee/5.0/*.so; do
OLD=$(otool -L $i | grep libGrantlee_Templates | cut -d\ -f1 | tr -d "\t")
SONAME=$(basename $OLD )
install_name_tool -change ${OLD} @executable_path/../Frameworks/${SONAME} $i;
OLD=$(otool -L $i | grep QtCore | cut -d\ -f1 | tr -d "\t")
install_name_tool -change ${OLD} @executable_path/../Frameworks/QtCore.framework/QtCore $i;
mv $i Subsurface.app/Contents/PlugIns/grantlee
done
rmdir Subsurface.app/Contents/PlugIns/grantlee/5.0
pushd Subsurface.app/Contents/PlugIns/grantlee
ln -s . 5.0
popd

View file

@ -23,7 +23,6 @@ autoreconf --install
# the intended layout as seen inside the container is # the intended layout as seen inside the container is
# /win/subsurface # sources that we are testing # /win/subsurface # sources that we are testing
# /win32 # binaries that are build # /win32 # binaries that are build
# /grantlee
# /libzip # /libzip
# /hidapi # /hidapi
# /googlemaps # /googlemaps
@ -46,7 +45,6 @@ docker exec -t builder apt-get install -y ca-certificates libtool
docker exec -t builder bash subsurface/scripts/get-dep-lib.sh single . libzip docker exec -t builder bash subsurface/scripts/get-dep-lib.sh single . libzip
docker exec -t builder bash subsurface/scripts/get-dep-lib.sh single . hidapi docker exec -t builder bash subsurface/scripts/get-dep-lib.sh single . hidapi
docker exec -t builder bash subsurface/scripts/get-dep-lib.sh single . googlemaps docker exec -t builder bash subsurface/scripts/get-dep-lib.sh single . googlemaps
docker exec -t builder bash subsurface/scripts/get-dep-lib.sh single . grantlee
# smtk2ssrf build # smtk2ssrf build
docker exec -t builder bash subsurface/scripts/get-dep-lib.sh single . mdbtools docker exec -t builder bash subsurface/scripts/get-dep-lib.sh single . mdbtools

View file

@ -3,7 +3,7 @@
# installer on Travis # installer on Travis
# #
# working directory is assumed to be the directory including all the # working directory is assumed to be the directory including all the
# source directories (subsurface, googlemaps, grantlee, etc) # source directories (subsurface, googlemaps, etc)
# in order to be compatible with the assumed layout in the MXE script, we # in order to be compatible with the assumed layout in the MXE script, we
# need to create the secondary build directory # need to create the secondary build directory

View file

@ -59,15 +59,6 @@ echo "Get googlemaps"
cd ${TRAVIS_BUILD_DIR}/.. cd ${TRAVIS_BUILD_DIR}/..
git clone https://github.com/Subsurface/googlemaps.git git clone https://github.com/Subsurface/googlemaps.git
echo "Get Grantlee"
cd ${TRAVIS_BUILD_DIR}/..
git clone https://github.com/steveire/grantlee.git
cd grantlee
if ! git checkout v5.0.0 ; then
echo "can't check out v5.0.0 of grantlee -- giving up"
exit 1
fi
echo "Get mdbtools" echo "Get mdbtools"
cd ${TRAVIS_BUILD_DIR}/.. cd ${TRAVIS_BUILD_DIR}/..
git clone https://github.com/brianb/mdbtools.git git clone https://github.com/brianb/mdbtools.git