You are viewing a plain text version of this content. The canonical link for it is here.
Posted to p-dev@xerces.apache.org by "Jason E. Stewart" <ja...@openinformatics.com> on 2001/03/06 21:05:47 UTC

Re: [Fwd: Jason Stewart: xerces-perl mods]

Hey Harmon,

The easies thing is for me to finish checking all this into CVS...
>
> How is it you're make the formerly XERCES modules into XML::Xerces via SWIG?
> Swig doesn't like a "%module XML::Xerces" in the Xerces.i file.  You can 
> use the
> "-package XML::Xerces" command-line option, but that doesn't really do 
> the trick,
> since you still say "use Xerces" in a perl-script, and the module still 
> wants to autoload
> auto/XERCES/XERCES.so instead of auto/XML/XERCES/Xerces.so

Yes I'm using 'swig -package XML::Xerces', and in the Makefile.pl, the
Name is 'XML::Xerces'. Thus the file is called Xerces.pm, and perl
installs it into the XML/ directory of $INST_LIB. So that way it works
with a 'use XML::Xerces;'

> As for the diff-file change:
> 
> -    result = new DOM_Node const (arg0->getCommonAncestorContainer()); 
>    ST(argvi) = sv_newmortal();
> +    result = new DOM_Node (arg0->getCommonAncestorContainer());    
> ST(argvi) = sv_newmortal();
> 
> I'm trying to figure out where that "const" came from that the diff is 
> removing.  I think its
> from the dom/DOM_Range.hpp header file, i.e. "const" at the end of the 
> following
> declaration:
> 
> const DOM_Node getCommonAncestorContainer() const;
> 
> Try commenting this out:
> 
> const DOM_Node getCommonAncestorContainer() /*const*/;
> 
> to see if this makes it so you don't need the diff.  By the way, there's 
> *lots* of
> declarations like this.  If they're a problem with SWIG 1.3, they all 
> need to be
> commented out.  I'm working on this and the rest as I write this, since 
> it can't
> do any harm anyway...

Funny that was the only line the compiler bitched about....

jas.

--NAA05525.983909148/amadeus.openinformatics.com--


Re: [Fwd: Jason Stewart: xerces-perl mods]

Posted by "Harmon S. Nine" <hn...@netarx.com>.
Hmm... very weird.  Does commenting out that const fix the problem, or 
do you still
need the diff?

-- Harmon

Jason E. Stewart wrote:

>> Try commenting this out:
>> 
>> const DOM_Node getCommonAncestorContainer() /*const*/;
>> 
>> to see if this makes it so you don't need the diff.  By the way, there's 
>> *lots* of
>> declarations like this.  If they're a problem with SWIG 1.3, they all 
>> need to be
>> commented out.  I'm working on this and the rest as I write this, since 
>> it can't
>> do any harm anyway...
> 
> Funny that was the only line the compiler bitched about....
> 
> jas.
> 
> 




Re: [Fwd: Jason Stewart: xerces-perl mods]

Posted by "Harmon S. Nine" <hn...@netarx.com>.
Jason E. Stewart wrote:

> "Jason E. Stewart" <ja...@openinformatics.com> writes:
> 
> 
>> Hey Harmon,
>> 
>> The easies thing is for me to finish checking all this into CVS...
>> 
>>> How is it you're make the formerly XERCES modules into XML::Xerces via SWIG?
>>> Swig doesn't like a "%module XML::Xerces" in the Xerces.i file.  You can 
>>> use the
>>> "-package XML::Xerces" command-line option, but that doesn't really do 
>>> the trick,
>>> since you still say "use Xerces" in a perl-script, and the module still 
>>> wants to autoload
>>> auto/XERCES/XERCES.so instead of auto/XML/XERCES/Xerces.so
>> 
>> Yes I'm using 'swig -package XML::Xerces', and in the Makefile.pl, the
>> Name is 'XML::Xerces'. Thus the file is called Xerces.pm, and perl
>> installs it into the XML/ directory of $INST_LIB. So that way it works
>> with a 'use XML::Xerces;'
> 
> OK, I get it. SWIG 1.1 does not properly handle -package, god what a
> pain. I just spent 30 minutes wrestling with 1.1 to try to modify the
> namespace, and it just refuses. 
> 
> The good news: 1.3 handles -package properly
> 
> The bad news: I'm getting these wierd const problems all over the
> place with 1.3.
> 
> jas.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-p-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-p-dev-help@xml.apache.org
> 
> 

Sounds like SWIG 1.3 doesn't handle the "const" after those method 
declarations in
DOM_Node (and any other file that does the same thing).  They probably 
just need to
be commented out.

As for the XML:Xerces problem, I think the postSource.pl script could be 
modified to
mung the module appropriately.

Let's work on this in parallel and combine the results.

-- Harmon


Re: [Fwd: Jason Stewart: xerces-perl mods]

Posted by "Jason E. Stewart" <ja...@openinformatics.com>.
"Jason E. Stewart" <ja...@openinformatics.com> writes:

> Hey Harmon,
> 
> The easies thing is for me to finish checking all this into CVS...
> >
> > How is it you're make the formerly XERCES modules into XML::Xerces via SWIG?
> > Swig doesn't like a "%module XML::Xerces" in the Xerces.i file.  You can 
> > use the
> > "-package XML::Xerces" command-line option, but that doesn't really do 
> > the trick,
> > since you still say "use Xerces" in a perl-script, and the module still 
> > wants to autoload
> > auto/XERCES/XERCES.so instead of auto/XML/XERCES/Xerces.so
> 
> Yes I'm using 'swig -package XML::Xerces', and in the Makefile.pl, the
> Name is 'XML::Xerces'. Thus the file is called Xerces.pm, and perl
> installs it into the XML/ directory of $INST_LIB. So that way it works
> with a 'use XML::Xerces;'

OK, I get it. SWIG 1.1 does not properly handle -package, god what a
pain. I just spent 30 minutes wrestling with 1.1 to try to modify the
namespace, and it just refuses. 

The good news: 1.3 handles -package properly

The bad news: I'm getting these wierd const problems all over the
place with 1.3.

jas.