From 646a5c1cbfd95873950a87b5f75d52073a967023 Mon Sep 17 00:00:00 2001 From: Patrick J Volkerding Date: Mon, 28 May 2018 19:12:29 +0000 Subject: Mon May 28 19:12:29 UTC 2018 a/pkgtools-15.0-noarch-13.txz: Rebuilt. installpkg: default line length for --terselength is the number of columns. removepkg: added --terse mode. upgradepkg: default line length for --terselength is the number of columns. upgradepkg: accept -option in addition to --option. ap/vim-8.1.0026-x86_64-1.txz: Upgraded. d/bison-3.0.5-x86_64-1.txz: Upgraded. e/emacs-26.1-x86_64-1.txz: Upgraded. kde/kopete-4.14.3-x86_64-8.txz: Rebuilt. Recompiled against libidn-1.35. n/conntrack-tools-1.4.5-x86_64-1.txz: Upgraded. n/libnetfilter_conntrack-1.0.7-x86_64-1.txz: Upgraded. n/libnftnl-1.1.0-x86_64-1.txz: Upgraded. n/links-2.16-x86_64-2.txz: Rebuilt. Rebuilt to enable X driver for -g mode. n/lynx-2.8.9dev.19-x86_64-1.txz: Upgraded. n/nftables-0.8.5-x86_64-1.txz: Upgraded. n/p11-kit-0.23.11-x86_64-1.txz: Upgraded. n/ulogd-2.0.7-x86_64-1.txz: Upgraded. n/whois-5.3.1-x86_64-1.txz: Upgraded. xap/network-manager-applet-1.8.12-x86_64-1.txz: Upgraded. xap/vim-gvim-8.1.0026-x86_64-1.txz: Upgraded. --- source/a/util-linux/util-linux.SlackBuild | 112 +++++++++++++++--------------- 1 file changed, 57 insertions(+), 55 deletions(-) (limited to 'source/a/util-linux/util-linux.SlackBuild') diff --git a/source/a/util-linux/util-linux.SlackBuild b/source/a/util-linux/util-linux.SlackBuild index 4d6046024..0d6f9bf70 100755 --- a/source/a/util-linux/util-linux.SlackBuild +++ b/source/a/util-linux/util-linux.SlackBuild @@ -1,6 +1,6 @@ -#!/bin/sh +#!/bin/bash -# Copyright 2008, 2009, 2010, 2011, 2012, 2013, 2015 Patrick J. Volkerding, Sebeka, MN, USA +# Copyright 2008, 2009, 2010, 2011, 2012, 2013, 2015, 2017, 2018 Patrick J. Volkerding, Sebeka, MN, USA # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -22,14 +22,17 @@ # Slackware build script for util-linux +cd $(dirname $0) ; CWD=$(pwd) + +PKGNAM=util-linux VERSION=${VERSION:-$(echo util-linux*.tar.xz | cut -d - -f 3 | rev | cut -f 3- -d . | rev)} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} ADJTIMEXVERS=1.29 SETSERIALVERS=2.17 ZIPTOOLVERS=1.4.0 -NUMJOBS=${--j8} +NUMJOBS=${NUMJOBS:-" -j7 "} # Automatically determine the architecture we're building on: if [ -z "$ARCH" ]; then @@ -41,6 +44,14 @@ if [ -z "$ARCH" ]; then esac fi +# 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 "$PKGNAM-$VERSION-$ARCH-$BUILD.txz" + exit 0 +fi + if [ "$ARCH" = "i586" ]; then SLKCFLAGS="-O2 -march=i586 -mtune=i686" LIBDIRSUFFIX="" @@ -55,7 +66,6 @@ else LIBDIRSUFFIX="" fi -CWD=$(pwd) TMP=${TMP:-/tmp} PKG=$TMP/package-util-linux @@ -77,7 +87,15 @@ find . \ # 83 back to "Linux swap": zcat $CWD/util-linux.fdisk-no-solaris.diff.gz | patch -p1 --verbose || exit 1 -CFLAGS="$SLKCFLAGS" \ +# This just call the configure script with $1 either being 2 for python2 +# or 3 for python3. +# +# The releasenotes say to use --runstatedir, but it doesn't work and the +# configure script fails. So we'll leave things using localstatedir, but +# check again later: +# +# --runstatedir=/run +configure_with_python(){ ./configure \ --prefix=/usr \ --libdir=/usr/lib${LIBDIRSUFFIX} \ @@ -88,15 +106,15 @@ CFLAGS="$SLKCFLAGS" \ --docdir=/usr/doc/util-linux-$VERSION \ --disable-static \ --enable-agetty \ - --disable-eject \ --enable-kill \ --disable-last \ + --enable-libmount-support-mtab \ --enable-line \ --enable-mesg \ --enable-partx \ + --enable-pg \ --enable-raw \ --enable-rename \ - --enable-reset \ --disable-login \ --enable-schedutils \ --enable-wall \ @@ -106,19 +124,24 @@ CFLAGS="$SLKCFLAGS" \ --enable-libmount \ --enable-libuuid \ --disable-uuidd \ - --with-python=2 \ - --without-readline \ - --build=$ARCH-slackware-linux \ - || exit 1 + --with-python=$1 \ + --build=$ARCH-slackware-linux +} -# UNUSED, but maybe needed if we enable readline here: -# -# Yet another project that doesn't seem to get that -readline requires either -# -ltermcap or -lncurses on systems that don't make assumptions... -#sed -i -e 's|-lreadline|\0 -lncursesw|g' Makefile +CFLAGS="$SLKCFLAGS" \ + configure_with_python 2 || exit 1 + +make $NUMJOBS || make || exit 1 +make install DESTDIR=$PKG || exit 1 -make $NUMBJOBS || make || exit 1 -make install DESTDIR=$PKG || make install DESTDIR=$PKG +# Build python3 bindings for libmount: +make clean +CFLAGS="$SLKCFLAGS" \ + configure_with_python 3 || exit 1 +make \ + install-pylibmountexecLTLIBRARIES \ + install-pylibmountexecPYTHON \ + DESTDIR=$PKG || exit 1 # Remove all overlap with the shadow package, since --disable-login doesn't quite do that: rm $PKG/sbin/nologin $PKG/usr/man/man8/nologin.8 $PKG/sbin/sulogin $PKG/usr/man/man8/sulogin.8 @@ -161,7 +184,7 @@ cp -a ddate $PKG/usr/bin cat ddate.1 > $PKG/usr/man/man1/ddate.1 chown root:root $PKG/usr/bin/ddate -# Build ziptool +# Build ziptool (install as jaztool to avoid conflict with libzip): cd $TMP || exit 1 rm -rf ziptool-$ZIPTOOLVERS tar xvf $CWD/ziptool-$ZIPTOOLVERS.tar.xz || exit 1 @@ -172,12 +195,12 @@ cat $CWD/scsi_ioctl.h > scsi/scsi_ioctl.h chown -R root:root . make || exit 1 strip ziptool -cat ziptool > $PKG/sbin/ziptool -chmod 0755 $PKG/sbin/ziptool +cat ziptool > $PKG/sbin/jaztool +chmod 0755 $PKG/sbin/jaztool mkdir -p $PKG/usr/doc/ziptool-$ZIPTOOLVERS cp -a README $PKG/usr/doc/ziptool-$ZIPTOOLVERS chmod 644 $PKG/usr/doc/ziptool-$ZIPTOOLVERS/* -cat ziptool.1.gz > $PKG/usr/man/man1/ziptool.1.gz +cat ziptool.1.gz > $PKG/usr/man/man1/jaztool.1.gz # Build bsdstrings cd $TMP || exit 1 @@ -187,34 +210,9 @@ cd bsdstrings || exit 1 zcat $CWD/bsdstrings-util-linux_overflow.diff.gz | patch -p1 --verbose || exit 1 make || exit 1 strip strings -cat strings > $PKG/usr/bin/strings -chmod 0755 $PKG/usr/bin/strings -cat strings.1 | gzip -9c > $PKG/usr/man/man1/strings.1.gz - -# Add just the hostname utilities from net-tools, so that anyone -# installing just the A series will not have a hostname (null): -cd $TMP || exit 1 -rm -rf net-tools-1.60.20120726git -tar xvf $CWD/net-tools-1.60.20120726git.tar.xz -cd net-tools-1.60.20120726git -zcat $CWD/net-tools.config.h.gz > config.h -make -make hostname -strip hostname -cat hostname > $PKG/bin/hostname -chmod 755 $PKG/bin/hostname -chown root:root $PKG/bin/hostname -( cd $PKG/bin - ln -sf hostname dnsdomainname - ln -sf hostname nisdomainname - ln -sf hostname ypdomainname - ln -sf hostname domainname -) -cd man/en_US -for page in hostname.1 dnsdomainname.1 nisdomainname.1 ypdomainname.1 \ -domainname.1 ; do - cat $page | gzip -9c > $PKG/usr/man/man1/$page.gz -done +cat strings > $PKG/usr/bin/strings-BSD +chmod 0755 $PKG/usr/bin/strings-BSD +cat strings.1 | gzip -9c > $PKG/usr/man/man1/strings-BSD.1.gz # Build adjtimex cd $TMP || exit 1 @@ -268,7 +266,7 @@ cd $TMP/util-linux-$VERSION # Go back home :) ( cd $PKG/sbin ln -s ../bin/mount . ln -s ../bin/umount . - ln -s ziptool jaztool + #ln -s ziptool jaztool ln -s hwclock clock cd $PKG/usr/sbin ln -s ../../sbin/cfdisk . @@ -281,7 +279,7 @@ cd $TMP/util-linux-$VERSION # Go back home :) ln -s ../../bin/more . ln -s ../../sbin/raw . cd $PKG/usr/man/man1 - ln -s ziptool.1 jaztool.1 + #ln -s ziptool.1 jaztool.1 cd $PKG/usr/man/man8 ln -s hwclock.8 clock.8 ) @@ -289,6 +287,9 @@ cd $TMP/util-linux-$VERSION # Go back home :) find $PKG | xargs file | grep -e "executable" -e "shared object" \ | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null +# Don't ship .la files: +rm -f $PKG/{,usr/}lib${LIBDIRSUFFIX}/*.la + # Compress and if needed symlink the man pages: if [ -d $PKG/usr/man ]; then ( cd $PKG/usr/man @@ -309,8 +310,9 @@ rm $PKG/usr/info/dir gzip -9 $PKG/usr/info/* mkdir -p $PKG/usr/doc/util-linux-$VERSION -cp -a AUTHORS COPYING DEPRECATED NEWS README* TODO \ - docs/v${VERSION}-ReleaseNotes \ +cp -a AUTHORS COPYING* DEPRECATED NEWS README* \ + Documentation/v${VERSION}-ReleaseNotes \ + Documentation/licenses/* Documentation/{TODO,*.txt} \ $PKG/usr/doc/util-linux-$VERSION mkdir $PKG/install -- cgit v1.2.3-79-gdb01