[Users] [PATCH v2 2/5] osx: fix python plugin build error

Igor Mammedov imammedo at redhat.com
Thu Jan 22 17:35:57 CET 2015


Fixes following build error on OS X:

duplicate symbol __PyGtk_API in:
    .libs/python_la-clawsmailmodule.o
    .libs/python_la-python-hooks.o
duplicate symbol __PyGObject_API in:
    .libs/python_la-clawsmailmodule.o
    .libs/python_la-python-hooks.o

Signed-off-by: Igor Mammedov <imammedo at redhat.com>
---
 src/plugins/python/python-hooks.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/plugins/python/python-hooks.c b/src/plugins/python/python-hooks.c
index 4cd1cb5..9001f64 100644
--- a/src/plugins/python/python-hooks.c
+++ b/src/plugins/python/python-hooks.c
@@ -27,6 +27,10 @@
 
 #ifdef ENABLE_PYTHON
 #include <Python.h>
+#ifdef __APPLE__
+#define NO_IMPORT_PYGOBJECT
+#define NO_IMPORT_PYGTK
+#endif
 #include <pygobject.h>
 #include <pygtk/pygtk.h>
 #endif // ENABLE_PYTHON
-- 
1.9.3 (Apple Git-50)




More information about the Users mailing list