> I've tried to do this, and have always had problem getting even Xerces-C to build using that compiler. I'll try again with the latest Solaris distribution and see what happens.
How Xerces-c 2.8 gets built on Solaris 10 64-bit platforms using GCC 3.4.x: Solaris xerces-c-2.8.0/sparc-sun-solaris2.10/GCC 3.4.6 1) Download xerces tar ball, 2) Set XERCESCROOT (export XERCESCROOT=/path/to/xerces-c-src_2_8_0) 3) cd ${XERCESCROOT}/src/xercesc 4) On Solaris, If you are building a 64 bit Xerces-C++ using g++ that by default generated 32 bit code (or vice versa), then you will need to specify additional compiler and linker options via the -z and -l runConfigure options in order to switch the compiler into 64 bit mode (or 32 bit mode). These options are architecture-specific and you may need to consult the GCC manual to determine which ones to use. For the x86-64, and SPARC architectures these options are -m64 (64 bit mode) and -m32 (32 bit mode). Note also that if you are using the packageBinaries.pl script to build Xerces-C++ then you may need to modify this script to pass the necessary options to runConfigure. 5) Configure with (note -z-pthreads is needed because it is not automatically added to the command line. In previous builds this was done by manually editing the Makefile after configuring. -rpthread not -rpthreads because -rpthreads is not recoganized. 6) Configure: ./runConfigure -psolaris -cgcc -xg++ -b64 -l"-m64" -l"-mcpu=v9" -l"-O0" \ -l"-Wa,-xarch=v9" -z"-m64" -z"-mcpu=v9" -z"-O0" -z"-fPIC" -z"-Wa,-xarch=v9" \ -rpthread -z-pthreads 7) Build with: make xerces-c-2.8.0/i386-pc-solaris2.10/GCC 3.4.3 1) Download xerces tar ball, 2) Set XERCESCROOT (export XERCESCROOT=/path/to/xerces-c-src_2_8_0) 3) cd ${XERCESCROOT}/src/xercesc 4) On Solaris, If you are building a 64 bit Xerces-C++ using g++ that by default generated 32 bit code (or vice versa), then you will need to specify additional compiler and linker options via the -z and -l runConfigure options in order to switch the compiler into 64 bit mode (or 32 bit mode). These options are architecture-specific and you may need to consult the GCC manual to determine which ones to use. For the x86-64, and SPARC architectures these options are -m64 (64 bit mode) and -m32 (32 bit mode). Note also that if you are using the packageBinaries.pl script to build Xerces-C++ then you may need to modify this script to pass the necessary options to runConfigure. 5) Configure with (note -z-pthreads is needed because it is not automatically added to the command line. In previous builds this was done by manually editing the Makefile after configuring. -rpthread not -rpthreads because -rpthreads is not recoganized. 6) Configure: ./runConfigure -psolaris -cgcc -xg++ -b64 -l"-m64" -z"-m64" -rpthread -z-pthreads 7) Build with: make -----Original Message----- From: David Bertoni [mailto:dbert...@apache.org] Sent: Monday, March 16, 2009 12:34 PM To: xalan-c-users@xml.apache.org Subject: Re: build Xalan-C using GCC on Solaris x86_64 and Solaris Sparc 64-bit Zhuo Yang wrote: >> I've never seen a version of GCC on Solaris x86 or Solaris SPARC that > could build 64-bit binaries, so I've never tried it. > > GCC compilers that were used for compiling 64-bit binaries: > > - GCC 3.4.6 for Sun Sparc / Solaris 10. > - Download from http://www.sunfreeware.com/indexsparc10.html > - (I think GCC that comes with Solaris 10 in /usr/sfw/bin can > build 64-bit as well.) I don't have any SPARC hardware, so I can't test this. > > - GCC 3.4.3, that comes with Solaris 10 x86 OS installation, can > build 64-bit. > "If you need to do 64-bit compiles, you should use the > gcc-3.4.3 that comes with Solaris 10 in /usr/sfw/bin." (See comments > at http://www.sunfreeware.com/indexintel10.html for > gcc-3.4.6-sol10-x86-local.gz) I've tried to do this, and have always had problem getting even Xerces-C to build using that compiler. I'll try again with the latest Solaris distribution and see what happens. In the meantime, you can try this yourself, by modifying runConfigure to add -m64 to the bitstobuildDefines variable for the Linux platform, and use that to build. Dave