summaryrefslogtreecommitdiffstats
path: root/academic/ds9/ds9.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'academic/ds9/ds9.SlackBuild')
-rw-r--r--academic/ds9/ds9.SlackBuild33
1 files changed, 23 insertions, 10 deletions
diff --git a/academic/ds9/ds9.SlackBuild b/academic/ds9/ds9.SlackBuild
index a757a1bed5..096402f85e 100644
--- a/academic/ds9/ds9.SlackBuild
+++ b/academic/ds9/ds9.SlackBuild
@@ -1,8 +1,8 @@
-#!/bin/sh
+#!/bin/bash
-# Slackware build script for SAOImage DS9
+# Slackware build script for ds9 (SAOImageDS9)
-# Copyright 2017 Nitish Ragoomundun, Mauritius
+# Copyright 2022 Nitish Ragoomundun, Mauritius
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -22,10 +22,13 @@
# 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=ds9
-VERSION=${VERSION:-7.6}
+VERSION=${VERSION:-8.4.1}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
@@ -35,7 +38,14 @@ if [ -z "$ARCH" ]; then
esac
fi
-CWD=$(pwd)
+# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
+# the name of the created package would be, and then exit. This information
+# could be useful to other scripts.
+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}
@@ -72,15 +82,18 @@ find -L . \
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
-./unix/configure \
+unix/configure \
--prefix=/usr \
--bindir=/usr/bin \
--sysconfdir=/etc \
--localstatedir=/var \
--docdir=/usr/doc/$PRGNAM-$VERSION \
- --with-arch=${ARCH}-slackware-linux
+ --x-includes=/usr/include \
+ --x-libraries=/usr/lib$LIBDIRSUFFIX \
+ --with-x \
+ --with-arch=$ARCH-slackware-linux
-make -j1
+make
# Install the ds9 executable
mkdir -p $PKG/usr/{bin,doc/$PRGNAM-$VERSION}
@@ -89,8 +102,8 @@ install -D -m755 bin/ds9 $PKG/usr/bin/
# Install icon
mkdir -p $PKG/usr/share/applications
mkdir -p $PKG/usr/share/pixmaps
+install -m 644 ds9/doc/sun.png $PKG/usr/share/pixmaps/ds9-icon.png
install -m 644 $CWD/ds9.desktop $PKG/usr/share/applications
-install -m 644 $CWD/ds9-icon.png $PKG/usr/share/pixmaps
# Copy documentation
cp -a BUILD.txt LICENSE README.md ds9/doc/* $PKG/usr/doc/$PRGNAM-$VERSION
@@ -102,4 +115,4 @@ cat $CWD/slack-desc > $PKG/install/slack-desc
cat $CWD/doinst.sh > $PKG/install/doinst.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