aboutsummaryrefslogtreecommitdiff
path: root/libraries/pgplot/pgplot.SlackBuild
diff options
context:
space:
mode:
authorNitish Ragoomundun <lrugratz@gmail.com>2018-08-03 06:03:36 +0700
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2018-08-04 08:17:11 +0700
commitd6a3de9726e70631fc392cfc2c4d95d964c2694d (patch)
treeb478d5255213492fa27db46560b8fecac4e40416 /libraries/pgplot/pgplot.SlackBuild
parent89c18e54780b3704ec757028fa33c72ebdf1f841 (diff)
libraries/pgplot: Updated script.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'libraries/pgplot/pgplot.SlackBuild')
-rw-r--r--libraries/pgplot/pgplot.SlackBuild31
1 files changed, 26 insertions, 5 deletions
diff --git a/libraries/pgplot/pgplot.SlackBuild b/libraries/pgplot/pgplot.SlackBuild
index 2fa320790666..75d8f6b23092 100644
--- a/libraries/pgplot/pgplot.SlackBuild
+++ b/libraries/pgplot/pgplot.SlackBuild
@@ -2,7 +2,7 @@
# Slackware build script for PGPLOT
-# Copyright 2017 Nitish Ragoomundun, Mauritius
+# Copyright 2018 Nitish Ragoomundun, Mauritius
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -21,7 +21,14 @@
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
+# ---------------------------------------------------------------------------
+#
+# Changelog:
+# 02/Aug/2018 : added LD_LIBRARY_PATH and an additional variable for the
+# scripts in /etc/profile.d
+# * Thanks to Eric Lindblad for his suggestions.
+#
+# ---------------------------------------------------------------------------
PRGNAM=pgplot
VERSION=${VERSION:-5.2.2}
@@ -96,17 +103,31 @@ cp -a cpgplot.h $PKG/usr/include/cpgplot.h
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
+
+# /etc/profile.d scripts
mkdir -p $PKG/etc/profile.d/
-cat << EOF > $PKG/etc/profile.d/pgplot.sh.new
+cat << EOF > $PKG/etc/profile.d/pgplot.sh
#!/bin/sh
export PGPLOT_DIR="/usr/lib${LIBDIRSUFFIX}/$PRGNAM"
+export LD_LIBRARY_PATH="\$LD_LIBRARY_PATH:/usr/lib${LIBDIRSUFFIX}/$PRGNAM"
+
+# uncomment the following line if xwin wanted as default
+# export PGPLOT_DEV="/xwin"
EOF
-cat << EOF > $PKG/etc/profile.d/pgplot.csh.new
+
+cat << EOF > $PKG/etc/profile.d/pgplot.csh
#!/bin/csh
setenv PGPLOT_DIR /usr/lib${LIBDIRSUFFIX}/$PRGNAM
+setenv LD_LIBRARY_PATH \$LD_LIBRARY_PATH:/usr/lib${LIBDIRSUFFIX}/$PRGNAM
+
+# uncomment the following line if xwin wanted as default
+# setenv PGPLOT_DEV /xwin
EOF
-chmod 0755 $PKG/etc/profile.d/*
+chmod 0755 $PKG/etc/profile.d/pgplot.{sh,csh}
+
+
+# Copying documentation and changelogs
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a aaaread.me copyright.notice install*.txt ver5*.txt \
$PKG/usr/doc/$PRGNAM-$VERSION