From 79eac0f28f46758a5ee53c6d43fe8bff1443c50d Mon Sep 17 00:00:00 2001 From: ArTourter Date: Fri, 17 Jun 2022 11:25:52 +0100 Subject: gis/proj: Updated for version 9.0.1. - remove mandir patch since it was merged upstream - add TESTBUILD option to build and run tests (off by default) - fix /usr/share/doc path in package (bug in CMake definitions) Signed-off-by: ArTourter Signed-off-by: Andrew Clemons Signed-off-by: Willy Sudiarto Raharjo --- gis/proj/proj.SlackBuild | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) (limited to 'gis/proj/proj.SlackBuild') diff --git a/gis/proj/proj.SlackBuild b/gis/proj/proj.SlackBuild index 6b556bbfc7..b11d2ce96d 100644 --- a/gis/proj/proj.SlackBuild +++ b/gis/proj/proj.SlackBuild @@ -25,7 +25,7 @@ cd $(dirname $0) ; CWD=$(pwd) PRGNAM=proj -VERSION=${VERSION:-9.0.0} +VERSION=${VERSION:-9.0.1} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} PKGTYPE=${PKGTYPE:-tgz} @@ -66,6 +66,10 @@ fi set -e +if [[ ${TESTBUILD:='NO'} == 'NO' ]]; then + TESTBUILDFLAGS='-DBUILD_TESTING=OFF' +fi + rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT cd $TMP @@ -79,8 +83,6 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; -patch -p1 < $CWD/fix_mandir.patch - mkdir -p build ( cd build cmake \ @@ -88,22 +90,24 @@ mkdir -p build -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \ -DCMAKE_INSTALL_PREFIX=/usr \ -DCMAKE_INSTALL_LIBDIR=lib${LIBDIRSUFFIX} \ - -DCMAKE_INSTALL_MANDIR=/usr/man \ + -DCMAKE_INSTALL_MANDIR=man \ + -DCMAKE_INSTALL_DOCDIR=doc/$PRGNAM-$VERSION \ -DCMAKE_BUILD_TYPE=Release \ - -DBUILD_TESTING=off \ + $TESTBUILDFLAGS \ .. make + [[ $TESTBUILD == "YES" ]] && make test make install/strip DESTDIR=$PKG ) -rm -rf $PKG/usr/lib${LIBDIRSUFFIX}/*.la - find $PKG/usr/man -type f -exec gzip -9 {} \; for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done -mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION +mkdir $PKG/usr/doc +mv $PKG/usr/share/doc/proj $PKG/usr/doc/$PRGNAM-$VERSION +rm -rf $PKG/usr/share/doc cp -a \ - AUTHORS CITATION COPYING ChangeLog INSTALL NEWS README README.md\ + AUTHORS CITATION COPYING ChangeLog NEWS README README.md\ $PKG/usr/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild -- cgit v1.2.3