Guest User

0ad-ppa-wfg

a guest
Feb 15th, 2011
196
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.96 KB | None | 0 0
  1. # Maintainer: scrawl <[email protected]>
  2. # Contributor: docci
  3.  
  4. pkgname=0ad-ppa-wfg
  5. pkgver=alpha_3_r8832
  6. pkgrel=2
  7. pkgdesc="0ad build from the wildfire games PPA at launchpad.net"
  8. arch=('i686' 'x86_64')
  9. url="http://www.wildfiregames.com/0ad"
  10. license=('GPL2' 'CCPL')
  11. depends=('libpng12' 'binutils' 'boost' 'crypto++' 'devil' 'enet-old' 'fam' 'libogg' 'libvorbis' 'libxml2' 'mesa' 'nasm' 'openal' 'sdl' 'wxgtk' 'zip' 'zlib')
  12. makedepends=('p7zip' 'deb2targz')
  13.  
  14. _arch=$CARCH
  15. [ $CARCH == i686 ] && _arch="i386"
  16. [ $CARCH == x86_64 ] && _arch="amd64"
  17. source=( https://launchpad.net/~wfg/+archive/0ad/+files/0ad_0.0.0%2Br08832-1~10.10~wfg1_$_arch.deb https://launchpad.net/~wfg/+archive/0ad/+files/0ad-data_0.0.0%2Br08832-1~10.10~wfg1_all.deb http://trac.wildfiregames.com/attachment/ticket/492/0ad.packaging.tar.gz?format=raw 0ad.sh http://ubuntu.mirror.cambrium.nl/ubuntu//pool/universe/b/boost1.40/libboost-filesystem1.40.0_1.40.0-6ubuntu1_$_arch.deb http://ubuntu.mirror.cambrium.nl/ubuntu//pool/universe/b/boost1.40/libboost-system1.40.0_1.40.0-6ubuntu1_$_arch.deb)
  18. md5sums=( 36f8e02ae3daf81114eb207dd789c41a fe27ed6aff7752ca76fc88fd199f683a b6c74d2ee0fa4b54b7e617c25794ca3e 9677c33dddf6e20c16f042ae0621082c d685a2421f7e070df57c6b1624a25455 4c34d6a96877b6d79d4cb6d99d805826 )
  19. [ $CARCH == i686 ] && md5sums=( 38b0897f4f6514c9fc2cd10d77205629 fe27ed6aff7752ca76fc88fd199f683a b6c74d2ee0fa4b54b7e617c25794ca3e 9677c33dddf6e20c16f042ae0621082c c516c0edfd025a0925baf2ae6b44790e eb948da264a58a7d6282cce37f9d67ff )
  20.  
  21. conflicts=('0ad' '0ad-svn')
  22.  
  23. build() {
  24. # Unpack packaging data (.desktop file, icon...)
  25. tar xvf 0ad.packaging.tar.gz\?format\=raw
  26.  
  27. # Unpack and install debs
  28. 7z e 0ad_0.0.0%2Br08832-1~10.10~wfg1_amd64.deb -so |tar -x
  29. 7z e 0ad-data_0.0.0%2Br08832-1~10.10~wfg1_all.deb -so |tar -x
  30. mv usr $pkgdir/
  31.  
  32. # Unpack and install libfix
  33. deb2targz libboost-filesystem1.40.0_1.40.0-6ubuntu1_amd64.deb
  34. tar -xzf libboost-filesystem1.40.0_1.40.0-6ubuntu1_amd64.tar.gz
  35. deb2targz libboost-system1.40.0_1.40.0-6ubuntu1_amd64.deb
  36. tar -xzf libboost-system1.40.0_1.40.0-6ubuntu1_amd64.tar.gz
  37. mv usr/lib/ $pkgdir/usr/lib/games/0ad/libfix/
  38.  
  39. # Install run script
  40. mkdir -p $pkgdir/usr/lib/games/0ad/system
  41. cp 0ad.sh $pkgdir/usr/lib/games/0ad/system/pyrogenesis
  42. mkdir $pkgdir/usr/bin
  43. cp 0ad.sh $pkgdir/usr/bin/0ad
  44. chmod +x $pkgdir/usr/lib/games/0ad/system/pyrogenesis
  45.  
  46. # Fix LD errors caused by Ubuntu shipping different library versions
  47. cd $pkgdir/usr/lib/games/0ad/libfix
  48. ln -s /usr/lib/libjpeg.so ./libjpeg.so.62
  49. ln -s /usr/lib/libtiff.so ./libtiff.so.4
  50. ln -s /usr/lib/libenet.so ./libenet.so.0debian1
  51. ln -s ./libboost_filesystem.so.1.40.0 ./libboost_filesystem.so.1.42.0
  52. ln -s ./libboost_system.so.1.40.0 ./libboost_system.so.1.42.0
  53.  
  54. # Install .desktop file
  55. cd $srcdir/0ad.packaging
  56. install -D -m 0644 "0ad.desktop" "$pkgdir/usr/share/applications/0ad.desktop"
  57. install -D -m 0644 "0ad.png" "$pkgdir/usr/share/pixmaps/0ad.png"
  58.  
  59. }
Advertisement
Add Comment
Please, Sign In to add comment