Joe Orton wrote:
[...]
Thanks Joe. So what kind of hack of the hack can we use here? I suppose that even if it did expand it, there would have been a problem since we have:

 #define modperl_io_apache_init(pTHX)

so it expands to nothing. Of course the right solution is to never include this in the autogenerated modperl_exports.c but this will require C parsing with some messy sed like Apache/APR do. Is there some other solution for this kind of functions?


Just make the generated export stub code #ifndef'ed?

#ifndef modperl_io_apache_init
const void *modperl_hack_io_apache_init = (const void *)modperl_io_apache_init;
#endif

if the symbol is a macro then there's no point in generating a stub for
it anyway...

It's not a macro normally, it's a macro only on certain setups. Here it is again:


#ifdef PERLIO_LAYERS
MP_INLINE void modperl_io_apache_init(pTHX);
#else
#define        modperl_io_apache_init(pTHX)
#endif

So that trick of #ifndef, won't work when PERLIO_LAYERS is not defined, right? Since modperl_io_apache_init is always defined but something it's a real symbols at other times it's a macro to keep some compilers happy.

Thanks.

--
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

--
Report problems: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html
List etiquette: http://perl.apache.org/maillist/email-etiquette.html



Reply via email to