summaryrefslogtreecommitdiffstats
path: root/academic/ViennaRNA/ViennaRNA.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'academic/ViennaRNA/ViennaRNA.SlackBuild')
-rw-r--r--academic/ViennaRNA/ViennaRNA.SlackBuild85
1 files changed, 53 insertions, 32 deletions
diff --git a/academic/ViennaRNA/ViennaRNA.SlackBuild b/academic/ViennaRNA/ViennaRNA.SlackBuild
index 8bc20e2a45..42ae76bbd7 100644
--- a/academic/ViennaRNA/ViennaRNA.SlackBuild
+++ b/academic/ViennaRNA/ViennaRNA.SlackBuild
@@ -1,8 +1,8 @@
-#!/bin/sh
+#!/bin/bash
# Slackware build script for ViennaRNA
-# Copyright 2018 Rob van Nues
+# Copyright 2018-2023 Rob van Nues
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -22,10 +22,19 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+cd $(dirname $0) ; CWD=$(pwd)
+
PRGNAM=ViennaRNA
-VERSION=${VERSION:-2.4.17}
+VERSION=${VERSION:-2.6.4}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
+
+# RNAxplorer requires lapacke (which requires lapack that requires blas)
+# but cannot see what blas is used for compiling lapack
+# please adjust $BLAS to the blas installed on your system
+BLAS=${BLAS:-openblas}
+
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
@@ -35,7 +44,11 @@ if [ -z "$ARCH" ]; then
esac
fi
-CWD=$(pwd)
+if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
+ echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
+ exit 0
+fi
+
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
@@ -82,8 +95,7 @@ find -L . \
# - RNAlocmin
# - Swig (all scripting interfaces)
# - Perl interface
-# - Python interface
-# - Python 3 interface
+# - Python 3 interface (= Python interface)
# - Streaming SIMD Extension support
# in the case of run time/ make/ or configure problems try turning off:
# - Link Time Optimization (LTO)
@@ -94,25 +106,24 @@ find -L . \
# for Z-score filtering via statically linked libsvm:
# - SVM Z-score filter in RNALfold
# - GNU Scientific Library for RNApvmin
-
-cluster="" ; [ "${CLUSTER:-yes}" != "no" ] && cluster="--with-cluster"
-kinwalker="" ; [ "${KINWALKER:-yes}" != "no" ] && kinwalker="--with-kinwalker"
+# everything is enabled here
+cluster="" ; [ "${CLUSTER:-yes}" != "no" ] && cluster="--with-cluster"
+kinwalker="" ; [ "${KINWALKER:-yes}" != "no" ] && kinwalker="--with-kinwalker"
# Default enabled features:
-forester="" ; [ "${FORESTER:-yes}" != "yes" ] && forester="--without-forester"
-kinfold="" ; [ "${KINFOLD:-yes}" != "yes" ] && kinwalk="--without-kinfold"
-rnalocmin="" ; [ "${RNALOCMIN:-yes}" != "yes" ] && rnalocmin="--without-rnalocmin"
-perl="" ; [ "${PERL:-yes}" != "yes" ] && perl="--without-perl"
-
-python3="" ; [ "${PYTHON3:-yes}" != "yes" ] && python3="--without-python3"
-swig="" ; [ "${SWIG:-yes}" != "yes" ] && swig="--without-swig"
-simd="" ; [ "${SIMD:-yes}" != "yes" ] && simd="--disable-simd"
-lto="" ; [ "${LTO:-yes}" != "yes" ] && lto="--disable-lto"
-openmp="" ; [ "${OPENMP:-yes}" != "yes" ] && openmp="--disable-openmp"
-pthreads="" ; [ "${PTHREADS:-yes}" != "yes" ] && pthreads="--disable-pthreads"
-svm="" ; [ "${SVM:-yes}" != "yes" ] && svm="--without-svm"
-gsl="" ; [ "${GSL:-yes}" != "yes" ] && gsl="--without-gsl"
-# Default to python3 (above) only;
-python="" ; [ "${PYTHON:-no}" != "yes" ] && python="--without-python"
+forester="" ; [ "${FORESTER:-yes}" != "no" ] && forester="--with-forester"
+kinfold="" ; [ "${KINFOLD:-yes}" != "no" ] && kinfold="--with-kinfold"
+rnalocmin="" ; [ "${RNALOCMIN:-yes}" != "no" ] && rnalocmin="--with-rnalocmin"
+perl="" ; [ "${PERL:-yes}" != "no" ] && perl="--with-perl"
+# python = python3
+python="" ; [ "${PYTHON:-yes}" != "no" ] && python="--with-python"
+swig="" ; [ "${SWIG:-yes}" != "no" ] && swig="--with-swig"
+simd="" ; [ "${SIMD:-yes}" != "no" ] && simd="--enable-simd"
+lto="" ; [ "${LTO:-yes}" != "no" ] && lto="--enable-lto"
+openmp="" ; [ "${OPENMP:-yes}" != "no" ] && openmp="--enable-openmp"
+pthreads="" ; [ "${PTHREADS:-yes}" != "no" ] && pthreads="--enable-pthreads"
+svm="" ; [ "${SVM:-yes}" != "no" ] && svm="--with-svm"
+gsl="" ; [ "${GSL:-yes}" != "no" ] && gsl="--with-gsl"
+json="" ; [ "${JSON:-yes}" != "no" ] && json="--with-json"
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
@@ -122,6 +133,9 @@ CXXFLAGS="$SLKCFLAGS" \
--mandir=/usr/man \
--docdir=/usr/doc/$PRGNAM-$VERSION \
--build=$ARCH-slackware-linux \
+ --with-blas=$BLAS \
+ --with-python2=no \
+ --with-doc=no \
$cluster \
$kinwalker \
$forester \
@@ -129,14 +143,15 @@ CXXFLAGS="$SLKCFLAGS" \
$rnalocmin \
$perl \
$python \
- $python3 \
$swig \
$simd \
$lto \
$openmp \
$pthreads \
$svm \
- $gsl || exit 1
+ $gsl \
+ $json \
+ || exit 1
make
make install DESTDIR=$PKG
@@ -155,11 +170,13 @@ for perlscript in $PKG/usr/share/ViennaRNA/bin/*.pl ; do
done
rm -r $PKG/usr/share/ViennaRNA/bin
-# no need for that file it is outdated anyway
+# re-organise info files the Slackware/SBo way
+mkdir $PKG/usr/info/
rm $PKG/usr/share/info/dir
-
-#gzip info file
-gzip -9 $PKG/usr/share/info/*.info
+#gzip and move info file
+gzip -9 $PKG/usr/share/info/*.info*
+mv $PKG/usr/share/info/*.info* $PKG/usr/info/
+rmdir $PKG/usr/share/info
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
@@ -181,12 +198,16 @@ if [[ -e $PKG/usr/doc/$PRGNAM-$VERSION/RNAlib-$VERSION.pdf ]]; then
fi
cp -a \
- NEWS README.md AUTHORS COPYING THANKS INSTALL CHANGELOG.md license.txt \
+ NEWS README.md AUTHORS COPYING THANKS CHANGELOG.md license.txt \
$PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+rm -f $PKG/usr/lib*/*.la
+
mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
+cat $CWD/doinst.sh > $PKG/install/doinst.sh
+cat $CWD/douninst.sh > $PKG/install/douninst.sh
cd $PKG
-/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE