summaryrefslogtreecommitdiffstats
path: root/main/libxml2
diff options
context:
space:
mode:
authorTimo Teräs <timo.teras@iki.fi>2013-09-27 14:13:22 +0000
committerTimo Teräs <timo.teras@iki.fi>2013-09-27 14:22:25 +0000
commit488443722c56299f15c69a64e1e8554e0bc55535 (patch)
tree8a15af93cc35da7a128aef609b1934bf25a38440 /main/libxml2
parenta433482bbea7dcceaf8cbe9ddcad1db8c9b254ff (diff)
downloadaports-488443722c56299f15c69a64e1e8554e0bc55535.tar.bz2
aports-488443722c56299f15c69a64e1e8554e0bc55535.tar.xz
main/libxml2: fix build against musl
they have horrible hack to make pthread symbols weak, it's unneeded. patch from sabotage.
Diffstat (limited to 'main/libxml2')
-rw-r--r--main/libxml2/APKBUILD13
-rw-r--r--main/libxml2/libxml2-pthread.patch53
2 files changed, 62 insertions, 4 deletions
diff --git a/main/libxml2/APKBUILD b/main/libxml2/APKBUILD
index 5500426a1..1fb7ad948 100644
--- a/main/libxml2/APKBUILD
+++ b/main/libxml2/APKBUILD
@@ -2,7 +2,7 @@
# Maintainer: Carlo Landmeter <clandmeter@gmail.com>
pkgname=libxml2
pkgver=2.9.1
-pkgrel=0
+pkgrel=1
pkgdesc="XML parsing library, version 2"
url="http://www.xmlsoft.org/"
arch="all"
@@ -12,6 +12,7 @@ depends_dev="zlib-dev python-dev"
makedepends="zlib-dev python-dev"
subpackages="$pkgname-doc $pkgname-dev py-$pkgname:py $pkgname-utils"
source="ftp://ftp.xmlsoft.org/${pkgname}/${pkgname}-${pkgver}.tar.gz
+ libxml2-pthread.patch
"
options="!strip"
@@ -19,6 +20,7 @@ options="!strip"
_builddir="$srcdir/$pkgname-$pkgver"
prepare() {
cd "$_builddir"
+ update_config_sub || return 1
for i in $source; do
case $i in
*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
@@ -63,6 +65,9 @@ utils() {
mv "$pkgdir"/usr/bin "$subpkgdir"/usr/
}
-md5sums="9c0cfef285d5c4a5c80d00904ddab380 libxml2-2.9.1.tar.gz"
-sha256sums="fd3c64cb66f2c4ea27e934d275904d92cec494a8e8405613780cbc8a71680fdb libxml2-2.9.1.tar.gz"
-sha512sums="7b10de749485bc2eb2108063e97d89e70d6fbb78b1bf195ab5528c8c64e79483d55223a49d95934f4e00b00e906c18bdd34344703ffe158dcf08096905a44c1b libxml2-2.9.1.tar.gz"
+md5sums="9c0cfef285d5c4a5c80d00904ddab380 libxml2-2.9.1.tar.gz
+f5fe0da88617b8d87977640a009b8ea9 libxml2-pthread.patch"
+sha256sums="fd3c64cb66f2c4ea27e934d275904d92cec494a8e8405613780cbc8a71680fdb libxml2-2.9.1.tar.gz
+59e0013398c959df25cf7406e43ad15cccc9bdcfefb6875260bf0daf67c76543 libxml2-pthread.patch"
+sha512sums="7b10de749485bc2eb2108063e97d89e70d6fbb78b1bf195ab5528c8c64e79483d55223a49d95934f4e00b00e906c18bdd34344703ffe158dcf08096905a44c1b libxml2-2.9.1.tar.gz
+1a1c747bfd5f8692ef5df2510dea5572aaf153b597463da0dfd817e53a5cd5c8ebb7e9be88ab787194ccedbf4f2739ada45acf655d38fb40a384004e91062322 libxml2-pthread.patch"
diff --git a/main/libxml2/libxml2-pthread.patch b/main/libxml2/libxml2-pthread.patch
new file mode 100644
index 000000000..d6e6f466a
--- /dev/null
+++ b/main/libxml2/libxml2-pthread.patch
@@ -0,0 +1,53 @@
+--- libxml2-2.9.1.patched/threads.c 2013-07-24 03:30:55.160000003 +0000
++++ libxml2-2.9.1/threads.c 2013-07-24 03:33:50.323000003 +0000
+@@ -47,49 +47,7 @@
+ #ifdef HAVE_PTHREAD_H
+
+ static int libxml_is_threaded = -1;
+-#ifdef __GNUC__
+-#ifdef linux
+-#if (__GNUC__ == 3 && __GNUC_MINOR__ >= 3) || (__GNUC__ > 3)
+-extern int pthread_once (pthread_once_t *__once_control,
+- void (*__init_routine) (void))
+- __attribute((weak));
+-extern void *pthread_getspecific (pthread_key_t __key)
+- __attribute((weak));
+-extern int pthread_setspecific (pthread_key_t __key,
+- __const void *__pointer)
+- __attribute((weak));
+-extern int pthread_key_create (pthread_key_t *__key,
+- void (*__destr_function) (void *))
+- __attribute((weak));
+-extern int pthread_key_delete (pthread_key_t __key)
+- __attribute((weak));
+-extern int pthread_mutex_init ()
+- __attribute((weak));
+-extern int pthread_mutex_destroy ()
+- __attribute((weak));
+-extern int pthread_mutex_lock ()
+- __attribute((weak));
+-extern int pthread_mutex_unlock ()
+- __attribute((weak));
+-extern int pthread_cond_init ()
+- __attribute((weak));
+-extern int pthread_cond_destroy ()
+- __attribute((weak));
+-extern int pthread_cond_wait ()
+- __attribute((weak));
+-extern int pthread_equal ()
+- __attribute((weak));
+-extern pthread_t pthread_self ()
+- __attribute((weak));
+-extern int pthread_key_create ()
+- __attribute((weak));
+-extern int pthread_key_delete ()
+- __attribute((weak));
+-extern int pthread_cond_signal ()
+- __attribute((weak));
+-#endif
+-#endif /* linux */
+-#endif /* __GNUC__ */
++
+ #endif /* HAVE_PTHREAD_H */
+
+ /*