1 # Maintainer: Martin Erik Werner ("arand") <martinerikwerner@mail.com>
6 pkgdesc="A single-player and multi-player first-person ego-shooter, built as a total conversion of Cube Engine 2, "
8 url="http://redeclipse.net"
9 license=('custom' 'ZLIB' 'MIT' 'CC-BY-SA')
10 depends=('hicolor-icon-theme' 'sdl_image' 'libgl' 'sdl_mixer')
11 makedepends=('subversion' 'imagemagick' 'gzip' 'mesa')
13 _svntrunk=https://redeclipse.svn.sourceforge.net/svnroot/redeclipse
20 if [ -d "$_svnmod"/.svn ]; then
21 msg "Updating existing SVN checkout"
22 (cd "$_svnmod" && svn up -r "$pkgver")
24 msg "New checkout from SVN"
25 svn co "$_svntrunk" --config-dir ./ -r "$pkgver" "$_svnmod"
28 msg "SVN export to clean build directory"
30 rm -rf "$srcdir/$pkgname"
31 svn export "$srcdir/$_svnmod" "$srcdir/$pkgname"
35 # build in exported directory
36 cd "$srcdir/$pkgname/src"
42 make -C src DESTDIR="$pkgdir" prefix=/usr redeclipse=redeclipse-svn \
45 msg "Adapting scripts, manpages and desktop file"
47 sed -e 's#\(RE_OPTIONS=".*\)-r\(.*"\)#\1-h$HOME/.redeclipse-svn/\2#' \
48 -i "$pkgdir/usr/bin/redeclipse-svn" \
49 -i "$pkgdir/usr/bin/redeclipse-svn-server"
51 zcat "$pkgdir/usr/share/man/man6/redeclipse-svn.6.gz" | \
52 sed -e 's#REDECLIPSE#REDECLIPSE-SVN#' | \
54 > "$pkgdir/usr/share/man/man6/redeclipse-svn.6.gz.tmp" && \
55 mv "$pkgdir/usr/share/man/man6/redeclipse-svn.6.gz.tmp" \
56 "$pkgdir/usr/share/man/man6/redeclipse-svn.6.gz"
58 sed -e 's#\(^Name.*$\)#\1\ SVN#' \
59 -i "$pkgdir/usr/share/applications/redeclipse-svn.desktop"
61 msg "Installing license and trademark info"
62 install -Dm644 license.txt "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
63 install -Dm644 trademark.txt "$pkgdir/usr/share/licenses/$pkgname/TRADEMARK"