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 Bruce Snyder <bs...@pengroup.com> on 2000/05/15 22:40:07 UTC

Need help with Xerces-perl on Win NT4.0!

I have repeatedly attempted to install Xerces-perl 1.0 under Win NT 4.0
SP 5 with ActivePerl 5.6 build 613 using Visual C++ 6.0 and I have yet
to receive a successful install. I am really under a lot of pressure to
get this installed. Any help would be *greatly* appreciated

I successfully set up Xerces-c 1.1.0, SWIG 1.1, ICU 1.4.1.2. I then
edited the makefile.pl to properly reflect the locations of these items
on my computer. Then I begin the setup of Xerces-perl using the
following steps on the command line (output is included): 

-----------------------------------------------------------------
1. vcvars32 
Setting environment for using Microsoft Visual C++ tools.
2. swig -perl5 -c++ xerces.i
Generating wrappers for Perl 5

3. perl makefile.pl
Writing Makefile for Xerces

4. nmake

Microsoft (R) Program Maintenance Utility   Version 6.00.8168.0
Copyright (C) Microsoft Corp 1988-1998. All rights reserved.

mkdir blib
mkdir blib\lib
mkdir blib\arch
mkdir blib\arch\auto
mkdir blib\arch\auto\Xerces
mkdir blib\lib\auto
mkdir blib\lib\auto\Xerces
cp DOM.pm blib\lib/Xerces/DOM.pm
cp DOMPARSE.pm blib\lib/Xerces/DOMPARSE.pm
cp Xerces.pm blib\lib/Xerces/Xerces.pm
        cl -c -Id:/xerces-c_1_1_0/include/
-Id:/icu-1.1.1.2/bin/Release/icu/ -O1 -MD -DNDEBUG -DWIN3
2 -D_CONSOLE -DNO_STRICT -DHAVE_DES_FCRYPT -DPERL_IMPLICIT_CONTEXT
-DPERL_IMPLICIT_SYS -DPERL_MSVCRT
_READFIX -O1 -MD -DNDEBUG      -DVERSION=\"0.10\"  -DXS_VERSION=\"0.10\"
-TP -GX -ID:\Perl\lib\CORE
-DHAS_BOOL Xerces_wrap.c
Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 12.00.8168 for
80x86
Copyright (C) Microsoft Corp 1984-1998. All rights reserved.

Xerces_wrap.c
Xerces_wrap.c(292) : error C2065: 'sv_undef' : undeclared identifier
Xerces_wrap.c(292) : error C2446: '==' : no conversion from 'int *' to
'struct sv *'
        Types pointed to are unrelated; conversion requires
reinterpret_cast, C-style cast or functi
on-style cast
Xerces_wrap.c(292) : error C2230: '==' : indirection to different types
Xerces_wrap.c(411) : error C2440: '=' : cannot convert from 'int
(__cdecl *)(struct sv *,struct magi
c *)' to 'int (__cdecl *)(struct interpreter *,struct sv *,struct magic
*)'
        This conversion requires a reinterpret_cast, a C-style cast or
function-style cast
Xerces_wrap.c(412) : error C2440: '=' : cannot convert from 'int
(__cdecl *)(struct sv *,struct magi
c *)' to 'int (__cdecl *)(struct interpreter *,struct sv *,struct magic
*)'
        This conversion requires a reinterpret_cast, a C-style cast or
function-style cast
Xerces_wrap.c(8280) : error C2065: 'na' : undeclared identifier
Xerces_wrap.c(8920) : error C2039: 'strcmp' : is not a member of
'DOMString'
        d:/xerces-c_1_1_0/include/dom/DOMString.hpp(125) : see
declaration of 'DOMString'
Xerces_wrap.c(9640) : error C2733: second C linkage of overloaded
function 'boot_Xerces' not allowed

        Xerces_wrap.c(9640) : see declaration of 'boot_Xerces'
Xerces_wrap.c(10220) : error C2065: 'sv_yes' : undeclared identifier
Xerces_wrap.c(10220) : error C2440: '=' : cannot convert from 'int *' to
'struct sv *'
        Types pointed to are unrelated; conversion requires
reinterpret_cast, C-style cast or functi
on-style cast
NMAKE : fatal error U1077: 'cl' : return code '0x2'
Stop.
-----------------------------------------------------------------

