Hi,
I'm trying to cross-compile gnomemeeting for win32 for mingw (native compiling with mingw works now).
I can cross-compile pwlib without problem, but when I try to compile the sample/hello_world program, I get a problem that I think isn't pwlib-specific, but more probably a mingw32-binutils issue. Especially the fact that an assertion fails and ld/collect2 segfaults is impressive.
Here is the log of the failed link :
i586-mingw32msvc-c++ -o obj_mingw_x86_r/hello -I/home/jpuydt/Gnomemeeting/Cross/windows/include -L/home/jpuydt/Gnomemeeting/Cross/windows/lib -L/home/jpuydt/Gnomemeeting/Cross/windows/lib -enable-auto-import -enable-runtime-pseudo-reloc -enable-stdcall-fixup -fatal-warning -L/home/jpuydt/Gnomemeeting/Cross/pwlib//lib
./obj_mingw_x86_r/hello.o -lpt_mingw_x86_r -lldap -lldap_r -llber -lwinmm -lwsock32 -lsnmpapi -lmpr -lcomdlg32 -lgdi32 -lavicap32 -lregex
collect2: ld terminated with signal 11 [Segmentation fault]
/home/jpuydt/Gnomemeeting/Cross/pwlib//lib/libpt_mingw_x86_r.dll(.text+0x100): In function `atexit':
/build/buildd/mingw32-runtime-3.7/build_dir/src/mingw-runtime-3.7/dllcrt1.c:161: multiple definition of `_atexit'
/usr/lib/gcc/i586-mingw32msvc/3.4.2/../../../../i586-mingw32msvc/lib/crt2.o(.text+0x210):/build/buildd/mingw32-runtime-3.7/build_dir/src/mingw-runtime-3.7/crt1.c:250: first defined here
/home/jpuydt/Gnomemeeting/Cross/pwlib//lib/libpt_mingw_x86_r.dll(.text+0x130): In function `_onexit':
/build/buildd/mingw32-runtime-3.7/build_dir/src/mingw-runtime-3.7/dllcrt1.c:177: multiple definition of `__onexit'
/usr/lib/gcc/i586-mingw32msvc/3.4.2/../../../../i586-mingw32msvc/lib/crt2.o(.text+0x220):/build/buildd/mingw32-runtime-3.7/build_dir/src/mingw-runtime-3.7/crt1.c:258: first defined here
/home/jpuydt/Gnomemeeting/Cross/pwlib//lib/libpt_mingw_x86_r.dll(.text+0x150): In function `_onexit':
/build/buildd/mingw32-runtime-3.7/build_dir/src/mingw-runtime-3.7/dllcrt1.c:183: multiple definition of `___do_sjlj_init'
/usr/lib/gcc/i586-mingw32msvc/3.4.2/crtbegin.o(.text+0x0): first defined here
/home/jpuydt/Gnomemeeting/Cross/pwlib//lib/libpt_mingw_x86_r.dll(.rdata+0x183d8): In function `_onexit':
/build/buildd/mingw32-runtime-3.7/build_dir/src/mingw-runtime-3.7/dllcrt1.c:183: multiple definition of `typeinfo for PThread'
./obj_mingw_x86_r/hello.o(.rdata$_ZTI7PThread[typeinfo for PThread]+0x0):hello.cxx: first defined here
/home/jpuydt/Gnomemeeting/Cross/pwlib//lib/libpt_mingw_x86_r.dll(.rdata+0x18548): In function `_onexit':
/build/buildd/mingw32-runtime-3.7/build_dir/src/mingw-runtime-3.7/dllcrt1.c:183: multiple definition of `typeinfo for PProcess'
./obj_mingw_x86_r/hello.o(.rdata$_ZTI8PProcess[typeinfo for PProcess]+0x0):hello.cxx: first defined here
/home/jpuydt/Gnomemeeting/Cross/pwlib//lib/libpt_mingw_x86_r.dll(.rdata+0x1bb64): In function `_onexit':
/build/buildd/mingw32-runtime-3.7/build_dir/src/mingw-runtime-3.7/dllcrt1.c:183: multiple definition of `typeinfo name for PProcess'
./obj_mingw_x86_r/hello.o(.rdata$_ZTS8PProcess[typeinfo name for PProcess]+0x0):hello.cxx: first defined here
/home/jpuydt/Gnomemeeting/Cross/pwlib//lib/libpt_mingw_x86_r.dll(.rdata+0x183b8): In function `_onexit':
/build/buildd/mingw32-runtime-3.7/build_dir/src/mingw-runtime-3.7/dllcrt1.c:183: multiple definition of `typeinfo for PObject'
./obj_mingw_x86_r/hello.o(.rdata$_ZTI7PObject[typeinfo for PObject]+0x0):hello.cxx: first defined here
/home/jpuydt/Gnomemeeting/Cross/pwlib//lib/libpt_mingw_x86_r.dll(.rdata+0x1b8b0): In function `_onexit':
/build/buildd/mingw32-runtime-3.7/build_dir/src/mingw-runtime-3.7/dllcrt1.c:183: multiple definition of `typeinfo name for PThread'
./obj_mingw_x86_r/hello.o(.rdata$_ZTS7PThread[typeinfo name for PThread]+0x0):hello.cxx: first defined here
/home/jpuydt/Gnomemeeting/Cross/pwlib//lib/libpt_mingw_x86_r.dll(.rdata+0x1b88c): In function `_onexit':
/build/buildd/mingw32-runtime-3.7/build_dir/src/mingw-runtime-3.7/dllcrt1.c:183: multiple definition of `typeinfo name for PObject'
./obj_mingw_x86_r/hello.o(.rdata$_ZTS7PObject[typeinfo name for PObject]+0x0):hello.cxx: first defined here
/usr/lib/gcc/i586-mingw32msvc/3.4.2/../../../../i586-mingw32msvc/bin/ld: BFD 2.15.91 20040904 assertion fail /build/buildd/mingw32-binutils-2.15.91.20040904.1/build_dir/src/binutils-2.15.91-20040904-1/bfd/cofflink.c:1929
make: *** [obj_mingw_x86_r/hello] Error 1
Let me add I use package version 2.15.91.20040904.1-1, with apt-cache policy saying it comes from http://archive.ubuntu.com breezy/universe Packages...
Is there hope ?
Snark on #gnomemeeting
Does this problem still exist with the latest version?