This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
The shared libraries can't work correctly in GCC 4.0.0 with MingW32
- From: heromyth <zxpmyth at yahoo dot com dot cn>
- To: gcc-help at gcc dot gnu dot org
- Date: Sun, 08 May 2005 10:25:01 +0800
- Subject: The shared libraries can't work correctly in GCC 4.0.0 with MingW32
I have compiled GCC 4.0.0 with MingW32, and use it to compile STLport
CVS Libraries. I got a shared library and a static one. There is no
problem in compiling and linking my code with the static library. And
the EXE file works perfectly. When using the shared library instead, I
got a EXE file which can't work. Running it, show belown:
terminate called after throwing an instance of 'std::bad_cast'
what(): St8bad_cast
abnormal program termination
Also, I can't compiled wxWidget 2.6.0 shared libraries. There is no
problem in compiling and linking all the libraries with GCC 3.4.2, and
these libraries work well. What's wrong with these. I am lost! I
compiled GCC 4.0.0 like this:
E:\>g++ -v
Using built-in specs.
Target: mingw32
Configured with: ../gcc-4.0.0/configure --with-gcc --with-gnu-ld
--with-gnu-as --host=mingw32 --target=mingw32 --prefix=/mingw
-enable-threads --enable-languages=c,c++ --disable-win32-registry
--disable-shared --enable-sjlj-exceptions --disable-java-awt --without-x
--enable-interpreter --enable-hash-synchronization --enable-libstdcxx-debug
Thread model: win32
gcc version 4.0.0