diff options
author | Fellype do Nascimento <fellype (at) gmail (dot) com> | 2022-06-17 12:19:45 +0100 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2022-06-18 09:09:57 +0700 |
commit | 4dc1627a83ca8c34af3806c189eb124bc22988a9 (patch) | |
tree | aad9d9c5fe8a70be0f8385a639c410c470f75787 /academic/scidavis/scidavis.SlackBuild | |
parent | 8916f9fc1af38da67bf8df7587a32bc290ffd012 (diff) |
academic/scidavis: Updated for version 2.9.0.
Signed-off-by: Dave Woodfall <dave@slackbuilds.org>
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'academic/scidavis/scidavis.SlackBuild')
-rw-r--r-- | academic/scidavis/scidavis.SlackBuild | 36 |
1 files changed, 27 insertions, 9 deletions
diff --git a/academic/scidavis/scidavis.SlackBuild b/academic/scidavis/scidavis.SlackBuild index 62e21593e3a4..b82649a8e7c8 100644 --- a/academic/scidavis/scidavis.SlackBuild +++ b/academic/scidavis/scidavis.SlackBuild @@ -26,7 +26,7 @@ cd $(dirname $0) ; CWD=$(pwd) PRGNAM=scidavis -VERSION=${VERSION:-2.4.0} +VERSION=${VERSION:-2.9.0} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} PKGTYPE=${PKGTYPE:-tgz} @@ -53,13 +53,16 @@ OUTPUT=${OUTPUT:-/tmp} if [ "$ARCH" = "i586" ]; then SLKCFLAGS="-O2 -march=i586 -mtune=i686" - SPEC="" + LIBDIRSUFFIX="" elif [ "$ARCH" = "i686" ]; then SLKCFLAGS="-O2 -march=i686 -mtune=i686" - SPEC="" + LIBDIRSUFFIX="" elif [ "$ARCH" = "x86_64" ]; then SLKCFLAGS="-O2 -fPIC" - SPEC="-spec linux-g++-64" + LIBDIRSUFFIX="64" +else + SLKCFLAGS="-O2" + LIBDIRSUFFIX="" fi rm -rf $PKG @@ -68,6 +71,18 @@ cd $TMP rm -rf $PRGNAM-$VERSION tar xvf $CWD/$PRGNAM-$VERSION.tar.gz cd $PRGNAM-$VERSION + +rmdir 3rdparty/qwt5-qt5/ +rmdir 3rdparty/qwtplot3d/ +rmdir 3rdparty/liborigin/ + +tar xvf $CWD/qwt5-qt5-f7519200f102676fb04fb7bd0be555e0a419d378.tar.gz -C 3rdparty/ +mv 3rdparty/qwt5-qt5-f7519200f102676fb04fb7bd0be555e0a419d378 3rdparty/qwt5-qt5 +tar xvf $CWD/qwtplot3d-b2655743d30ed3185f3c0e2626b33a1d29655216.tar.gz -C 3rdparty/ +mv 3rdparty/qwtplot3d-b2655743d30ed3185f3c0e2626b33a1d29655216 3rdparty/qwtplot3d +tar xvf $CWD/liborigin-a92f26f28e531f64684b66a2731dd617bea3cb45.tar.gz -C 3rdparty/ +mv 3rdparty/liborigin-a92f26f28e531f64684b66a2731dd617bea3cb45 3rdparty/liborigin + chown -R root:root . find -L . \ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ @@ -75,6 +90,14 @@ 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 {} \; +# Set the correct python paths - code based on scidavis.spec for Fedora by Alexander Ploumistos +sed -i "s:set(PYTHON_SCRIPTDIR etc:set(PYTHON_SCRIPTDIR lib$LIBDIRSUFFIX/python3.9/site-packages/scidavis:" scidavis/CMakeLists.txt +sed -i "s:FILES scidavisrc.py \${CMAKE_CURRENT_BINARY_DIR}/\$<CONFIG>/scidavisrc.pyc DESTINATION:FILES scidavisrc.py DESTINATION:" scidavis/CMakeLists.txt +sed -i "s:FILES scidavisrc.py \${CMAKE_CURRENT_BINARY_DIR}/scidavisrc.pyc DESTINATION:FILES scidavisrc.py DESTINATION:" scidavis/CMakeLists.txt +sed -i "s:FILES scidavisUtil.py DESTINATION share/scidavis:FILES scidavisUtil.py DESTINATION \${PYTHON_SCRIPTDIR}:" scidavis/CMakeLists.txt +sed -i "s:PYTHON_CONFIG_PATH=\"\${CMAKE_INSTALL_PREFIX}/etc\":PYTHON_CONFIG_PATH=\"/usr/lib$LIBDIRSUFFIX/python3.9/site-packages/scidavis\":" libscidavis/CMakeLists.txt +sed -i "s:PYTHON_UTIL_PATH=\"\${CMAKE_INSTALL_PREFIX}/share/scidavis\":PYTHON_UTIL_PATH=\"/usr/lib$LIBDIRSUFFIX/python3.9/site-packages/scidavis\":" libscidavis/CMakeLists.txt + export PYTHON=python3 mkdir build && cd build @@ -91,10 +114,6 @@ make install DESTDIR=$PKG find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true -## Sometimes 'make install' fails to install the translation files -mkdir -p $PKG/usr/share/scidavis/translations -install -m 0644 scidavis/translations/*.qm $PKG/usr/share/scidavis/translations - # Move manpage to a more appropriated dir mkdir -p $PKG/usr/man/man1/ mv $PKG/usr/share/man/man1/scidavis.1 $PKG/usr/man/man1/scidavis.1 @@ -104,7 +123,6 @@ 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 -cp -a README.md LICENSE $PKG/usr/doc/$PRGNAM-$VERSION cp -a $PKG/usr/share/doc/scidavis/*.* $PKG/usr/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild rm -rf $PKG/usr/share/doc |