blob: a5635b0034522136a816aab36cc10f0cd291d5c3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
|
#!/bin/bash
# Slackware build script for icbm
# Written by B. Watson (urchlay@slackware.uk)
# Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details.
# Note to self: tarballs with versioned filenames do exist, but the
# link on the homepage is always icbm-current.tar.gz (presumably a
# symlink). To check for updated versions, look at the the top of:
# https://co.ordinate.org/icbm/Changelog
# The crypto modules are actually optional: icbm will run without
# them, with encryption disabled. I've made them required here, to
# keep things simpler for me (and easier for users, too). If you
# really object to this, just don't install them (you still need
# perl-Curses, though).
cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=icbm
VERSION=${VERSION:-1.6.0}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
ARCH=noarch
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}
set -e
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
cd $PRGNAM-$VERSION
chown -R root:root .
# tarball perms suck, leave this as-is:
chmod 644 *
SHAREDIR=$PKG/usr/share/icb
BINDIR=$PKG/usr/bin
MANDIR=$PKG/usr/man/man1
# There's no Makefile or install script, follow the directions
# in INSTALL.
# Note that icbserverdb is different from the one that ships
# with cicb (some of the same servers listed, but the cicb one
# has an extra 'server admin' field).
mkdir -p $SHAREDIR/Net $BINDIR $MANDIR
cp -a primes $SHAREDIR
cp -a icbserverdb $SHAREDIR/icbserverdb.new
cp -a ICB.pm $SHAREDIR/Net
install -m0755 icbm $BINDIR
gzip -9c < icbm.1 > $MANDIR/icbm.1.gz
# BUGS is 0 bytes in 1.6.0. README.ICBM is actually troff, it's the
# man page for an older version.
PKGDOC=$PKG/usr/doc/$PRGNAM-$VERSION
mkdir -p $PKGDOC
cp -a Changelog README.ENCRYPTION TODO gpl.txt sample_* colors $PKGDOC
cat $CWD/$PRGNAM.SlackBuild > $PKGDOC/$PRGNAM.SlackBuild
mkdir -p $PKG/install
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
|