slackbuilds/UNUSED/doc/diveintopython3/SlackBuild

57 lines
913 B
Text
Raw Normal View History

2010-04-14 12:58:46 +02:00
#!/bin/sh
CWD=$(pwd)
PRGNAM=$(basename $CWD)
2011-10-05 09:31:51 +02:00
VERSION=$(date +"%Y.%m.%d_%H.%M")
2010-04-14 12:58:46 +02:00
BUILD=1
2011-10-05 09:31:51 +02:00
ARCH=noarch
2010-04-14 12:58:46 +02:00
2011-10-05 09:31:51 +02:00
REPOSITORY=/home/installs/SlackBuilds/repositories/$PRGNAM
2010-04-14 12:58:46 +02:00
2020-06-25 11:23:11 +02:00
TAG=gwh
TMP=/tmp/$TAG
2010-04-14 12:58:46 +02:00
PKG=$TMP/pkg-$PRGNAM
OUTPUT=/tmp
PREFIX=/usr
# cleaning
rm -fr $PKG
# get sources
2011-10-05 09:31:51 +02:00
if [ -e $REPOSITORY ] ; then
( cd $REPOSITORY
git pull
)
else
git clone http://github.com/diveintomark/diveintopython3.git $REPOSITORY
2011-10-05 09:31:51 +02:00
fi
2010-04-14 12:58:46 +02:00
mkdir -p $PKG$PREFIX/doc/
2011-10-05 09:31:51 +02:00
cp -R $REPOSITORY $PKG$PREFIX/doc/$PRGNAM
rm -fr $PKG$PREFIX/doc/$PRGNAM/.{git*,hg*}
2010-04-14 12:58:46 +02:00
2011-10-05 09:31:51 +02:00
cd $PKG
mkdir -p install
cat <<EOF > install/slack-desc
2010-04-14 12:58:46 +02:00
$PRGNAM: $PRGNAM (a book about Python 3)
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM: http://diveintopython3.org
$PRGNAM:
EOF
2011-10-05 09:31:51 +02:00
chown -R root:root *
rm -f $PKG/{,usr/}lib$(uname -m | grep -o 64)/*.la
2020-07-12 09:22:26 +02:00
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.txz
2010-04-14 12:58:46 +02:00