updated on Thu Jan 19 00:16:31 UTC 2012
[aur-mirror.git] / cenon / PKGBUILD
blob688f7a1bdd6153d5acf732cec7610f9b648b776a
1 # Contributor: Kyle Keen <keenerd@gmail.com>
2 pkgname=cenon
3 pkgver=3.9.3
4 _libver=3.9.2  # why!?
5 pkgrel=1
6 pkgdesc="GNUstep based vector editor for EPS, DXF, Gerber, HPGL.  Includes docs and examples."
7 arch=('i686' 'x86_64')
8 url="http://www.cenon.info"
9 license=('vhfPL')
10 depends=('gnustep-base' 'gnustep-gui')
11 makedepends=('gnustep-make' 'gcc-objc')
12 source=(http://www.vhf-group.com/vhf-interservice/download/source/Cenon-$pkgver.tar.bz2\
13   http://www.vhf-group.com/vhf-interservice/download/source/CenonLibrary-$_libver-1.tar.bz2\
14   http://www.vhf-group.com/vhf-interservice/download/doc/Cenon_gb.pdf)
15 md5sums=('c778a6d241b88379b13113ddc69d51ad'
16          'e216468bf28c84287bbd65cd2f9bee66'
17          '6680bc8050eb81725b603823a50782a0')
19 build() {
20   # Note to self: worst pkgbuild yet
21   cd $srcdir/Cenon
23   PATH="$PATH:/opt/GNUstep/System/Tools:/opt/GNUstep/Local/Tools"
24   LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/opt/GNUstep/Local/Library/Libraries"
25   
26   make GNUSTEP_MAKEFILES="/opt/GNUstep/System/Library/Makefiles/"
28   install -d "$pkgdir/opt/GNUstep/Local/Library/"
29   install -d "$pkgdir/opt/GNUstep/Local/Applications/"
30   sed -i "s/cp -R/#cp -R/" GNUmakefile.postamble
31   sed -i "s/chmod -R/#chmod -R/" GNUmakefile.postamble
33   make DESTDIR="$pkgdir" \
34        GNUSTEP_MAKEFILES="/opt/GNUstep/System/Library/Makefiles/" \
35        GNUSTEP_LOCAL_LIBRARY="/opt/GNUstep/Local/Library/" \
36        GNUSTEP_LOCAL_APPS="/opt/GNUstep/Local/Applications/" \
37        install
39   cp -R Library/Cenon/ $pkgdir/opt/GNUstep/Local/Applications/
40   chmod -R ugo+rX $pkgdir/opt/GNUstep/Local/Applications/Cenon.*
42   # yeah, yeah.  use install
43   cp -R Devices/ "$pkgdir/opt/GNUstep/Local/Library/Cenon/"
44   cp -R Documentation/ "$pkgdir/opt/GNUstep/Local/Library/Cenon/"
45   cp -R Examples/ "$pkgdir/opt/GNUstep/Local/Library/Cenon/"
46   cp -R Projects/ "$pkgdir/opt/GNUstep/Local/Library/Cenon/"
47   cp ../../Cenon_gb.pdf "$pkgdir/opt/GNUstep/Local/Library/Cenon/Documentation/"
49   # figure out how to fix the library path for real
50   install -d "$pkgdir/usr/bin/"
51   touch "$pkgdir/usr/bin/cenon"
52   chmod +x "$pkgdir/usr/bin/cenon"
53   echo "#!/bin/sh" >> $pkgdir/usr/bin/cenon
54   echo "export LD_LIBRARY_PATH=\"/opt/GNUstep/Local/Library/Libraries\"" >> $pkgdir/usr/bin/cenon
55   echo "/opt/GNUstep/Local/Applications/Cenon.app/Cenon" >> $pkgdir/usr/bin/cenon