2008-09-01 02:52:32 +07:00
|
|
|
default:
|
|
|
|
echo "sorry, no default action"
|
|
|
|
|
2009-02-24 08:32:00 +07:00
|
|
|
source: clean
|
|
|
|
rm -rf /tmp/relational/
|
|
|
|
mkdir /tmp/relational/
|
|
|
|
cp -R * /tmp/relational/
|
|
|
|
rm -rf /tmp/relational/samples/.svn/ /tmp/relational/debscript/.svn/ /tmp/relational/mac/.svn/
|
2009-02-24 14:52:19 +07:00
|
|
|
echo "cd /tmp ; tar -jcvvf relational.tar.bz relational/" | bash
|
|
|
|
mv /tmp/relational.tar.bz ./relational_`./relational.py -v`.tar.bz
|
2009-02-24 08:32:00 +07:00
|
|
|
|
2008-09-01 02:52:32 +07:00
|
|
|
clean:
|
2009-02-24 08:32:00 +07:00
|
|
|
rm -rf *~ || echo ok
|
|
|
|
rm -rf *.pyc *.pyo || echo ok
|
2008-09-01 02:52:32 +07:00
|
|
|
rm -rf Relational.app || echo ok
|
2008-09-21 10:33:51 +07:00
|
|
|
rm -rf relational || echo ok
|
2008-11-15 09:51:04 +07:00
|
|
|
rm relational*.tar.gz || echo ok
|
2008-11-15 09:33:02 +07:00
|
|
|
rm -rf data || echo ok
|
2009-02-24 08:32:00 +07:00
|
|
|
rm -rf *tar.bz || echo ok
|
2008-11-15 09:33:02 +07:00
|
|
|
rm -rf *.deb || echo ok
|
2008-09-01 02:52:32 +07:00
|
|
|
mac: app
|
|
|
|
mkdir relational || echo Exists
|
|
|
|
mv Relational.app relational
|
|
|
|
mkdir relational/samples || echo Exists
|
2009-02-24 14:52:19 +07:00
|
|
|
cp samples/*csv relational/samples
|
2008-11-15 09:51:04 +07:00
|
|
|
tar -zcvvf relational_`./relational.py -v`.tar.gz relational/
|
2008-09-01 02:52:32 +07:00
|
|
|
app:
|
|
|
|
mkdir Relational.app/ || echo Exists
|
|
|
|
mkdir Relational.app/Contents || echo Exists
|
|
|
|
mkdir Relational.app/Contents/Resources || echo Exists
|
|
|
|
cp *py Relational.app/Contents/Resources
|
|
|
|
cp mac/Info.plist mac/PkgInfo Relational.app/Contents
|
|
|
|
mkdir Relational.app/Contents/MacOS || echo Exists
|
|
|
|
cp mac/relational mac/Python Relational.app/Contents/MacOS
|
|
|
|
cp mac/PythonApplet.icns mac/__argvemulator_relational.py Relational.app/Contents/Resources/
|
2008-11-15 09:33:02 +07:00
|
|
|
|
2008-11-15 09:51:04 +07:00
|
|
|
debian:
|
2008-11-15 09:33:02 +07:00
|
|
|
#Python files
|
2008-11-15 11:09:31 +07:00
|
|
|
mkdir -p data/usr/share/python-support/relational/
|
2008-11-15 09:33:02 +07:00
|
|
|
|
|
|
|
cp *py data/usr/share/python-support/relational/
|
2008-11-15 11:09:31 +07:00
|
|
|
|
|
|
|
#man
|
|
|
|
mkdir -p data/usr/share/man/man1
|
|
|
|
cp relational.1 data/usr/share/man/man1
|
|
|
|
gzip --best data/usr/share/man/man1/relational.1
|
|
|
|
|
2008-11-15 09:33:02 +07:00
|
|
|
#doc
|
2008-11-15 11:09:31 +07:00
|
|
|
mkdir -p data/usr/share/doc/relational
|
|
|
|
|
|
|
|
echo "Copyright (C) 2008 Salvo "LtWorf" Tomaselli" >> data/usr/share/doc/relational/copyright
|
|
|
|
echo "" >> data/usr/share/doc/relational/copyright
|
|
|
|
echo "License:" >> data/usr/share/doc/relational/copyright
|
|
|
|
echo "This program is under the GPLv3 license" >> data/usr/share/doc/relational/copyright
|
|
|
|
|
2008-11-15 09:33:02 +07:00
|
|
|
cp CHANGELOG data/usr/share/doc/relational/changelog
|
2008-12-09 11:24:24 +07:00
|
|
|
echo "relational ("`./relational.py -v | cut -d. -f1`":"`./relational.py -v`+SVN`svn update | cut -d" " -f3 | tr -d "."`") unstable; urgency=low" >> data/usr/share/doc/relational/changelog.Debian
|
2008-11-15 11:09:31 +07:00
|
|
|
echo "" >> data/usr/share/doc/relational/changelog.Debian
|
|
|
|
echo " * Automatically generated package, see changelog.gz" >> data/usr/share/doc/relational/changelog.Debian
|
|
|
|
echo "" >> data/usr/share/doc/relational/changelog.Debian
|
|
|
|
echo " -- Make <make@make.org> Fri, 10 Oct 2008 19:18:35 +0200">> data/usr/share/doc/relational/changelog.Debian
|
|
|
|
|
|
|
|
gzip --best data/usr/share/doc/relational/changelog.Debian
|
|
|
|
gzip --best data/usr/share/doc/relational/changelog
|
2008-11-15 09:33:02 +07:00
|
|
|
cp -r samples data/usr/share/doc/relational/examples
|
|
|
|
rm -rf data/usr/share/doc/relational/examples/.svn
|
|
|
|
|
|
|
|
#start script
|
2008-11-15 11:09:31 +07:00
|
|
|
mkdir -p data/usr/bin
|
2009-02-26 05:18:07 +07:00
|
|
|
cp debscript/relational data/usr/bin/relational
|
2008-11-15 09:33:02 +07:00
|
|
|
chmod a+x data/usr/bin/relational
|
|
|
|
|
|
|
|
#desktop file
|
2008-11-15 11:09:31 +07:00
|
|
|
mkdir -p data/usr/share/applications/
|
2009-02-26 05:18:07 +07:00
|
|
|
cp debscript/relational.desktop data/usr/share/applications/
|
2008-11-15 09:33:02 +07:00
|
|
|
|
2008-11-15 11:09:31 +07:00
|
|
|
mkdir -p data/DEBIAN
|
2008-11-15 09:33:02 +07:00
|
|
|
#package description
|
2009-02-26 05:18:07 +07:00
|
|
|
debscript/gencontrol.sh data/DEBIAN/control
|
2008-12-09 11:24:24 +07:00
|
|
|
|
|
|
|
#Postrm file to remove optimized generated python files
|
2009-02-26 05:18:07 +07:00
|
|
|
#cp debscript/prerm data/DEBIAN/prerm
|
2008-12-09 11:24:24 +07:00
|
|
|
|
2008-12-09 11:47:45 +07:00
|
|
|
chmod 0755 data/DEBIAN/prerm data/DEBIAN/postinst
|
2008-12-09 11:24:24 +07:00
|
|
|
|
2008-11-15 09:51:04 +07:00
|
|
|
su -c "chown -R root:root data/*; dpkg -b data/ relational.deb; rm -rf data/"
|
2008-12-09 11:24:24 +07:00
|
|
|
cp relational.deb relational_`./relational.py -v`+SVN`svn update | cut -d" " -f3 | tr -d "."`.deb
|
2008-11-15 09:51:04 +07:00
|
|
|
rm -f relational.deb
|