updated on Fri Jan 20 04:00:45 UTC 2012
[aur-mirror.git] / topmod-svn / PKGBUILD
blob5fda1689adcdf8a1e48a64700e0670bdcc2ea19c
1 # Contributer: N30N <archlinux@alunamation.com>
3 pkgname=topmod-svn
4 pkgver=243
5 pkgrel=1
6 pkgdesc='TopMod is a topological mesh modeling system that allows users to create high genus 2-manifold meshes'
7 url='http://topmod3d.org'
8 license=('GPL')
9 arch=('i686' 'x86_64')
10 depends=('qt>=4.3' 'python')
11 makedepends=('subversion')
12 source=('topmod.sh' 'topmod.desktop' '64bit.patch')
13 md5sums=('c8aef06e02f0f244b6f451a703c97235' 'bffc574730f7dd3df567eb7e690277c5' '0f9a1b63815ee3efbf960617ebf8044f')
15 _svntrunk="http://topmod.googlecode.com/svn/trunk"
16 _svnmod="topmodx"
18 build() {
19         cd ${startdir}/src
21         msg "Connecting to topmod SVN server......."
22         if [ -d ${_svnmod}/.svn ]; then
23                 (cd ${_svnmod} && svn update -r ${pkgver})
24         else
25                 svn co ${_svntrunk}/${_svnmod} --config-dir ./ -r ${pkgver}
26         fi
28         if [ -e ${_svnmod}-build ]; then
29                 rm -rf ${_svnmod}-build
30         fi
31         cp -r ${_svnmod} ${_svnmod}-build
32         cd ${_svnmod}-build
34         if [ ${CARCH} == "x86_64" ]; then
35                 patch -p1 < ../64bit.patch
36         fi
38         # change path to videos
39         sed -i "s/fromLocalFile(\"video/fromLocalFile(\"\/usr\/share\/topmod\/video/" MainWindow.cc
41         # update python version
42         sed -i "s/2\.5/2\.6/g" topmod.pro
44         msg "Starting build process."
45         cd include
46         qmake && make || return 1
48         cd pydlfl || return 1
49         make
50         python dlfl_setup.py install --root=${startdir}/pkg || return 1
52         cd ../../
53         lupdate topmod.pro
54         lrelease topmod.pro
56         # use a transparent image for the missing colour fill icon
57         # cp images/{doosabin_extrude.png,color-fill.png}
59         qmake && make || return 1
61         install -D -m755 TopMod ${startdir}/pkg/usr/share/topmod/TopMod
62         install -D -m644 images/topmod.png ${startdir}/pkg/usr/share/pixmaps/topmod.png
63         install -D -m755 ${startdir}/{src/topmod.sh,pkg/usr/bin/topmod}
64         install -D -m644 ${startdir}/{src/topmod.desktop,pkg/usr/share/applications/topmod.desktop}
65         cp -r video ${startdir}/pkg/usr/share/topmod/video