slackbuilds/web/fatfree/fatfree.SlackBuild

72 lines
1.7 KiB
Text
Raw Normal View History

2011-02-08 11:53:05 +01:00
#!/bin/sh
CWD=$(pwd)
PRGNAM=$(basename $CWD)
VERSION=trunk$(date +%Y.%m.%d_%H.%M)
BUILD=1
2011-02-08 11:53:05 +01:00
ARCH=$(uname -m)
REPOSITORIES=/home/cycojesus/projets/packages/repositories
TAG=cyco
TMP=/tmp/$TAG
2011-02-08 11:53:05 +01:00
PKG=$TMP/pkg-$PRGNAM
OUTPUT=/tmp
PREFIX=/usr
# cleaning
rm -fr $PKG
# get sources
[ ! -e $REPOSITORIES ] && mkdir -p $REPOSITORIES
( cd $REPOSITORIES
if [ -e $REPOSITORIES/$PRGNAM ] ; then
( cd $REPOSITORIES/$PRGNAM
svn up
)
else
svn co https://fatfree.svn.sourceforge.net/svnroot/fatfree $REPOSITORIES/$PRGNAM
fi
)
2011-02-08 12:30:52 +01:00
mkdir -p $PKG/srv/www/htdocs $PKG$PREFIX/doc/
2011-02-08 11:53:05 +01:00
cp -R $REPOSITORIES/$PRGNAM $PKG/srv/www/htdocs/
find $PKG/srv/www/htdocs -name \.svn\* -exec rm -fr {} \;
if [ ! -e $CWD/fatfree.sourceforge.net ]; then
( cd $CWD
wget -cpk http://fatfree.sourceforge.net/
)
fi
cp -R $CWD/fatfree.sourceforge.net $PKG$PREFIX/doc/$PRGNAM
2011-02-08 13:21:03 +01:00
mkdir -p $PKG$PREFIX/doc/$PRGNAM/demos $CWD/demos/
for i in fatfree-url.zip fatfree-oop.zip fatfree-ini.zip fatfree-i18n.zip fatfree-blog.zip; do
wget -c http://sourceforge.net/projects/fatfree/files/$i/download -O $CWD/demos/$i
cp $CWD/demos/$i $PKG$PREFIX/doc/$PRGNAM/demos
done
2011-02-08 11:53:05 +01:00
( cd $PKG
mkdir -p install
cat <<EOF > install/slack-desc
$PRGNAM: $PRGNAM (PHP Web framwork)
$PRGNAM:
$PRGNAM: FAT-FREE is a powerful and lightweight PHP 5.3+ Web application framework
$PRGNAM: designed to help you build dynamic and robust Web sites - fast! Unlike
$PRGNAM: other PHP frameworks, Fat-Free aims to be usable - not usual.
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM: http://fatfree.sourceforge.net/
$PRGNAM:
EOF
chown -R root:root *
makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.txz
2011-02-08 11:53:05 +01:00
)