updated on Sat Jan 21 20:03:50 UTC 2012
[aur-mirror.git] / ldc-bin / PKGBUILD
blobf3a9be3b8493d262be1c9c09e6257e9255e320fb
1 # $Id: pkgbuild-mode.el,v 1.23 2007/10/20 16:02:14 juergen Exp $
2 # Submitter: Sebastien Binet <binet@farnsworth>
3 # Maintainer: Joshua Taylor "deficite" <taylor.joshua88@gmail.com>
4 pkgname=ldc-bin  
5 pkgver=0.9.2
6 pkgrel=3
7 pkgdesc="A D Compiler based on the LLVM Compiler Infrastructure including D runtime and tango library and imports"
8 url="http://www.dsource.org/projects/ldc"
9 arch=('i686' 'x86_64')
10 license=('BSD')
11 depends=('llvm' 'gcc-libs')
12 conflicts=('ldc')
13 replaces=('ldc')
14 provides=('ldc')
15 if [[ $CARCH == "i686" ]]; then
16   source=(http://www.incasoftware.de/~kamm/ldc/ldc-$pkgver-linux-x86_32.tar.bz2)
17   md5sums=('88f919e5548dffe64270cbdb89048334')
18 elif [[ $CARCH == "x86_64" ]]; then
19   source=(http://www.incasoftware.de/~kamm/ldc/ldc-$pkgver-x86_64.tbz2)
20   md5sums=('87a68a215e2553c432468ffb9f6bc8c3')
23 build() {
25   if [[ $CARCH == "i686" ]]; then
26     pkgver_arch=linux-x86_32
27   elif [[ $CARCH == "x86_64" ]]; then
28     pkgver_arch=x86_64
29   fi
31   cd $startdir/src/ldc-$pkgver-$pkgver_arch
32   _srcdir=$startdir/src/ldc-$pkgver-$pkgver_arch
34   # install ldc binary
35   install -d -m755 $startdir/pkg/usr/bin
36   install -m755 $_srcdir/bin/ldc $startdir/pkg/usr/bin
37   install -m755 $_srcdir/bin/ldmd $startdir/pkg/usr/bin
39   # install ldc.conf
40   install -d -m755 $startdir/pkg/etc
41   install -m755 $_srcdir/bin/ldc.conf $startdir/pkg/etc
43   # install ldc libraries
44   install -d -m755 $startdir/pkg/usr/lib
45   install -m755 $_srcdir/lib/* $startdir/pkg/usr/lib
46   
47   # install ldc imports
48   install -d -m755 $startdir/pkg/usr/include/d
49   /bin/cp -r $_srcdir/import/{tango,object.di} $startdir/pkg/usr/include/d/.
50   chmod -R 0755 $startdir/pkg/usr/include
52   # install license
53   install -d -m755 $startdir/pkg/usr/share/licenses/ldc-bin
54   install -m755 $_srcdir/LICENSE_LDC $startdir/pkg/usr/share/licenses/ldc-bin