1 # Maintainer: Alexander F Rødseth <xyproto@archlinux.org>
2 # Contributor: Bartłomiej Piotrowski <barthalion@gmail.com>
3 # Contributor: Larry Hajali <larryhaja[at]gmail[dot]com>
4 # Contributor: Hubert Grzeskowiak <arch at nemesis13 dot de>
9 pkgdesc='Simple, small XML parser'
10 url='http://grinninglizard.com/tinyxml/'
14 source=("https://downloads.sourceforge.net/$pkgname/${pkgname}_${pkgver//./_}.tar.gz"
16 $pkgname-2.5.3-stl.patch
18 b2sums=('84d4ad0174eb38583a4488523410105928b9797f09a2ef84b41156580a40cc11d1d09e28e67512494bd02d7a7e0b208aa6c1ce3383bec12de606491214c16a77'
19 'e8430b2fea965f351c12a0413c3bba43ce19da7e8a0973fae3c7db4b4a8978cbc8b74beb495dd9141e79e90f9ad012b6b5e738207f8075ad7001cb85b424f5be'
20 'e9a3d63283f7946e04dafa58a7eeda782b02d6d6093bae18fdec727b9e6c6722a4c610230cc43ea8142695f3a0aaa1e9bf11a8f0072ad580acb5428655a3d6e8'
21 '8d7658c143ccc3ebe226f3dfdf96ec96de94bca4168e77c560ec4bea41c5d78245c4a3cdf1f4126361f9214176bfb362a6c8377404ccf2a4c999c3f0d491930c')
27 patch -p0 -i "$srcdir/entity.patch"
29 # Make TINYXML_USE_STL permanently defined in tinyxml.h
30 patch -p1 -i "$srcdir/$pkgname-2.5.3-stl.patch"
33 setconf Makefile TINYXML_USE_STL YES
34 setconf Makefile RELEASE_CFLAGS "$CXXFLAGS -fPIC"
41 g++ -fPIC $CXXFLAGS $LDFLAGS -shared -o "lib$pkgname.so.0.$pkgver" \
42 -Wl,-soname,"lib$pkgname.so.0" $(ls *.o | grep -v xmltest)
48 install -d -m 0755 "$pkgdir"/usr/{lib,include}
49 install -m 0755 "lib$pkgname.so.0.$pkgver" "$pkgdir"/usr/lib/
50 install -m 0644 $pkgname.h tinystr.h "$pkgdir"/usr/include
51 install -Dm644 readme.txt "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
52 install -Dm644 "$srcdir/$pkgname.pc" "$pkgdir/usr/lib/pkgconfig/$pkgname.pc"
55 ln -s "lib${pkgname}.so.0.$pkgver" lib$pkgname.so.0
56 ln -s "lib${pkgname}.so.0.$pkgver" lib$pkgname.so