Cross Building (Protobuf)

For all the help you need with Armagetron!
Post Reply
User avatar
Light
Reverse Outside Corner Grinder
Posts: 1664
Joined: Thu Oct 20, 2011 2:11 pm

Cross Building (Protobuf)

Post by Light »

I'm assuming my issue is with protobuf, but I can't seem to get it. I tried the package provided in Ubuntu 15.10, which I know has often failed. I went and grabbed from git, installed it to /usr and same failure. Again with /usr/local (default location) with the same failure once again. Below is my last attempt with it in /usr/local.

It has been some times since I had to set this up, but if I remember correctly, there was an .so file I needed to symlink somewhere?

Build attempt is for Windows, cross building from Linux.

// Edit: I should mention that the winlibs protobuf source and bin file exist in the proper location. Pretty sure without that it would have failed much sooner? Guess I could be wrong.

Code: Select all

..\..\..\winlibs\win32\boost_libs\libboost_thread-mgw47-mt-1_53.a(thread.o): duplicate section `.rdata$_ZTVN5boost16exception_detail10clone_implINS0_19error_info_injectorINS_21thread_resource_errorEEEEE[__ZTVN5boost16exception_detail10clone_implINS0_19error_info_injectorINS_21thread_resource_errorEEEEE]' has different size
..\..\..\winlibs\win32\boost_libs\libboost_thread-mgw47-mt-1_53.a(thread.o): duplicate section `.rdata$_ZTVN5boost16exception_detail10clone_implINS0_19error_info_injectorINS_10lock_errorEEEEE[__ZTVN5boost16exception_detail10clone_implINS0_19error_info_injectorINS_10lock_errorEEEEE]' has different size
..\..\..\winlibs\win32\boost_libs\libboost_thread-mgw47-mt-1_53.a(thread.o): duplicate section `.rdata$_ZTVN5boost16exception_detail10clone_implINS0_19error_info_injectorISt9bad_allocEEEE[__ZTVN5boost16exception_detail10clone_implINS0_19error_info_injectorISt9bad_allocEEEE]' has different size
..\..\..\winlibs\win32\boost_libs\libboost_thread-mgw47-mt-1_53.a(thread.o): duplicate section `.rdata$_ZTSN5boost16exception_detail10clone_implINS0_19error_info_injectorINS_21thread_resource_errorEEEEE[__ZTSN5boost16exception_detail10clone_implINS0_19error_info_injectorINS_21thread_resource_errorEEEEE]' has different size
..\..\..\winlibs\win32\boost_libs\libboost_thread-mgw47-mt-1_53.a(thread.o): duplicate section `.rdata$_ZTSN5boost16exception_detail10clone_implINS0_19error_info_injectorINS_10lock_errorEEEEE[__ZTSN5boost16exception_detail10clone_implINS0_19error_info_injectorINS_10lock_errorEEEEE]' has different size
..\..\..\winlibs\win32\boost_libs\libboost_thread-mgw47-mt-1_53.a(thread.o): duplicate section `.rdata$_ZTSN5boost16exception_detail10clone_implINS0_19error_info_injectorISt9bad_allocEEEE[__ZTSN5boost16exception_detail10clone_implINS0_19error_info_injectorISt9bad_allocEEEE]' has different size
..\..\..\winlibs\win32\boost_libs\libboost_thread-mgw47-mt-1_53.a(thread.o): duplicate section `.rdata$_ZTSN5boost16exception_detail19error_info_injectorINS_21thread_resource_errorEEE[__ZTSN5boost16exception_detail19error_info_injectorINS_21thread_resource_errorEEE]' has different size
..\..\..\winlibs\win32\boost_libs\libboost_thread-mgw47-mt-1_53.a(thread.o): duplicate section `.rdata$_ZTSN5boost16exception_detail19error_info_injectorINS_10lock_errorEEE[__ZTSN5boost16exception_detail19error_info_injectorINS_10lock_errorEEE]' has different size
..\..\build\tmp\Armagetron_Dedicated___Win32_Release\src\engine\eEventNotification.o:eEventNotification.cpp:(.text+0x209): undefined reference to `google::protobuf::internal::kEmptyString'
..\..\build\tmp\Armagetron_Dedicated___Win32_Release\src\engine\eEventNotification.o:eEventNotification.cpp:(.text+0x230): undefined reference to `google::protobuf::internal::kEmptyString'
C:/Program Files (x86)/CodeBlocks/MinGW/bin/../lib/gcc/mingw32/4.9.2/../../../../mingw32/bin/ld.exe: ..\..\build\tmp\Armagetron_Dedicated___Win32_Release\src\engine\eEventNotification.o: bad reloc address 0x1 in section `.text$_ZNK16nProtoBufMessageIN6Engine17EventNotificationEE20DoAccessWorkProtoBufEv[__ZNK16nProtoBufMessageIN6Engine17EventNotificationEE20DoAccessWorkProtoBufEv]'
C:/Program Files (x86)/CodeBlocks/MinGW/bin/../lib/gcc/mingw32/4.9.2/../../../../mingw32/bin/ld.exe: final link failed: Invalid operation
collect2.exe: error: ld returned 1 exit status
Process terminated with status 1 (10 minute(s), 15 second(s))
3 error(s), 32 warning(s) (10 minute(s), 15 second(s))
fixme:msvcrt:MSVCRT__wsopen_s : pmode 0x81b6 ignored
fixme:msvcrt:MSVCRT__wsopen_s : pmode 0x81b6 ignored
fixme:msvcrt:MSVCRT__wsopen_s : pmode 0x81b6 ignored
fixme:heap:HeapSetInformation 0x110000 0 0x81fc0c 4
fixme:heap:HeapSetInformation 0x16e1000 0 0x81fc0c 4
fixme:heap:HeapSetInformation 0x2c4000 0 0x81fc0c 4
fixme:msvcrt:MSVCRT__wsopen_s : pmode 0x81b6 ignored

User avatar
Lucifer
Project Developer & Local Moonshiner
Posts: 8610
Joined: Sun Aug 15, 2004 3:32 pm
Location: Republic of Texas
Contact:

Re: Cross Building (Protobuf)

Post by Lucifer »

Are you absolutely certain ld isn't trying to link to linux .so files?
Image

Be the devil's own, Lucifer's my name.
- Iron Maiden

User avatar
Light
Reverse Outside Corner Grinder
Posts: 1664
Joined: Thu Oct 20, 2011 2:11 pm

Re: Cross Building (Protobuf)

Post by Light »

Lucifer wrote:Are you absolutely certain ld isn't trying to link to linux .so files?
I don't know, but I was assuming it ended up using both. I'm not sure that really makes sense thinking back on it, but I was thinking the last time I set this up I needed to copy a .so file somewhere to make it work, though I can't remember if that was for the Windows client or Linux client. It does show the path to the winlibs protobuf source earlier in the build, but maybe I need to look a little more into that. I'll put out my log below.

Once I get this builder working again, I have it set up to not break. My goal is to make it work on my server, but I'll worry about that after I get it going again.

Bleh .. Apparently I can't have a 427,984 character post. lol I'm attaching it, which is hopefully okay.
Attachments
buildlog.txt
(417.82 KiB) Downloaded 55 times

User avatar
Z-Man
God & Project Admin
Posts: 11426
Joined: Sun Jan 23, 2005 6:01 pm
Location: Cologne
Contact:

Re: Cross Building (Protobuf)

Post by Z-Man »

Another likely point of failure would me a mismatch between your mingw version and the version the winlibs binaries were built with. The mismatching symbols the linker complains about look like templates two compilers don't agree on. The right compiler version is in the lib name, I can't remember which one of the two.

User avatar
Light
Reverse Outside Corner Grinder
Posts: 1664
Joined: Thu Oct 20, 2011 2:11 pm

Re: Cross Building (Protobuf)

Post by Light »

Z-Man wrote:Another likely point of failure would me a mismatch between your mingw version and the version the winlibs binaries were built with. The mismatching symbols the linker complains about look like templates two compilers don't agree on. The right compiler version is in the lib name, I can't remember which one of the two.
That could be an idea. I'll see about rebuilding them tonight.

User avatar
Lucifer
Project Developer & Local Moonshiner
Posts: 8610
Joined: Sun Aug 15, 2004 3:32 pm
Location: Republic of Texas
Contact:

Re: Cross Building (Protobuf)

Post by Lucifer »

So it would still be an ABI mismatch? ;)
Image

Be the devil's own, Lucifer's my name.
- Iron Maiden

Post Reply