summaryrefslogtreecommitdiff
path: root/community/mtasc/PKGBUILD
blob: 2619fbd4193ccdc35a1e595dc4b1c654a437ea15 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# Contributor: Niel Drummond <niel.drummond@grumpytoad.org>

pkgname=mtasc
pkgver=20091229
pkgrel=1
pkgdesc="An open source flash (swf) compiler"
arch=(i686 x86_64)
url="http://mtasc.org/"
license=('GPL2')
depends=('zlib')
makedepends=('ocaml' 'cvs')
source=(http://www.mtasc.org/doc/mtasc/install.ml)
md5sums=('d072094a9c3ec4384ce232d4b65dab40')

build() {
  cd $startdir/src
  sed -i 's/anonymous@/anonymous:@/' $startdir/src/install.ml

  msg "Running ocaml script..."
  cd $startdir/src
  ocaml $startdir/src/install.ml || return 1

  msg "Done compiling..."

  install -D -m755 $startdir/src/bin/${pkgname} $startdir/pkg/usr/bin/${pkgname} || return 1

  for f in $( cd ocaml/mtasc/ && find ./{std,std8} -type f -iname '*.as' | grep -iv cvs ); do
    install -D -m644 ocaml/mtasc/$f ../pkg/usr/share/mtasc/$f || return 1
  done
}