summaryrefslogtreecommitdiffstats
path: root/main/py-libvirt/musl-gnuc-prereq.patch
diff options
context:
space:
mode:
authorTimo Teräs <timo.teras@iki.fi>2013-12-18 15:43:00 +0000
committerTimo Teräs <timo.teras@iki.fi>2013-12-18 15:43:15 +0000
commit371e29c29e5f4f0002d0d692886a73be7a4d7dfa (patch)
tree031e1dc9abb7c8fa596657a2977c8957605c8222 /main/py-libvirt/musl-gnuc-prereq.patch
parentd13909666badb65577087723a4ee3481adbace05 (diff)
downloadaports-371e29c29e5f4f0002d0d692886a73be7a4d7dfa.tar.bz2
aports-371e29c29e5f4f0002d0d692886a73be7a4d7dfa.tar.xz
main/py-libvirt: fix musl build
Diffstat (limited to 'main/py-libvirt/musl-gnuc-prereq.patch')
-rw-r--r--main/py-libvirt/musl-gnuc-prereq.patch18
1 files changed, 18 insertions, 0 deletions
diff --git a/main/py-libvirt/musl-gnuc-prereq.patch b/main/py-libvirt/musl-gnuc-prereq.patch
new file mode 100644
index 000000000..2e3c95e3f
--- /dev/null
+++ b/main/py-libvirt/musl-gnuc-prereq.patch
@@ -0,0 +1,18 @@
+--- libvirt-python-1.2.0.orig/libvirt-utils.h
++++ libvirt-python-1.2.0/libvirt-utils.h
+@@ -28,6 +28,15 @@
+ # define MIN(a,b) (((a) < (b)) ? (a) : (b))
+ # endif
+
++# ifndef __GNUC_PREREQ
++# if defined __GNUC__ && defined __GNUC_MINOR__
++# define __GNUC_PREREQ(maj, min) \
++ ((__GNUC__ << 16) + __GNUC_MINOR__ >= ((maj) << 16) + (min))
++# else
++# define __GNUC_PREREQ(maj, min) 0
++# endif
++#endif
++
+ /**
+ * libvirt.h provides this as of version 1.2.0, but we want to be able
+ * to support older versions of libvirt so copy and paste the macro from