summaryrefslogtreecommitdiffstats
path: root/abs/core/libxslt/PKGBUILD
blob: 3f8af1b2e2003a31f86eb146ece49c6a5163a02c (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
# $Id$
# Maintainer: Eric Belanger <eric@archlinux.org>
# Contributor: John Proctor <jproctor@prium.net>

pkgname=libxslt
pkgver=1.1.32+3+g32c8821
pkgrel=1
pkgdesc="XML stylesheet transformation library"
url="http://xmlsoft.org/XSLT/"
arch=(x86_64)
license=(custom)
depends=(libxml2 libgcrypt)
makedepends=(python2 git)
checkdepends=(docbook-xml python)
_commit=32c88216ddbaa0f3491f45bc84ee89285c6a1129  # master
source=("git+https://git.gnome.org/browse/libxslt#commit=$_commit")
sha256sums=('SKIP')

pkgver() {
  cd $pkgname
  git describe --tags | sed 's/^v//;s/-/+/g'
}

prepare() {
  cd $pkgname

  sed -e 's|/usr/bin/python -u|/usr/bin/python2 -u|g' \
      -e 's|/usr/bin/python$|/usr/bin/python2|g' \
      -i python/tests/*.py

  NOCONFIGURE=1 ./autogen.sh
}

build() {
  cd $pkgname
  ./configure --prefix=/usr --with-python=/usr/bin/python2
  sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
  make
}

check() {
  cd $pkgname
  make check
}

package() {
  cd $pkgname
  make DESTDIR="$pkgdir" install
  install -Dm644 COPYING "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
  find "$pkgdir" -name '*.a' -print -delete
}