Pastebin is 300% more awesome when you are logged in. Sign Up, it's FREE!
Guest

heekscad-git PKGBUILD

By: a guest on Mar 18th, 2013  |  syntax: None  |  size: 1.66 KB  |  hits: 65  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. # Maintainer: Nick Ƙstergaard <oe dot nick at gmail dot com>
  2. pkgname=heekscad-git
  3. pkgver=20130318
  4. pkgrel=1
  5. pkgdesc="A free CAD program based on Open CASCADE"
  6. arch=('i686' 'x86_64')
  7. url="https://github.com/Heeks/heekscad"
  8. license=('custom:BSD3')
  9. depends=('python2' 'wxgtk' 'gtkglext' 'opencascade' 'hicolor-icon-theme' 'xdg-utils' 'tinyxml')
  10. makedepends=('git' 'cmake' 'python2' 'wxgtk' 'gtkglext' 'opencascade')
  11. provides=('heekscad')
  12. conflicts=('heekscad' 'heekscad-svn')
  13. install=heekscad.install
  14. source=( heekscad_PI.patch )
  15. noextract=()
  16. md5sums=('4d512b3d783489fd593c075662d0ca9e')
  17.  
  18. _gitroot=git://github.com/Heeks/heekscad.git
  19. _gitname=heekscad
  20.  
  21. _gitroot_area=git://github.com/Heeks/libarea.git
  22. _gitname_area=libarea
  23.  
  24. build() {
  25.   cd "$srcdir"
  26.   msg "Connecting to GIT server...."
  27.  
  28.   if [[ -d "$_gitname" ]]; then
  29.     cd "$_gitname" && git pull origin
  30.     cd "$_gitname_area" && git pull origin
  31.     msg "The local files are updated."
  32.   else
  33.     git clone "$_gitroot" "$_gitname"
  34.     cd "$_gitname" && git clone "$_gitroot_area" "$_gitname_area"
  35.   fi
  36.  
  37.   msg "GIT checkout done or server timeout"
  38.   msg "Starting build..."
  39.  
  40.   rm -rf "$srcdir/$_gitname-build"
  41.   cp -R "$srcdir/$_gitname" "$srcdir/$_gitname-build"
  42.   cd "$srcdir/$_gitname-build"
  43.  
  44.   #
  45.   # BUILD HERE
  46.   #
  47.   export CASROOT=/opt/opencascade
  48.   cmake CMAKE_INSTALL_PREFIX=/usr .
  49.  
  50.   # Copy license
  51.   install -Dm644 COPYING "$pkgdir/usr/share/licenses/$pkgname/COPYING"
  52. }
  53.  
  54. package() {
  55.   cd "$srcdir/$_gitname-build"
  56.   make install DESTDIR=$pkgdir
  57.  
  58.   # Remove symlink to be compatible with the community/tinyxml package
  59.   rm $pkgdir/usr/lib/libtinyxml.so
  60. }
  61.  
  62. # vim:set ts=2 sw=2 et: