summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 6cd69e8af2b2bde9266827095082deff283efea6 (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
# Contributor: Simo Huhtiranta <simo_huhtirantaATpp_inet_fi>  
# Contributor: Tilmann Becker <tilmann.becker@web.de>
# Maintainer: Stefan Husmann <stefan-husmann@t-online.de>

pkgname=scribus-svn
pkgver=23065
pkgrel=1
pkgdesc="A desktop publishing program - Version from SVN"
arch=('i686' 'x86_64')
license=('GPL' 'LGPL')
url="http://www.scribus.net"
depends=('hunspell' 'podofo' 'python2' 'libcups' 'graphicsmagick'
	 'poppler' 'libcdr' 'libvisio' 'libpagemaker' 'harfbuzz-icu'
	 'qt5-declarative' 'libmspub' 'openscenegraph' 'libwmf'
	 'desktop-file-utils')
makedepends=('subversion' 'cmake' 'qt5-tools')
optdepends=('lib2geom: for mesh distortion')
conflicts=('scribus')
provides=('scribus')
source=('scribus::svn://scribus.net/trunk' python2.patch)
sha256sums=('SKIP'
            '1801f9b1fbabeee33112c48e706706072e1e60b1160b1723c9bb80df0b4e2c66')
_svnmod='scribus'

pkgver() {
  cd ${_svnmod}
  local ver="$(svnversion)"
  printf "%s" "${ver//[[:alpha:]]}"
}

prepare() {
  cd $_svnmod/Scribus
  patch -Np1 < "$srcdir"/python2.patch || true
}

build() {
  cd $_svnmod/Scribus
  cmake . -DCMAKE_INSTALL_PREFIX:PATH=/usr \
	-DCMAKE_SKIP_RPATH:BOOL=YES \
	-DWANT_GRAPHICSMAGICK:BOOL=YES \
	-DCMAKE_LIBRARY_PATH:PATH=/usr/lib \
	-DCMAKE_INCLUDE_PATH:PATH=/usr/include/python2.7 \
	-DCMAKE_EXE_LINKER_FLAGS:STRING="-lQt5Quick -lQt5PrintSupport" \
	-DQT_PREFIX:PATH="/usr" -DWANT_SVNVERSION:BOOL=YES
  make
}

package () {
  cd "$srcdir"/$_svnmod/Scribus
  make DESTDIR="$pkgdir" install
  install -Dm644 COPYING "$pkgdir"/usr/share/licenses/$pkgname/COPYING
  install -Dm644 scribus.desktop $pkgdir/usr/share/applications/scribus.desktop
  install -d "${pkgdir}"/usr/share/pixmaps
  ln -s /usr/share/scribus/icons/1_5_0/scribus.png "${pkgdir}"/usr/share/pixmaps/scribus.png
  # move around some picture files
  for _i in AppIcon.png AllCaps.png Kapital.xpm Strike.xpm \
		       outlined.png shadow.png shade.png Revers.png zeichen.png
  do install "$pkgdir"/usr/share/scribus/icons/1_5_0/$_i "$pkgdir"/usr/share/scribus/icons/1_5_1/$_i
     rm "$pkgdir"/usr/share/scribus/icons/1_5_0/$_i
  done
}