1 # Maintainer: RetroX <classixretrox@gmail.com>
5 pkgdesc="An open-source alternative to YoYoGame's Game Maker, written in C++."
6 pkglongdesc="ENIGMA Development Environment
8 An open-source alternative to YoYoGame's Game Maker, written in C++."
10 arch=('i386' 'i486' 'i586' 'i686' 'x86_64' 'amd64')
11 url="http://enigma-dev.org"
13 depends=('libgl' 'libx11' 'mesa' 'zlib' 'openal' 'gcc' 'make' 'java-runtime>=6' 'gtk2' 'lateralgm')
14 debdepends=('libgl1-mesa-dev' 'libglu1-mesa-dev ' 'libx11-dev' 'libz-dev' 'libopenal-dev' 'libgtk2.0-dev' 'gcc' 'g++' 'make' 'java-common' 'lateralgm')
15 makedepends=('subversion')
16 provides=('enigma-dev')
19 _svntrunk="https://enigma-dev.svn.sourceforge.net/svnroot/enigma-dev/trunk"
21 install="enigma.install"
22 debpreinst="enigma.preinst"
23 debpostinst="enigma.postinst"
24 debpostrm="enigma.postrm"
25 lzmpostinst="enigma.postinst"
26 export PKGARCH="$PKGARCH"
31 svn co $_svntrunk $_svnmod
33 mkdir -p $pkgdir/opt/enigma
35 cp -r $srcdir/$_svnmod -T $pkgdir/opt/enigma
37 mv $pkgdir/opt/enigma/LinuxExtra/usr $pkgdir/usr
38 rm -rf $pkgdir/opt/enigma/LinuxExtra
40 # ecj . -source 1.6 -classpath /usr/share/java/jna/jna.jar:/usr/share/java/lateralgm/lateralgm.jar:/usr/share/java/svnkit/svnkit.jar && echo
42 chmod -R 755 $pkgdir/opt $pkgdir/usr
43 chmod -R 777 $pkgdir/opt/enigma
44 find $pkgdir/usr -type f -exec chmod 644 {} \;
45 rm $pkgdir/opt/enigma/lgm*.jar
50 if [[ "$PKGARCH" == "i386" || "$PKGARCH" == "i486" || "$PKGARCH" == "i586" || "$PKGARCH" == "i686" ]]; then
51 compileflags='-m32 -mtune=generic'
52 elif [[ "$PKGARCH" == "amd64" || "$PKGARCH" == "x86_64" ]]; then
53 compileflags='-m64 -mtune=generic'
56 make MISCFLAGS="$compileflags" -C CompilerSource
60 for make_GMODE in {Run,Debug,Build,Release}; do
61 for make_dir in {Audio_Systems/*,Graphics_Systems/*}; do
62 if [[ -d "$make_dir" && -f "$make_dir/Config/xlib.ey" ]]; then
63 make $make_GMODE MODE="$make_GMODE" MISCFLAGS="$compileflags" -C ENIGMAsystem/SHELL/$make_dir
66 for make_dir in {Collision_Systems/*,Universal_System,Platforms/xlib}; do
67 if [[ -f "$make_dir/Makefile" ]]; then
68 make $make_GMODE MODE="$make_GMODE" MISCFLAGS="$compileflags" -C ENIGMAsystem/SHELL/$make_dir
76 rm -rf $pkgdir/opt/enigma/{Autoconf,CompilerSource,pluginsource,MacOS}
77 find $pkgdir -name "*.svn" -exec rm -rf {} \; 2> /dev/null || true