summaryrefslogtreecommitdiffstats
path: root/source/d/rcs
diff options
context:
space:
mode:
author Patrick J Volkerding <volkerdi@slackware.com>2013-11-04 17:08:47 +0000
committer Eric Hameleers <alien@slackware.com>2018-05-31 22:57:36 +0200
commit76fc4757ac91ac7947a01fb7b53dddf9a78a01d1 (patch)
tree9b98e6e193c7870cb27ac861394c1c4592850922 /source/d/rcs
parent9664bee729d487bcc0a0bc35859f8e13d5421c75 (diff)
downloadcurrent-76fc4757ac91ac7947a01fb7b53dddf9a78a01d1.tar.gz
current-76fc4757ac91ac7947a01fb7b53dddf9a78a01d1.tar.xz
Slackware 14.1slackware-14.1
Mon Nov 4 17:08:47 UTC 2013 Slackware 14.1 x86_64 stable is released! It's been another interesting release cycle here at Slackware bringing new features like support for UEFI machines, updated compilers and development tools, the switch from MySQL to MariaDB, and many more improvements throughout the system. Thanks to the team, the upstream developers, the dedicated Slackware community, and everyone else who pitched in to help make this release a reality. The ISOs are off to be replicated, a 6 CD-ROM 32-bit set and a dual-sided 32-bit/64-bit x86/x86_64 DVD. Please consider supporting the Slackware project by picking up a copy from store.slackware.com. We're taking pre-orders now, and offer a discount if you sign up for a subscription. Have fun! :-)
Diffstat (limited to 'source/d/rcs')
-rw-r--r--source/d/rcs/rcs-5.7.diff17
-rwxr-xr-xsource/d/rcs/rcs.SlackBuild131
2 files changed, 88 insertions, 60 deletions
diff --git a/source/d/rcs/rcs-5.7.diff b/source/d/rcs/rcs-5.7.diff
deleted file mode 100644
index a53b351cd..000000000
--- a/source/d/rcs/rcs-5.7.diff
+++ /dev/null
@@ -1,17 +0,0 @@
---- src/conf.sh.orig Sat Aug 12 20:25:11 1995
-+++ src/conf.sh Sat Aug 12 20:25:45 1995
-@@ -77,10 +77,10 @@
- rm -f a.d &&
- date >a.d &&
- chmod 0 a.d &&
--{ test -w a.d || cp /dev/null a.d 2>/dev/null; } && {
-- echo >&3 "$n$0: This command should not be run with superuser permissions."
-- exit 1
--}
-+#{ test -w a.d || cp /dev/null a.d 2>/dev/null; } && {
-+# echo >&3 "$n$0: This command should not be run with superuser permissions."
-+# exit 1
-+#}
- echo >&3 OK
- rm -f a.d || exit
-
diff --git a/source/d/rcs/rcs.SlackBuild b/source/d/rcs/rcs.SlackBuild
index 7a3980179..8faa20ae0 100755
--- a/source/d/rcs/rcs.SlackBuild
+++ b/source/d/rcs/rcs.SlackBuild
@@ -1,6 +1,6 @@
#!/bin/sh
-# Copyright 2008, 2009, 2010 Patrick J. Volkerding, Sebeka, Minnesota, USA
+# Copyright 2013 Patrick J. Volkerding, Sebeka, Minnesota, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -20,47 +20,61 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-VERSION=5.7
-BUILD=${BUILD:-2}
+
+PKGNAM=rcs
+VERSION=${VERSION:-$(echo $PKGNAM-*.tar.xz | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
+BUILD=${BUILD:-1}
# Automatically determine the architecture we're building on:
if [ -z "$ARCH" ]; then
- case "$( uname -m )" in
- i?86) export ARCH=i486 ;;
- arm*) export ARCH=arm ;;
+ case "$(uname -m)" in
+ i?86) ARCH=i486 ;;
+ arm*) readelf /usr/bin/file -A | egrep -q "Tag_CPU.*[4,5]" && ARCH=arm || ARCH=armv7lh ;;
# Unless $ARCH is already set, use uname -m for all other archs:
- *) export ARCH=$( uname -m ) ;;
+ *) ARCH=$(uname -m) ;;
esac
+ export ARCH
fi
-if [ "$ARCH" = "i486" ]; then
+NUMJOBS=${NUMJOBS:-" -j7 "}
+
+if [ "$ARCH" = "i386" ]; then
+ SLKCFLAGS="-O2 -march=i386 -mcpu=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i486" ]; then
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i586" ]; then
+ SLKCFLAGS="-O2 -march=i586 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march=i686"
+ LIBDIRSUFFIX=""
elif [ "$ARCH" = "s390" ]; then
SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
+elif [ "$ARCH" = "armv7hl" ]; then
+ SLKCFLAGS="-O3 -march=armv7-a -mfpu=vfpv3-d16"
+ LIBDIRSUFFIX=""
else
SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
fi
CWD=$(pwd)
TMP=${TMP:-/tmp}
-PKG=$TMP/package-rcs
+PKG=$TMP/package-$PKGNAM
rm -rf $PKG
mkdir -p $TMP $PKG
-# Explode the package framework:
-cd $PKG
-explodepkg $CWD/_rcs.tar.gz
-
-echo "+=========+"
-echo "| rcs-$VERSION |"
-echo "+=========+"
cd $TMP
-rm -rf rcs-$VERSION
-tar xvf $CWD/rcs-$VERSION.tar.gz || exit 1
-cd rcs-$VERSION
+rm -rf $PKGNAM-$VERSION
+tar xvf $CWD/$PKGNAM-$VERSION.tar.xz || exit 1
+cd $PKGNAM-$VERSION
chown -R root:root .
find . \
@@ -69,35 +83,66 @@ find . \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \;
-zcat $CWD/rcs-$VERSION.diff.gz | patch -p0 || exit 1
-
-./configure --prefix=/usr
-
-make CFLAGS="$SLKCFLAGS" LDFLAGS=-s || exit 1
+# Configure:
+CFLAGS="$SLKCFLAGS" \
+./configure \
+ --prefix=/usr \
+ --sysconfdir=/etc \
+ --libdir=/usr/lib${LIBDIRSUFFIX} \
+ --mandir=/usr/man \
+ --infodir=/usr/info \
+ --build=$ARCH-slackware-linux
+
+# Build and install:
+make $NUMJOBS || make || exit 1
+make install DESTDIR=$PKG || exit 1
+
+# Strip binaries:
+( cd $PKG
+ find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
+ find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
+)
+
+# Add a documentation directory:
+mkdir -p $PKG/usr/doc/${PKGNAM}-$VERSION
+cp -a \
+ AUTHORS COPYING* HACKING INSTALL NEWS README* THANKS TODO \
+ $PKG/usr/doc/${PKGNAM}-$VERSION
+
+# Compress and if needed symlink the man pages:
+if [ -d $PKG/usr/man ]; then
+ ( cd $PKG/usr/man
+ for manpagedir in $(find . -type d -name "man*") ; do
+ ( cd $manpagedir
+ for eachpage in $( find . -type l -maxdepth 1) ; do
+ ln -s $( readlink $eachpage ).gz $eachpage.gz
+ rm $eachpage
+ done
+ gzip -9 *.?
+ )
+ done
+ )
+fi
-cd src
-cat ci > $PKG/usr/bin/ci
-cat co > $PKG/usr/bin/co
-cat ident > $PKG/usr/bin/ident
-cat merge > $PKG/usr/bin/merge
-cat rcs > $PKG/usr/bin/rcs
-cat rcsclean > $PKG/usr/bin/rcsclean
-cat rcsdiff > $PKG/usr/bin/rcsdiff
-cat rcsmerge > $PKG/usr/bin/rcsmerge
-cat rcstest > $PKG/usr/bin/rcstest
-cat rlog > $PKG/usr/bin/rlog
+# Compress info files, if any:
+if [ -d $PKG/usr/info ]; then
+ ( cd $PKG/usr/info
+ rm -f dir
+ gzip -9 *
+ )
+fi
-cd ../man
-for page in ci.1 co.1 ident.1 merge.1 rcs.1 rcsclean.1 rcsdiff.1 rcsfreeze.1 \
-rcsintro.1 rcsmerge.1 rlog.1 ; do
- cat $page | gzip -9c > $PKG/usr/man/man1/$page.gz
-done
-cat rcsfile.5 | gzip -9c > $PKG/usr/man/man5/rcsfile.5.gz
+# If there's a ChangeLog, installing at least part of the recent history
+# is useful, but don't let it get totally out of control:
+if [ -r ChangeLog ]; then
+ DOCSDIR=$(echo $PKG/usr/doc/${PKGNAM}-$VERSION)
+ cat ChangeLog | head -n 1000 > $DOCSDIR/ChangeLog
+ touch -r ChangeLog $DOCSDIR/ChangeLog
+fi
mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
-# Build the package:
cd $PKG
-/sbin/makepkg -l y -c n $TMP/rcs-$VERSION-$ARCH-$BUILD.txz
+/sbin/makepkg -l y -c n $TMP/$PKGNAM-$VERSION-$ARCH-$BUILD.txz