summaryrefslogtreecommitdiff
path: root/community/rawtherapee/PKGBUILD
blob: 1de4c8f15137a6031eb04ffe81195c77272b5c72 (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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
# $Id: PKGBUILD 48519 2011-06-01 11:08:54Z stativ $
# Maintainer: Lukas Jirkovsky <l.jirkovsky AT gmail.com>
# Contributor: Bogdan Szczurek <thebodzio(at)gmail.com>
# Contributor: Vaclav Kramar <vaclav.kramar@tiscali.cz>
# Contributor: Archie <mymaud@gmail.com>

pkgname=rawtherapee
pkgver=3.1m5
pkgrel=1
pkgdesc="RAW photo editor"
arch=('i686' 'x86_64')
url="http://www.rawtherapee.com/"
license=('GPL')
depends=('bzip2' 'libsigc++' 'gtkmm' 'libiptcdata' 'lcms2' 'desktop-file-utils')
makedepends=('mercurial' 'cmake')
install=rawtherapee.install
source=(rawtherapee.desktop rawtherapee.png)
md5sums=('83f14b57b27f066705b0aec7ad56c53d'
         '4e54e74684971a2f04d9396b9051570e')

_root="https://rawtherapee.googlecode.com/hg/"
_repo="rawtherapee"
#_branch="branch_3.0"
#_changeset="71045bfba97e" # changeset $pkgver

build() {
  cd "$srcdir"
  msg "Connecting to Mercurial server...."

  if [ -d $_repo ] ; then
    cd $_repo
    hg pull
    hg up "Dev-$pkgver"
    msg "The local files are updated."
  else
    hg clone -u "Dev-$pkgver" $_root $_repo
  fi

  msg "Mercurial checkout done or server timeout"
  msg "Starting make..."

  if [ -e "$srcdir/$_repo-build" ]; then
    rm -rf "$srcdir/$_repo-build"
  fi
  mkdir "$srcdir/$_repo-build"
  cd "$srcdir/$_repo-build"

  cmake -DCMAKE_INSTALL_PREFIX=/usr \
    -DCMAKE_BUILD_TYPE=Release \
    -DWITH_MYFILE_MMAP=OFF \
     ../$_repo
  make
}

package() {
  cd "$srcdir/$_repo-build"
  make DESTDIR="$pkgdir/" install

  # remove unneded rtstart script
  # see http://code.google.com/p/rawtherapee/issues/detail?id=184
  rm "$pkgdir"/usr/bin/rtstart

  install -D -m644 "$srcdir"/rawtherapee.desktop "$pkgdir"/usr/share/applications/rawtherapee.desktop
  install -D -m644 "$srcdir"/rawtherapee.png "$pkgdir"/usr/share/pixmaps/rawtherapee.png
}