slackbuilds/UNUSED/doc/perl6-book/SlackBuild

55 lines
1.1 KiB
Text
Raw Normal View History

#!/bin/sh
CWD=$(pwd)
PRGNAM=$(basename $CWD)
VERSION=git$(date +"%Y.%m.%d_%H.%M")
BUILD=1
ARCH=$(uname -m)
2016-09-18 22:48:56 +02:00
REPOSITORY=/home/installs/SlackBuilds/repositories/$PRGNAM
2020-06-25 11:23:11 +02:00
TAG=gwh
TMP=/tmp/$TAG
PKG=$TMP/pkg-$PRGNAM
OUTPUT=/tmp
PREFIX=/usr
# cleaning
rm -fr $PKG
# get sources
2016-09-18 22:48:56 +02:00
[ ! -e $REPOSITORY ] && git clone http://github.com/perl6/book.git $REPOSITORY
( cd $REPOSITORY && git pull )
VERSION="git_$( cd $REPOSITORY && git log -1 --format=%h_%ad --date=format:%Y.%m.%d )"
mkdir -p $PKG$PREFIX/doc/
2016-09-18 22:48:56 +02:00
cp -R $REPOSITORY $PKG$PREFIX/doc/$PRGNAM
find $PKG$PREFIX/doc/$PRGNAM -name \.git\* -exec rm -fr {} \;
2016-09-18 22:48:56 +02:00
cd $PKG$PREFIX/doc/$PRGNAM
make
2016-09-18 22:48:56 +02:00
cd $PKG
mkdir -p install
cat <<EOF > install/slack-desc
$PRGNAM: $PRGNAM (a book about Perl 6)
2016-09-18 22:48:56 +02:00
$PRGNAM:
$PRGNAM: It will be some kind of example-driven introduction to Perl 6, and at
$PRGNAM: the same time showing off the reasons why we love that language.
2016-09-18 22:48:56 +02:00
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM: http://github.com/perl6/book
2016-09-18 22:48:56 +02:00
$PRGNAM:
EOF
2016-09-18 22:48:56 +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