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 Patrick Kuijvenhoven <pk...@office.kabelfoon.nl> on 2003/11/03 16:41:12 UTC

Build problems for XML::Xerces on FreeBSD

Hi, 

i need some help with compiling XML::Xerces on FreeBSD 4.7. Relevant information is shown below:

# perl Makefile.PL
Using XERCES_LIB = /usr/local/include/xercesc/
Using XERCES_INCLUDE = /usr/local/include/
using config file: /usr/ports/textproc/xerces-c2/work/xerces-c-src_2_3_0//src/xercesc/config.status

Found CXX      = c++
Found CXXFLAGS =  -pipe -DNONEXPORTABLE_CRYPT -w -DXML_USE_LIBICONV -I/usr/local/include -DXML_USE_INMEM_MESSAGELOADER -D_THREAD_SAFE -DXML_USE_PTHREADS -DXML_USE_NETACCESSOR_SOCKET
Found LDFLAGS  =
Using Xerces-C version info from /usr/local/include//xercesc/util/XercesVersion.hpp
Checking to see if libxerces is in your library path...Success!!
Using Xerces-C version: 2.3.0
Note (probably harmless): No library found for -lpthread
Writing Makefile for Handler
Writing Makefile for XML::Xerces

# c++ -v
Using builtin specs.
gcc version 2.95.4 20020320 [FreeBSD]

# gmake
gmake -C Handler static
gmake[1]: Entering directory `/usr/local/src/XML-Xerces-2.3.0-2/Handler'
c++ -c  -I. -IHandler -I/usr/local/include/ -pipe -DNONEXPORTABLE_CRYPT -w -DXML_USE_LIBICONV -I/usr/local/include -DXML_USE_INMEM_MESSAGELOADER -D_THREAD_SAFE -DXML_USE_PTHREADS -DXML_USE_NETACCESSOR_SOCKET -D_REENTRANT -O   -DVERSION=\"\" -DXS_VERSION=\"\" -DPIC -fPIC "-I/usr/local/lib/perl5/5.8.1/mach/CORE"   PerlCallbackHandler.cpp
c++ -c  -I. -IHandler -I/usr/local/include/ -pipe -DNONEXPORTABLE_CRYPT -w -DXML_USE_LIBICONV -I/usr/local/include -DXML_USE_INMEM_MESSAGELOADER -D_THREAD_SAFE -DXML_USE_PTHREADS -DXML_USE_NETACCESSOR_SOCKET -D_REENTRANT -O   -DVERSION=\"\" -DXS_VERSION=\"\" -DPIC -fPIC "-I/usr/local/lib/perl5/5.8.1/mach/CORE"   PerlContentCallbackHandler.cpp
In file included from PerlContentCallbackHandler.cpp:2:
PerlContentCallbackHandler.hpp:10: syntax error before `:'
gmake[1]: *** [PerlContentCallbackHandler.o] Error 1
gmake[1]: Leaving directory `/usr/local/src/XML-Xerces-2.3.0-2/Handler'
gmake: *** [blib/arch/auto/Handler/Handler.a] Error 2

I allready tried to compile the source with g++33 (gcc version 3.3.1 20030707 (prerelease) [FreeBSD]), but it still doesn't compile.

Any help appreciated :)

Kind regards,

Patrick Kuijvenhoven, 
R&D Team Kabelfoon
E: pkuijven@office.kabelfoon.nl




Re: Build problems for XML::Xerces on FreeBSD

Posted by "Jason E. Stewart" <ja...@openinformatics.com>.
"Patrick Kuijvenhoven" <pk...@office.kabelfoon.nl> writes:

> i need some help with compiling XML::Xerces on FreeBSD 4.7. Relevant
> information is shown below:

It's been quite some time since someone reported on BSD, and we've
automated the build system a lot since then, so it doesn't surprise me
if there's some glitches.

We'll probably need to get the right Xerces flags for OS and compiler.

> Found CXX      = c++

This is probably an issue. Right now I look for g++ to set the
-DXML_GCC flag. Perhaps I should actually run 'c++ --version' and
check the output.

> # c++ -v
> Using builtin specs.
> gcc version 2.95.4 20020320 [FreeBSD]

Is your Xerces-C compiled with 2.95 as well?

> In file included from PerlContentCallbackHandler.cpp:2:
> PerlContentCallbackHandler.hpp:10: syntax error before `:'
> gmake[1]: *** [PerlContentCallbackHandler.o] Error 1
> gmake[1]: Leaving directory `/usr/local/src/XML-Xerces-2.3.0-2/Handler'
> gmake: *** [blib/arch/auto/Handler/Handler.a] Error 2

I'm just guessing, but its probably not understanding the namespace
macro:

  #include "PerlCallbackHandler.hpp"
  #include "xercesc/sax2/ContentHandler.hpp"
  #include "xercesc/util/XMLString.hpp"
  
  XERCES_CPP_NAMESPACE_USE
  
  class PerlContentCallbackHandler  : public ContentHandler
  //				 , public PerlCallbackHandler 
  {

XERCES_CPP_NAMESPACE_USE is defined in the OS/compiler specific bits
of Xerces. Try commenting this out just to see if the compile gets any
further.

> I allready tried to compile the source with g++33 (gcc version 3.3.1
> 20030707 (prerelease) [FreeBSD]), but it still doesn't compile.

Where the errors different?

Cheers,
jas.

---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-p-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-p-dev-help@xml.apache.org