Marcelo Matus | 5 Dec 2005 23:28
Picon

Re: Swig preprocessor broken?

Ok, here is a better solution, use the CVS version and either use

  swig -erroraswarn 1 ...

or

--- arp.i ---
%module arp.i
%{
#include "arp.h"
%}
#pragma SWIG erroraswarn=1
%include arp.h
const int APR_PATH_MAX = APR_PATH_MAX;
--- arp.i ---

where the option/pragma "erroraswarn" force (or not) to treat
the cpp #error directive as a #warning instead.

hmm,maybe the name should be "cpperroraswarn", but is getting too long.

Marcelo

Torsten Landschoff wrote:

>Hi Marcelo, 
>
>On Mon, Dec 05, 2005 at 03:13:10AM -0700, Marcelo Matus wrote:
> 
>  
>
>>yeap,
>>
>>#ifdef SWIG
>>#endif
>>
>>but I still think in your case is much much simpler define
>>
>>----
>>%module apr
>>%{
>>#include "apr.h"
>>%}
>>#define PATH_MAX PATH_MAX
>>%include "apr.h"
>>const int APR_PATH_MAX = APR_PATH_MAX;
>>    
>>
> 
>Probably it is as the other way will need talking to upstream. Anyway
>it's not my construction site but the problem appeared in building
>subversion. I'll take this to the subversion developers list. 
>
>Thanks to all for information and suggestions, 
>
>	Torsten
>  
>

-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click

Gmane