"David Starks-Browning" <[EMAIL PROTECTED]> writes:
> Notice how hints/dec_osf.pl is processed twice, but seems not to make
> sense of it the first time.
Hey David,
It does things twice because I tell it to. The first time through I
check for libxerces on your system and if I don't find it, I exit.
> In my case, since perl was built with gcc but hints/dec_osf1.pl
> sepecifies cxx, I find that Handler/Makefile uses gcc, but Xerces.C
> is compiled with cxx. Does that make sense? I have no idea how to
> read Makefile.PL files, sorry!
Hmm.. No it doesn't. I must admit that I only discovered about hints
files recently while looking over how other C++ modules dealt with C++
compiler issues. The hints/ directory is the standard way to include
arch-specific information. It appears that I would need to have a
separate hints file for Handler as well.
If your perl was built with gcc, then you did the correct
thing. Makefile.PL files are just perl scripts, nothing strange about
them, except the final subrouting call to WriteMakefile() recursively
descends the directory structure writing Makefiles for all directories
with a Makefile.PL in it.
> After commenting out the cxx definitions in hints/dec_osf1.pl (since
> gcc should be able to handle C++ code), I get the following error in
> "make":
>
> > gcc -c -I. -IHandler -I/sw/common/src/xerces-c_2001-10-05/alpha-osf1/include
>-D_REENTRANT -DHAS_BOOL -O3 -DVERSION=\"1.5.7\" -DXS_VERSION=\"1.5.7\" -fpic
>-I/sw/common/share/perl/5.00503/alpha-osf1/CORE Xerces.C
> > Xerces.C: In function `struct swig_type_info * SWIG_TypeCheck(SV *, swig_type_info
>*)':
> > Xerces.C:175: passing `const char *' as argument 2 of `Perl_sv_derived_from(SV *,
>char *)' discards qualifiers
> > make: *** [Xerces.o] Error 1
>
> Is that a problem with my configuration or with Xerces.C?
Looks like an issue with Xerces.C because the call to
sv_derived_from() is inserted by me.
Test this. Edit Xerces.C line 175 from:
if (sv_derived_from(sv,s->name)) {
to:
if (sv_derived_from(sv,(char*)s->name)) {
or if g++ doesn't like that try
if (sv_derived_from(sv,const_cast<s->name>)) {
That way we tell the compiler it's OK to discard the const qualifier.
jas.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]