Blame zarafa-6.40.0-undefined-symbol.patch

77c66b7
Re-merged patch by Robert Scheck <robert@fedoraproject.org> for zarafa >= 6.40.0, which corrects
77c66b7
the linking between the libraries. Without this patch, any PHP usage causes the PHP error message
77c66b7
"undefined symbol: _ZN10ECMemTable6CreateEP14_SPropTagArrayjPPS_". The second hunk is required to
77c66b7
avoid linking errors like "(.rodata+0x0): multiple definition of `IID_IUnknown'". This patch was
77c66b7
originally by Michel de Ron (Zarafa); http://forums.zarafa.com/viewtopic.php?f=1&t=2418&start=15
77c66b7
is providing some more details and information.
77c66b7
77c66b7
--- zarafa-6.40.0/mapi4linux/src/Makefile.am			2010-05-31 15:44:42.000000000 +0200
77c66b7
+++ zarafa-6.40.0/mapi4linux/src/Makefile.am.undefined-symbol	2010-06-08 22:32:12.000000000 +0200
77c66b7
@@ -3,7 +3,9 @@
77c66b7
 AM_CPPFLAGS = $(DEBUGFLAGS) -DLINUX -I$(top_srcdir)/mapi4linux/include -I$(top_srcdir)/provider/common -I${top_srcdir}/common -I${top_srcdir}/libfreebusy
77c66b7
 AM_LDFLAGS = $(DL_LIBS) -export-symbols ${top_srcdir}/mapi4linux/src/mapi-exports.sym
77c66b7
 
77c66b7
-libmapi_la_LIBADD = ${top_builddir}/common/libcommon_util.la
77c66b7
+libmapi_la_LIBADD = ${top_builddir}/common/libcommon_util.la \
77c66b7
+	${top_builddir}/common/libcommon_mapi.la \
77c66b7
+	$(PROG_LIBS)
77c66b7
 
77c66b7
 # required because we're exporting extern "C" functions and want to filter with 'export-symbols'
77c66b7
 CXXLD=--tag=none gcc
77c66b7
--- zarafa-6.40.0/mapi4linux/src/m4lguids.cpp			2010-05-31 19:28:56.000000000 +0200
77c66b7
+++ zarafa-6.40.0/mapi4linux/src/m4lguids.cpp.undefined-symbol	2010-06-08 22:47:30.000000000 +0200
77c66b7
@@ -48,19 +48,5 @@
77c66b7
  */
77c66b7
 
77c66b7
 #include "platform.h"
77c66b7
-#define USES_IID_IUnknown
77c66b7
-#define USES_IID_IStream
77c66b7
-#define USES_IID_ISequentialStream
77c66b7
-#define USES_IID_IProfAdmin
77c66b7
-#define USES_IID_IProviderAdmin
77c66b7
-#define USES_IID_IMAPIAdviseSink
77c66b7
-#define USES_IID_IMsgServiceAdmin
77c66b7
-#define USES_IID_IProfSect
77c66b7
-#define USES_IID_IMAPISession
77c66b7
-#define USES_IID_IMAPIProp
77c66b7
-#define USES_IID_IMAPIFolder
77c66b7
-#define USES_IID_IMAPITable
77c66b7
-#include <initguid.h>
77c66b7
-
77c66b7
 #include "mapiguid.h"
77c66b7
 #include "m4l.mapiutil.h"