1 # Contributor: Martin Ellis <ellism88@gmail.com>
2 # Contributor: Tom Vincent <http://tlvince.com/contact/>
5 pkgname=bin32-$_pkgname32
8 pkgdesc="Kent Retargetable occam Compiler. An occam-pi compiler."
10 url="http://projects.cs.kent.ac.uk/projects/kroc/trac/wiki"
13 depends=('lib32-libv4l' 'bash' 'binutils' 'gawk' 'pkgconfig' 'lib32-libpng' 'lib32-libxmu' 'lib32-libxi' 'perl' 'python2' 'lib32-libxslt')
14 makedepends=('subversion')
15 optdepends=('sdl' 'sdl_sound' 'mesa')
16 provides=("kroc" "kroc-setup.sh" "occ21")
17 conflicts=($_pkgname32)
18 md5sums=(eb6839a64ac4a5303d333276eaf48ce0)
21 _svntrunk="http://projects.cs.kent.ac.uk/projects/kroc/svn/kroc/trunk/"
29 msg "Connecting to SVN server...."
31 if [[ -d "$_svnmod/.svn" ]]; then
32 (cd "$_svnmod" && svn up -r "$pkgver")
34 svn co "$_svntrunk" --config-dir ./ -r "$pkgver" "$_svnmod"
37 msg "SVN checkout done or server timeout"
38 msg "Starting build..."
40 rm -rf "$srcdir/$_svnmod-build"
41 cp -r "$srcdir/$_svnmod" "$srcdir/$_svnmod-build"
42 cd "$srcdir/$_svnmod-build"
44 export PYTHON="python2"
45 for file in $(find . -name '*.py' -print); do
47 sed -i 's_^#!.*/usr/bin/python_#!/usr/bin/python2_' $file
48 sed -i 's_^#!.*/usr/bin/env.*python_#!/usr/bin/env python2_' $file
51 sed -i 's_^#!.*/usr/bin/python_#!/usr/bin/python2_' tools/kroc/occbuild.in
52 sed -i 's_^#!.*/usr/bin/env.*python_#!/usr/bin/env python2_' tools/kroc/occbuild.in
54 sed -i 's_^#!.*/usr/bin/python_#!/usr/bin/python2_' tools/occamdoc/occamdoc.in
55 sed -i 's_^#!.*/usr/bin/env.*python_#!/usr/bin/env python2_' tools/occamdoc/occamdoc.in
57 sed -i 's_python__' runtime/ccsp/include/Makefile.am
59 patch -p0 -i ../arch.diff
62 ./configure --prefix=/usr --libdir=/user/lib32
68 cd "$srcdir/$_svnmod-build"
69 make DESTDIR="$pkgdir/" install
72 # vim:set ts=2 sw=2 et: