Archived

This forum has been archived. Please start a new discussion on GitHub.

Make on Red Hat Enterprise Linux ES release 2.1 (Panama) fails

Hi,

I have downloaded ICE 1.1.1.

When I try to compile it I get the next messages:
In file included from Unicode.cpp:15:
../../include/IceUtil/Unicode.h:23: parse error before `&'
../../include/IceUtil/Unicode.h:24: syntax error before `('
Unicode.cpp:28: parse error before `&'

and many more.

I run the following version of the compiler (-v option):

c++ -c -I../../include -DICE_UTIL_API_EXPORTS -v -g -ftemplate-depth-128 -fPIC -Wall -D_REENTRANT Unicode.cpp
Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/2.96/specs
gcc version 2.96 20000731 (Red Hat Linux 7.2 2.96-118.7.2)

Can anybody tell me what I do wrong?

Thanks in advance.

Albert

Comments

  • marc
    marc Florida
    This is a very old compiler version (2.96). Can you perhaps try GCC 3.2?

    We support GCC 2.97 with STLport (the STL included in GCC 2.97 is broken). So if you cannot switch to GCC 3.2 for some reason, you must compile Ice with STLport. However, given the choice, I recommend to use GCC 3.2 over GCC 2.97 + STLport.
  • Xerces

    Hi,

    While building, now with gcc 3.2.3 and after downloading and installing Xerces 2.3 the build still does not work.
    I get the following errors:
    c++ -g -ftemplate-depth-128 -fPIC -Wall -D_REENTRANT -L../../lib -o ../../bin/xsdvalidate Validate.o -lIceUtil -lpthread -L/usr/local/src/xerces/xerces-c-src_2_3_0/lib -lxerces-c
    /usr/bin/ld: Dwarf Error: Invalid or unhandled FORM value: 14.
    /usr/bin/ld: Dwarf Error: Invalid or unhandled FORM value: 14.
    /usr/bin/ld: Dwarf Error: Invalid or unhandled FORM value: 14.
    Validate.o: In function `toString(unsigned short const*)':
    :35: undefined reference to `xercesc_2_3::XMLString::transcode(unsigned short const*)'
    Validate.o: In function `main':
    :106: undefined reference to `xercesc_2_3::XMLUni::fgXercescDefaultLocale'

    followed by many others.

    a. o. undefined labels from xerces:
    /usr/local/src/xerces/xerces-c-src_2_3_0/lib/libxerces-c.so: undefined reference to `ostream::flush(void)'
    /usr/local/src/xerces/xerces-c-src_2_3_0/lib/libxerces-c.so: undefined reference to `ostream::write(char const *, int)'
    /usr/local/src/xerces/xerces-c-src_2_3_0/lib/libxerces-c.so: undefined reference to `cout'

    The makefile is in the directory slice2xsd and building xdsvalidate.

    Still something missing, or is there another problem?

    Thanks in advance.

    Albert
  • bernard
    bernard Jupiter, FL
    Hi Albert,

    Xerces-C is really a C++ library, so you need to build it with a C++ compiler compatible with your GCC version. GCC 2.9x and 3.x are not compatible.

    Cheers,
    Bernard
  • Hello Bernard,

    We have already upgraded our compiler to versie 3.2.3.
    With this version we have compiled Xerces-C.

    What else can be wrong?

    Albert
  • bernard
    bernard Jupiter, FL
    Hi Albert,

    We don't have access to a RedHat Entreprise Linux 2.1 system, so I tried with RedHat 7.3.

    I built GCC 3.2.3 and installed it in my home directory, and then added the corresponding bin directory to my PATH and the corresponding lib directory to my LD_LIBRARY_PATH.
    Next I built Xerces-C 2.3.0 with this compiler, and installed it also in my home directory. I defined XERCESC_HOME to point to this installation (see config/Make.rules in the Ice source distribution), and added $XERCESC_HOME/lib to my LD_LIBRARY_PATH.
    And finally I built Ice 1.1.1 without any problems (the tests passed as well).

    Maybe you could double-check that your libxerces-c.so is built as you expect, for example with:
    ldd $XERCESC_HOME/lib/libxerces-c.so
    

    Otherwise it could be an incompatibility between GCC 3.2.3 and the linker/binutils on your system ... seems unlikely though.

    Best regards,
    Bernard
  • Hi Bernard,

    Our building problems are solved now. It turned out the we had not compiler the xercesc library properly.

    Now everything builds and runs too.

    Thanks for you help.

    Albert