summaryrefslogtreecommitdiff
path: root/typewrappers.h
diff options
context:
space:
mode:
authorDaniel P. Berrangé <berrange@redhat.com>2018-07-09 09:04:23 +0100
committerDaniel P. Berrangé <berrange@redhat.com>2018-07-16 15:26:53 +0100
commitd68c14e069db7e2a2ef1de76aca734f918189513 (patch)
treea162056475b95a21f0d4c8be3ccf80c8c7c97fe6 /typewrappers.h
parent2efd1e9ab264639b35da4be5c405fba48c32fa7a (diff)
downloadlibvirt-python-d68c14e069db7e2a2ef1de76aca734f918189513.tar.gz
fix build with older libvirt missing virNWFilterBindingPtr
While we correctly disable all public API bindings that rely on virNWFilterBindingPtr, the generator is still creating a helper function that needs it - libvirt_virNWFilterBinding_pointer. Making this helper conditional is a little hairy, so just provide a trivial typedef to keep it happy. Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Diffstat (limited to 'typewrappers.h')
-rw-r--r--typewrappers.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/typewrappers.h b/typewrappers.h
index 1570c6a..4423774 100644
--- a/typewrappers.h
+++ b/typewrappers.h
@@ -27,6 +27,10 @@
typedef ssize_t Py_ssize_t;
#endif
+#if !LIBVIR_CHECK_VERSION(4, 5, 0)
+typedef struct _virNWFilterBinding *virNWFilterBindingPtr;
+#endif
+
#define PyvirConnect_Get(v) (((v) == Py_None) ? NULL : \
(((PyvirConnect_Object *)(v))->obj))