aboutsummaryrefslogtreecommitdiff
path: root/system/Sl/Sl.SlackBuild
blob: 3e7726a779c8bf18858fca9bd8546b7b96bfbe19 (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
#!/bin/bash

# Slackware build script for Sl

# Written by B. Watson (yalhcru@gmail.com)

# Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details.

# There's already an "sl" on SBo, so this is named Sl. The version number
# comes from the -version option.

cd $(dirname $0) ; CWD=$(pwd)

PRGNAM=Sl
VERSION=${VERSION:-1.1.3}
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}

SRCNAM="sl"

PKGBIN=$PKG/usr/bin
PKGMAN1=$PKG/usr/man/man1
PKGDOC=$PKG/usr/doc/$PRGNAM-$VERSION
PKGINST=$PKG/install

set -e

rm -rf $PKG
mkdir -p $OUTPUT $PKGBIN $PKGDOC $PKGMAN1 $PKGINST

# Look, Ma, no source directory!
cat $SRCNAM > $PKGBIN/$PRGNAM
chmod 755 $PKGBIN/$PRGNAM

gzip -9c < $PRGNAM.1 > $PKGMAN1/$PRGNAM.1.gz

# README.upstream is just a text rendition of the homepage, sl.tcl-example
# is linked to by the homepage.
cat README.upstream > $PKGDOC/README.txt
cat sl.tcl.example > $PKGDOC/sl.tcl.example
cat README > $PKGDOC/README_SBo.txt
cat $PRGNAM.SlackBuild > $PKGDOC/$PRGNAM.SlackBuild

cat slack-desc > $PKGINST/slack-desc
cat doinst.sh > $PKGINST/doinst.sh

cd $PKG
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE