updated on Mon Jan 16 00:01:41 UTC 2012
[aur-mirror.git] / seismicunix / PKGBUILD
blob5d4c2e1420e21ca32d87054387075ab2dc7f2e24
1 # Maintainer:  Elder Marco <eldermarco at gmail dot com>
3 pkgname=seismicunix
4 _pkgname=cwp_su_all
5 pkgver=43.1
6 _pkgver=43R1
7 pkgrel=1
8 pkgdesc="Open source software for seismic research and seismic processing"
10 license=('BSD')
11 url="http://www.cwp.mines.edu/cwpcodes/"
12 source=("ftp://ftp.cwp.mines.edu/pub/cwpcodes/${_pkgname}_${_pkgver}.tgz"
13         "$pkgname-$pkgver-makefile-config.patch"
14         "$pkgname-$pkgver-no-questions.patch"
15         "$pkgname.sh"
16         "$pkgname.csh")
18 makedepends=('libxmu' 'libxi' 'mesa' 'freeglut' 'lesstif' 'gcc-fortran')
19 depends=('libxmu' 'libxi' 'mesa' 'freeglut' 'lesstif')
21 arch=('i686' 'x86_64')
22 md5sums=('ce03c359022e91eff8c5fbc1e3a89c38'
23          '45a6c3a541946ea9035325583d802abf'
24          '82176ba5202a957b04bc94562c28bada'
25          '9b1f8dd11bc33f4b52c5db9870817d54'
26          '2984eab8f0481f9d9c510d1ce6c48519')
28 build () {
29     cd "$srcdir/src"
30     patch -Np1 -i ../$pkgname-$pkgver-makefile-config.patch
31     patch -Np1 -i ../$pkgname-$pkgver-no-questions.patch
32     export CWPROOT="$srcdir"
34     # Basic set of codes
35     make install
37     # X-toolkit applications
38     make xtinstall
40     # Motif application
41     make xminstall
43     # Fortran codes
44     make finstall
46     # Mesa/OpenGL items
47     make mglinstall
49     # libcwputils
50     make utils
53 package () {
54     cd "$srcdir"
56     # Binary files
57     mkdir -p "$pkgdir/opt/$pkgname/bin"
58     cp -pr bin/* "$pkgdir/opt/$pkgname/bin/"
60     # Include Headers
61     mkdir -p "$pkgdir/opt/$pkgname/include"
62     cp -pr include/* "$pkgdir/opt/$pkgname/include/"
64     # Libraries
65     mkdir -p "$pkgdir/opt/$pkgname/lib/"
66     cp -pr lib/* "$pkgdir/opt/$pkgname/lib/"
68     # Source Code and others
69     mkdir -p "$pkgdir/opt/$pkgname/src"
70     for _dir in doc cwp par psplot xplot Xtcwp 3D \
71                 Xmcwp su tri tetra faq comp xtri; do
72         cp -pr "src/$_dir" "$pkgdir/opt/$pkgname/src"
73     done
75     # Environment Variables
76     install -d -m0755 "$pkgdir/etc/profile.d"
77     install -m0755 "${pkgname}.sh" "$pkgdir/etc/profile.d/"
78     install -m0755 "${pkgname}.csh" "$pkgdir/etc/profile.d/"
80     # License file and acknowledgments
81     install -d -m0755 "$pkgdir/usr/share/licenses/$pkgname"
82     install -p -m0644 src/LEGAL_STATEMENT  \
83         "$pkgdir/usr/share/licenses/$pkgname/COPYING"
84     install -p -m0644 src/ACKNOWLEDGEMENTS \
85         "$pkgdir/usr/share/licenses/$pkgname/"
87 # expandtab:tabstop=4:shiftwidth=4