summaryrefslogtreecommitdiffstats
path: root/development/julia/julia.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'development/julia/julia.SlackBuild')
-rw-r--r--development/julia/julia.SlackBuild28
1 files changed, 19 insertions, 9 deletions
diff --git a/development/julia/julia.SlackBuild b/development/julia/julia.SlackBuild
index 0894aabbf5..4ca8c10fe8 100644
--- a/development/julia/julia.SlackBuild
+++ b/development/julia/julia.SlackBuild
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
# Slackware build script for julia
@@ -22,11 +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=julia
-VERSION=${VERSION:-0.6.0}
-VERSION_TAG=${VERSION_TAG:-903644385b}
+VERSION=${VERSION:-1.3.1}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
@@ -36,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}
@@ -63,9 +72,9 @@ set -e
rm -rf $PKG
mkdir -p $TMP $PKG $PKG/usr $OUTPUT
cd $TMP
-rm -rf $PRGNAM-${VERSION_TAG}
+rm -rf $PRGNAM-${VERSION}
tar xvf $CWD/$PRGNAM\-${VERSION}\-linux\-$ARCH.tar.gz
-cd $PRGNAM-${VERSION_TAG}
+cd $PRGNAM-${VERSION}
chown -R root:root .
find -L . \
\( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
@@ -78,10 +87,11 @@ cp -r etc $PKG/usr/etc
cp -r include $PKG/usr/include
# The julia binary expects all its libs to be in lib, not lib${LIBDIRSUFFIX}
cp -r lib $PKG/usr/lib
+cp -r libexec $PKG/usr/libexec
cp -r share $PKG/usr/share
-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
+# Don't strip binaries as it could cause some breakage
+# https://github.com/JuliaLang/julia/issues/34936
mv $PKG/usr/share/man $PKG/usr/
find $PKG/usr/man -type f -exec gzip -9 {} \;
@@ -100,4 +110,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