Update of /cvsroot/mahogany/M/src/Python
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31008/src/Python
Modified Files:
Names.mk
Log Message:
hack to fix linking problems with swig 1.3.21+: undo the renaming of SWIG_xxx
functions to SWIG_Python_xxx
Index: Names.mk
===================================================================
RCS file: /cvsroot/mahogany/M/src/Python/Names.mk,v
retrieving revision 1.12
retrieving revision 1.13
diff -b -u -2 -r1.12 -r1.13
--- Names.mk 6 Jan 2004 01:26:22 -0000 1.12
+++ Names.mk 21 Jul 2004 10:55:12 -0000 1.13
@@ -33,8 +33,19 @@
# this command replaces #include Python.h in the generated C++ code with
# #include MPython.h which we need for dynamic Python linking to work
+#
+# further, newer versions of swig (1.3.21) now automatically rename SWIG_xxx
+# functions to SWIG_Python_xxx which is very nice but incompatible with the
+# old versions because we have to also declare these functions ourselves as
+# they're not declared in any header -- and as we don't have an easy way to
+# check how the functionsare called we simply disable the #define's which do
+# the renaming in swig-generated code
define create_cpp
$(SWIG) -I$(IFACE_DIR) $(CPPFLAGS) $(SWIGFLAGS) \
$(if $(subst swiglib,,$*),-c) -o $(@:.o=.cpp) $< && \
- sed -e 's/Python\.h/MPython.h/' $(@:.o=.cpp) > $(@:.o=.cpp).new && mv
$(@:.o=.cpp).new $(@:.o=.cpp)
+ sed -e 's/Python\.h/MPython.h/' \
+ -e '/^#define SWIG_\(\w\+\) \+SWIG_Python_\1/d' \
+ -e '/^#define SWIG_\w\+(.*\\$$/,/^ \+SWIG_Python_\w\+(/d' \
+ -e 's/SWIG_Python_/SWIG_/g' $(@:.o=.cpp) \
+ > $(@:.o=.cpp).new && mv $(@:.o=.cpp).new $(@:.o=.cpp)
endef
-------------------------------------------------------
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=4721&alloc_id=10040&op=click
_______________________________________________
Mahogany-cvsupdates mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mahogany-cvsupdates