2010-08-06 22:03:53 +02:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
DATE=`date +%d.%m.%Y`
|
|
|
|
DIR="build_$DATE"
|
|
|
|
FILE="$DIR.tar.bz2"
|
|
|
|
|
|
|
|
rm -f $FILE
|
|
|
|
rm -rf $DIR
|
2010-08-20 21:33:59 +02:00
|
|
|
if [ "$1" == "clean" ] ; then
|
2010-08-06 22:03:53 +02:00
|
|
|
make clean
|
2010-08-20 21:33:59 +02:00
|
|
|
fi
|
2010-08-06 22:03:53 +02:00
|
|
|
make || (echo "Compilation failed" ; exit 1)
|
2010-08-20 21:33:59 +02:00
|
|
|
mkdir -p $DIR/lib
|
2010-08-20 21:40:28 +02:00
|
|
|
find $DIR -type f -exec strip \{\} \;
|
|
|
|
cp -r lib/freechart/lib/* lib/wxsqlite3-1.9.9/lib/* $DIR/lib
|
|
|
|
cp -r kc init.sql ressources tools/launch_kc.sh TODO CONTRIBUTORS COPYING README README.fr $DIR
|
2010-08-06 22:03:53 +02:00
|
|
|
tar -jcf $FILE $DIR
|
|
|
|
rm -rf $DIR
|
|
|
|
echo "Packaged !"
|