Hello,
I am trying to compile Xerces-C 3.1.1 using MinGW.
I am following the build instructions at
http://xerces.apache.org/xerces-c/build-3.html
The instruction says I must do: ./configure LDFLAGS=-no-undefined
However, it seems that GCC 4.6.0 and later fail when this option is given. Below
is the relevent section from my config.log.
Does anyone know how I should proceed to build XercesC using this version of GCC
in MinGW?
With Kind Regards,
Martin Brentnall
--------------
[snip]
configure:3699: checking for C++ compiler version
configure:3708: g++ --version >&5
g++.exe (GCC) 4.6.1
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
configure:3719: $? = 0
configure:3708: g++ -v >&5
Using built-in specs.
COLLECT_GCC=d:\mingw\bin\g++.exe
COLLECT_LTO_WRAPPER=d:/mingw/bin/../libexec/gcc/mingw32/4.6.1/lto-wrapper.exe
Target: mingw32
Configured with: ../gcc-4.6.1/configure
--enable-languages=c,c++,fortran,objc,obj-c++ --disable-sjlj-exceptions
--with-dwarf2 --enable-shared --enable-libgomp --disable-win32-registry
--enable-libstdcxx-debug --enable-version-specific-runtime-libs --build=mingw32
--prefix=/mingw
Thread model: win32
gcc version 4.6.1 (GCC)
configure:3719: $? = 0
configure:3708: g++ -V >&5
g++.exe: error: unrecognized option '-V'
g++.exe: fatal error: no input files
compilation terminated.
configure:3719: $? = 1
configure:3708: g++ -qversion >&5
g++.exe: error: unrecognized option '-qversion'
g++.exe: fatal error: no input files
compilation terminated.
configure:3719: $? = 1
configure:3741: checking for C++ compiler default output file name
configure:3763: g++ -no-undefined conftest.cpp >&5
g++.exe: error: unrecognized option '-no-undefined'
configure:3767: $? = 1
configure:3804: result:
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "xerces-c"
| #define PACKAGE_TARNAME "xerces-c"
| #define PACKAGE_VERSION "3.1.1"
| #define PACKAGE_STRING "xerces-c 3.1.1"
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE_URL ""
| #define PACKAGE "xerces-c"
| #define VERSION "3.1.1"
| /* end confdefs.h. */
| #include <stdio.h>
| int
| main ()
| {
| FILE *f = fopen ("conftest.out", "w");
| return ferror (f) || fclose (f) != 0;
|
| ;
| return 0;
| }
configure:3810: error: in `/xerces':
configure:3814: error: C++ compiler cannot create executables
See `config.log' for more details.
[snip]