archrelease: copy trunk to community-any
[ArchLinux/community.git] / pdfmod / trunk / PKGBUILD
blob07305b26113536b2a365437a0e1cfe325426f413
1 # Maintainer: Balló György <ballogyor+arch at gmail dot com>
2 # Contributor: Claudio Riva <firetux83@gmail.com>
4 pkgname=pdfmod
5 pkgver=0.9.1
6 pkgrel=12
7 pkgdesc="Simple application for modifying PDF written in C Sharp"
8 arch=('any')
9 url="https://wiki.gnome.org/Attic/PdfMod"
10 license=('GPL' 'MIT')
11 depends=('gtk-sharp-2' 'poppler-glib')
12 makedepends=('hyena' 'poppler-sharp' 'intltool' 'yelp-tools' 'dos2unix')
13 source=("https://download.gnome.org/sources/$pkgname/${pkgver%.*}/$pkgname-$pkgver.tar.bz2"
14         '0001-pdfmod-mono-2.10.patch'
15         '0002-fix-build.patch'
16         '0003-drop-gconf-dependency.patch'
17         '0004-yelp-tools.patch'
18         'pdfmod.appdata.xml'
19         'LICENSE-PDFsharp')
20 sha256sums=('eb7c987514a053106ddf03f26544766c751c801d87762909b36415d46bc425c9'
21             'fad48fb68fe6a9b60032a43c6c0389092684723a3aab296e926003ff0b33880c'
22             'fcf26040435b88f625d2c3b36540ea6c78e767439a6dee8d2f87119e8d666978'
23             '6a235f93ce7321cbe2e7f20094ece0659fb4648602e84a4824a0fb527be90914'
24             '40407ed97f2e79d5c63a9a6c67ea7c21a58b95095ba5449ff607acd5c829513a'
25             '15a79778dfebed691b0a59a34e9a02bd0377012aa540ecd6ff65a5b2b969d7d5'
26             '5d2b6e1a9e5582f9c5d129f222ff01ca6ce3dfa4a5c1f5c41ba827fe0fbeb4bd')
28 prepare() {
29   cd $pkgname-$pkgver
31   # Some files are distributed in DOS format
32   find . -type f -exec dos2unix -q '{}' \;
34   # https://bugzilla.gnome.org/show_bug.cgi?id=644516
35   patch -Np1 -i ../0001-pdfmod-mono-2.10.patch
37   # Workaround for build error (FS#39501)
38   patch -Np1 -i ../0002-fix-build.patch
40   # Remove deprecated GConf dependency
41   patch -Np1 -i ../0003-drop-gconf-dependency.patch
42   
43   # Don't use deprecated gnome-doc-utils
44   mv docs/C/{pdfmod.xml,index.docbook}
45   patch -Np1 -i ../0004-yelp-tools.patch
47   # Fix build
48   sed -i 's/gmcs/mcs/' configure{,.ac}
49   sed -i 's|pkglib_SCRIPTS|monolibdir = $(pkglibdir)/\nmonolib_DATA|' Makefile.include
51   autoreconf -fi
54 build() {
55   cd $pkgname-$pkgver
56   ./configure \
57      --prefix=/usr \
58      --sysconfdir=/etc \
59      --localstatedir=/var \
60      --disable-scrollkeeper
61   make
64 package() {
65   cd $pkgname-$pkgver
66   make DESTDIR="$pkgdir/" install
67   install -Dm0644 "$srcdir/pdfmod.appdata.xml" "$pkgdir/usr/share/metainfo/pdfmod.appdata.xml"
68   install -Dm0644 "$srcdir/LICENSE-PDFsharp" "$pkgdir/usr/share/licenses/$pkgname/LICENSE-PDFsharp"