logo       

Re: swig and perl580 and sun solaris compiler 5.3: msg#00127

programming.swig

Subject: Re: swig and perl580 and sun solaris compiler 5.3

-I/usr/local/tibco/6.6/SOL28/SPARC/include -xarch=v8plusa -g
-ptrdebug_dir -o debug_dir/client_wrap.o -c client_wrap.C
"/usr/local/rogue711/workspaces/SOLARIS28/SUNPRO52/12s_nonstl/rw/tislist.h",
line 130: Warning: Too few arguments in macro apply.
"/usr/local/rogue711/workspaces/SOLARIS28/SUNPRO52/12s_nonstl/rw/xpslist.h",
line 178: Warning: Too few arguments in macro apply.

I am faily certain that this is the same problem as the iostreams problem.
http://mailman.cs.uchicago.edu/pipermail/swig/2003-January/006615.html

The problem is that in the perl headers, there is a macro named apply being defined (in embed.h). Actually, there is a macro named Perl_apply which for convenience is also defined to apply. So then later, when other files try and use the name apply the perl macro gets expanded.

A quick hack would be either to not include embed.h (you will have to try that, I have no idea if it will work) or undef all the macros that give problems. So for example you could do something like

#include "EXTERN.h"
#include "perl.h"
#include "XSUB.h"
#undef apply
#undef ....

Well actually you should put the undef's in the .i file so they get added to the generated file. I am looking at fixing this problem for the next release of SWIG and not having to use those undefs.

John
_______________________________________________
Swig maillist - Swig@xxxxxxxxxxxxxxx
http://mailman.cs.uchicago.edu/mailman/listinfo/swig



<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise