Hi,
can anybody tell me what __pei386_runtime_relocator does/is supposed to do?
The boost regex dll segfaults on process attach within DllMain, or __pei386_runtime_relocator+0x1f to be exact. I'm running out of clues...
https://bugzilla.redhat.com/show_bug.cgi?id=654424
NB: I've privately built boost 1.44, it segfaults as well...
Tom
2010/11/18 Thomas Sailer sailer@sailer.dynip.lugs.ch:
Hi,
can anybody tell me what __pei386_runtime_relocator does/is supposed to do?
The boost regex dll segfaults on process attach within DllMain, or __pei386_runtime_relocator+0x1f to be exact. I'm running out of clues...
https://bugzilla.redhat.com/show_bug.cgi?id=654424
NB: I've privately built boost 1.44, it segfaults as well...
Tom
mingw mailing list mingw@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/mingw
Hello,
the function '__pei386_runtime_relocator' is a startup callback, which does the pseudo-relocation (generated by ld) on startup of a gnu-compiled windows application. There are two different formats present for pseudo-relocations. The old version (v1) and the newer one (v2 - which became default for newer ld). So please check what binutils version you are using and if the runtime-version is recent enough.
Best regards, Kai
Hi Kai,
thanks for you answer!
I first used a fully uptodate Fedora14 system: mingw32-binutils-2.20.1-1.fc14.x86_64 mingw32-runtime-3.15.2-5.fc13.noarch
Then I manually upgraded binutils: mingw32-binutils-2.20.51.0.10-1.fc14.x86_64
Both configurations resulted in segfaulting boost regex dlls.
Is there documentation on these two binary formats? Or is there a better way to better localize the problem?
Thanks, Tom
2010/11/21 Thomas Sailer t.sailer@alumni.ethz.ch:
Hi Kai,
thanks for you answer!
I first used a fully uptodate Fedora14 system: mingw32-binutils-2.20.1-1.fc14.x86_64 mingw32-runtime-3.15.2-5.fc13.noarch
Then I manually upgraded binutils: mingw32-binutils-2.20.51.0.10-1.fc14.x86_64
Both configurations resulted in segfaulting boost regex dlls.
Is there documentation on these two binary formats? Or is there a better way to better localize the problem?
Thanks, Tom
Hello Tom,
I am not sure if 3.15.2-5 already has support for v2 pseudo-relocations, but binutils 2.20.51 has it. So maybe try to specify the additional linker option '--enable-runtime-pseudo-reloc-v1' on dll generation. By this you can enforce that ld generates the old relocation information.
I hope this switch soilves you problem.
Best regards, Kai
Hi Kai,
I am not sure if 3.15.2-5 already has support for v2
Apparently not.
pseudo-relocations, but binutils 2.20.51 has it. So maybe try to specify the additional linker option '--enable-runtime-pseudo-reloc-v1' on dll generation. By this you can enforce that ld generates the old relocation information.
That did it - but only if I relink both the DLL _and_ the main program with --enable-runtime-pseudo-reloc-v1.
Specifically: DLL: /usr/bin/i686-pc-mingw32-g++ -Wl,--enable-runtime-pseudo-reloc-v1 -Wl,--enable-auto-import -shared -o ../../../bin/boost_regex-gcc45-d-1_44.dll -Wl,--out-implib,../../../lib/libboost_regex-gcc45-d-1_44.dll.a -Wl,--major-image-version,0,--minor-image-version,0 -Wl,@CMakeFiles/boost_regex-shared-debug.dir/objects1.rsp -lkernel32 -luser32 -lgdi32 -lwinspool -lshell32 -lole32 -loleaut32 -luuid -lcomdlg32 -ladvapi32
Main Program: i686-pc-mingw32-g++ -O2 -g -pipe -Wall -fexceptions -mms-bitfields test.cpp -o test.exe ./libboost_regex-gcc45-d-1_44.dll.a -lkernel32 -Wl,--enable-runtime-pseudo-reloc-v1
Thanks again, Tom