diff options
-rw-r--r-- | development/mlton/mlton.SlackBuild | 28 | ||||
-rw-r--r-- | development/mlton/mlton.info | 2 |
2 files changed, 18 insertions, 12 deletions
diff --git a/development/mlton/mlton.SlackBuild b/development/mlton/mlton.SlackBuild index c399bb907b9a..823ca65d83cd 100644 --- a/development/mlton/mlton.SlackBuild +++ b/development/mlton/mlton.SlackBuild @@ -28,14 +28,13 @@ PRGNAM=mlton VERSION=${VERSION:-20180207} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} -PREBUILT=$PRGNAM-$VERSION-$BUILD.amd64-linux +PREBUILT=${PREBUILT:-$PRGNAM-$VERSION-1.amd64-linux} -if [ -z "$ARCH" ]; then - case "$( uname -m )" in - x86_64) ARCH=x86_64 ;; +ARCH=${ARCH:-$(uname -m)} +case "$ARCH" in + x86_64) : ;; *) printf "This script only supports x86_64.\n" 1>&2; exit 1 ;; - esac -fi +esac CWD=$(pwd) TMP=${TMP:-/tmp/SBo} @@ -51,22 +50,29 @@ rm -rf $PREBUILT $PRGNAM-$VERSION tar xvf $CWD/$PREBUILT.tgz tar xvf $CWD/$PRGNAM-$VERSION.src.tgz -cd $PRGNAM-$VERSION - # Permissions are already set -chown -R root:root . +chown -R root:root $PREBUILT $PRGNAM-$VERSION + +cd $PRGNAM-$VERSION # Prefer the pre-built compiler PATH=$TMP/$PREBUILT/bin:$PATH -make all + +# Without any ulimit, "amd64 code gen" uses all available memory. +ulimit -v 4000000 + +make -j1 all make PREFIX="$PKG" install +# Fix ownership of stuff from 'make install' +chown -R root:root $PKG + # Binaries are already stripped cd $PKG mkdir -p usr mv share/man usr -if [ "$1" == "-docs" ]; then +if [ "$1" = "-docs" ]; then mkdir -p usr/share/doc mv share/doc/$PRGNAM usr/share/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > usr/share/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild diff --git a/development/mlton/mlton.info b/development/mlton/mlton.info index 3df87be02548..94214390e358 100644 --- a/development/mlton/mlton.info +++ b/development/mlton/mlton.info @@ -4,7 +4,7 @@ HOMEPAGE="http://mlton.org" DOWNLOAD="UNSUPPORTED" MD5SUM="" DOWNLOAD_x86_64="https://downloads.sourceforge.net/project/mlton/mlton/20180207/mlton-20180207-1.amd64-linux.tgz \ - https://downloads.sourceforge.net/project/mlton/mlton/20180207/mlton-20180207.src.tgz" + https://downloads.sourceforge.net/project/mlton/mlton/20180207/mlton-20180207.src.tgz" MD5SUM_x86_64="e318ea7d87cb1996c921810e278cb717 \ efa5a6b70d964daefefe4b2581173ad9" REQUIRES="" |