I have dug around the web looking for any solutions to these errors and
I cannot find anything. I am desparate to get these modules installed as
I am under a deadline.

Thank your for your help. 
-- 
Bruce Snyder
Technical Integration Architect
PENgroup.com
9510 Meridian Boulevard
Englewood, CO 80112
desk: 720.873.5485
cell: 720.635.5471
bsnyder@pengroup.com

Re: Need help with Xerces-perl on Win NT4.0!

Posted by Bruce Snyder <bs...@pengroup.com>.
Where should this be placed in xerces.i? I've placed it starting on line
#11, but the nmake still dies throwing the same errors.

BTW, thanks very much for the assistance.

"Jason E. Stewart" wrote:
> 
> >>>>> "Bruce" == Bruce Snyder <bs...@pengroup.com> writes:
> Bruce> Xerces_wrap.c
> Bruce> Xerces_wrap.c(292) : error C2065: 'sv_undef' : undeclared identifier
> Bruce> Xerces_wrap.c(292) : error C2446: '==' : no conversion from 'int *' to
> Bruce> 'struct sv *'
> 
> Hey Bruce,
> 
> This is a problem with SWIG. It doesn't handle later versions of perl
> very elegantly. The problem is with all the 'undeclared identifier'
> errors. Later Perls redefined these symbols to be something like
> Perl_sv_undef so as not to pollute the namespace of programs that
> might want to embed them.
> 
> To handle it for the latest Unix/Windows friendly release of xerces I
> added this chunk to Xerces.i
> 
> %{
>   #ifndef PERL_REVISION
>     #define PL_na na
>     #define PL_sv_undef sv_undef
>     #define PL_sv_yes sv_yes
>   #else
>     #define PERL_POLLUTE
>   #endif
> %}
> 
> Perl 5.6 defines PERL_POLLUTE which will make the appropriate
> modifications to na, sv_undef, and sv_yes, other earlier versions need
> to have it done by hand.
> 
> *** WARNING ***
> Be prepared to do a lot of this. The code you are using is definately
> not ready for prime time. If you enjoy getting into the guts of perl
> than this will work, if you do not I would strongly encourage using a
> more stable parser with less functionality like XML::Parser or
> XML::DOM.
> 
> It will be some time before there is a stable, push-button install for
> xerces.
> 
> jas.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-p-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-p-dev-help@xml.apache.org

-- 
Bruce Snyder
Technical Integration Architect
PENgroup.com
9510 Meridian Boulevard
Englewood, CO 80112
desk: 720.873.5485
cell: 720.635.5471
bsnyder@pengroup.com

Re: Need help with Xerces-perl on Win NT4.0!

Posted by "Jason E. Stewart" <je...@ncgr.org>.
>>>>> "Bruce" == Bruce Snyder <bs...@pengroup.com> writes:
Bruce> Xerces_wrap.c
Bruce> Xerces_wrap.c(292) : error C2065: 'sv_undef' : undeclared identifier
Bruce> Xerces_wrap.c(292) : error C2446: '==' : no conversion from 'int *' to
Bruce> 'struct sv *'

Hey Bruce,

This is a problem with SWIG. It doesn't handle later versions of perl
very elegantly. The problem is with all the 'undeclared identifier'
errors. Later Perls redefined these symbols to be something like
Perl_sv_undef so as not to pollute the namespace of programs that
might want to embed them.

To handle it for the latest Unix/Windows friendly release of xerces I
added this chunk to Xerces.i

%{
  #ifndef PERL_REVISION
    #define PL_na na
    #define PL_sv_undef sv_undef 
    #define PL_sv_yes sv_yes
  #else
    #define PERL_POLLUTE
  #endif
%}

Perl 5.6 defines PERL_POLLUTE which will make the appropriate
modifications to na, sv_undef, and sv_yes, other earlier versions need 
to have it done by hand.

*** WARNING ***
Be prepared to do a lot of this. The code you are using is definately
not ready for prime time. If you enjoy getting into the guts of perl
than this will work, if you do not I would strongly encourage using a
more stable parser with less functionality like XML::Parser or
XML::DOM. 

It will be some time before there is a stable, push-button install for 
xerces.

jas.