summaryrefslogtreecommitdiff
path: root/multilib/lib32-libxml2/PKGBUILD
blob: 48fe4649d045599e23e46dc6291256d23ee0ab22 (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
# $Id: PKGBUILD 64012 2012-02-08 18:56:17Z pschmitz $
# Maintainer: Jan de Groot <jgc@archlinux.org>
# Contributor: John Proctor <jproctor@prium.net>

_pkgbasename=libxml2
pkgname=lib32-$_pkgbasename
pkgver=2.7.8
pkgrel=2
pkgdesc="XML parsing library, version 2 (32-bit)"
arch=(x86_64)
license=('custom')
depends=('lib32-zlib>=1.2.4' 'lib32-readline>=6.1' 'lib32-ncurses>=5.7' $_pkgbasename)
makedepends=(gcc-multilib)
options=('!libtool')
url="http://www.xmlsoft.org/"
source=(ftp://ftp.xmlsoft.org/${_pkgbasename}/${_pkgbasename}-${pkgver}.tar.gz
        shared_library_versionning.patch)
md5sums=('8127a65e8c3b08856093099b52599c86'
         '84aeb7c6db023eae044e95d9211dba53')

build() {
  export CC="gcc -m32"
  export CXX="g++ -m32"
  export PKG_CONFIG_PATH="/usr/lib32/pkgconfig"

  cd "${srcdir}/${_pkgbasename}-${pkgver}"
  patch -Np1 -i "${srcdir}/shared_library_versionning.patch"
  autoreconf -fi
  ./configure --prefix=/usr --with-threads --with-history --libdir=/usr/lib32
  make
}

package() {
  cd "${srcdir}/${_pkgbasename}-${pkgver}"
  make DESTDIR="${pkgdir}" install

  rm -rf "${pkgdir}"/usr/{include,share,bin} "$pkgdir/usr/lib32/xml2Conf.sh"
  mkdir -p "$pkgdir/usr/share/licenses"
  ln -s $_pkgbasename "$pkgdir/usr/share/licenses/$pkgname"
}