diff options
Diffstat (limited to 'python/scikit-umfpack/scikit-umfpack.SlackBuild')
-rw-r--r-- | python/scikit-umfpack/scikit-umfpack.SlackBuild | 36 |
1 files changed, 21 insertions, 15 deletions
diff --git a/python/scikit-umfpack/scikit-umfpack.SlackBuild b/python/scikit-umfpack/scikit-umfpack.SlackBuild index 99de5a1762..0ba4018e1f 100644 --- a/python/scikit-umfpack/scikit-umfpack.SlackBuild +++ b/python/scikit-umfpack/scikit-umfpack.SlackBuild @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash # SlackBuild build script for scikit-umfpack @@ -22,10 +22,16 @@ # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +#### 20230515 bkw: Modified by SlackBuilds.org. See section beginning +#### with "NOT ALLOWED", below. + +cd $(dirname $0) ; CWD=$(pwd) + PRGNAM=scikit-umfpack VERSION=${VERSION:-0.3.2} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} +PKGTYPE=${PKGTYPE:-tgz} if [ -z "$ARCH" ]; then case "$( uname -m )" in @@ -35,8 +41,12 @@ if [ -z "$ARCH" ]; then esac fi -CWD=$(pwd) -TMP=${TMP:-/tmp} +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} @@ -69,7 +79,10 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; - +#### 20230515 bkw: This is NOT ALLOWED. Modifying files in the real +#### /usr, outside of $PKG, is forbidden. SlackBuilds may not do this. +#### Fix this. Ideally, get the umfpack maintainer to fix it in that +#### build, since system headers should not use "blah.h" for includes. ( if [ -f /usr/include/umfpack/umfpack.h ]; then echo "umfpack detected." echo @@ -80,17 +93,10 @@ find -L . \ find . -type f -name "umfpack.h" -print0 | xargs -0 sed -i 's/#include "amd.h"/#include <amd\/amd.h>/g' fi ) -# Python 2.7 will be droped in the future. -if $(python2 -c 'import sys' 2>/dev/null); then - python2 setup.py install --root=$PKG - else - python setup.py install --root=$PKG -fi +# Python 2.7 will be dropped in the future. +python2 setup.py install --root=$PKG -# Replacement of python-2.x Python3.x check presence and build if found. -if $(python3 -c 'import sys' 2>/dev/null); then - python3 setup.py install --root=$PKG -fi +python3 setup.py install --root=$PKG 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 @@ -103,4 +109,4 @@ mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc 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 |