FreeOrion

Forums for the FreeOrion project
It is currently Thu Dec 14, 2017 12:37 am

All times are UTC




Post new topic Reply to topic  [ 13 posts ] 
Author Message
PostPosted: Sun May 24, 2015 9:57 pm 
Offline
Dyson Forest

Joined: Sun May 11, 2008 10:50 am
Posts: 231
Quote:
[chris@desk build]$ make -j1 -k
Writing file: util/Version.cpp
Building v0.4.4+ build 2015-05-24.b39cbba
[ 0%] Built target freeorionversion
Scanning dependencies of target freeorioncommon
[ 0%] Building CXX object CMakeFiles/freeorioncommon.dir/combat/CombatEvent.cpp.o
In file included from /home/chris/freeorion-workspace/freeorion.git/combat/../util/Serialize.ipp:16:0,
from /home/chris/freeorion-workspace/freeorion.git/combat/CombatEvent.cpp:7:
/usr/include/boost/serialization/deque.hpp: In Funktion »void boost::serialization::load(Archive&, std::deque<U, Allocator>&, unsigned int)«:
/usr/include/boost/serialization/deque.hpp:48:27: Fehler: »library_version_type« in Namensbereich »boost::archive« bezeichnet keinen Typ
const boost::archive::library_version_type library_version(
^
/usr/include/boost/serialization/deque.hpp:55:8: Fehler: »library_version_type« ist kein Element von »boost::archive«
if(boost::archive::library_version_type(3) < library_version){
^
/usr/include/boost/serialization/deque.hpp:55:50: Fehler: »library_version« wurde in diesem Gültigkeitsbereich nicht definiert
if(boost::archive::library_version_type(3) < library_version){
^
CMakeFiles/freeorioncommon.dir/build.make:54: die Regel für Ziel „CMakeFiles/freeorioncommon.dir/combat/CombatEvent.cpp.o“ scheiterte
make[2]: *** [CMakeFiles/freeorioncommon.dir/combat/CombatEvent.cpp.o] Fehler 1
[ 1%] Building CXX object CMakeFiles/freeorioncommon.dir/combat/CombatEvents.cpp.o
In file included from /home/chris/freeorion-workspace/freeorion.git/combat/../util/Serialize.ipp:16:0,
from /home/chris/freeorion-workspace/freeorion.git/combat/CombatEvents.cpp:5:
/usr/include/boost/serialization/deque.hpp: In Funktion »void boost::serialization::load(Archive&, std::deque<U, Allocator>&, unsigned int)«:
/usr/include/boost/serialization/deque.hpp:48:27: Fehler: »library_version_type« in Namensbereich »boost::archive« bezeichnet keinen Typ
const boost::archive::library_version_type library_version(
^
/usr/include/boost/serialization/deque.hpp:55:8: Fehler: »library_version_type« ist kein Element von »boost::archive«
if(boost::archive::library_version_type(3) < library_version){
^
/usr/include/boost/serialization/deque.hpp:55:50: Fehler: »library_version« wurde in diesem Gültigkeitsbereich nicht definiert
if(boost::archive::library_version_type(3) < library_version){
^
CMakeFiles/freeorioncommon.dir/build.make:77: die Regel für Ziel „CMakeFiles/freeorioncommon.dir/combat/CombatEvents.cpp.o“ scheiterte
make[2]: *** [CMakeFiles/freeorioncommon.dir/combat/CombatEvents.cpp.o] Fehler 1


Code:
[chris@desk freeorion.git]$ git diff util/Process.h
diff --git a/util/Process.h b/util/Process.h
index f9927cc..f95b5f3 100644
--- a/util/Process.h
+++ b/util/Process.h
@@ -13,6 +13,10 @@
 #if BOOST_VERSION == 105700
 #include <boost/serialization/type_info_implementation.hpp> // This
 #endif
+// HACK: For the same boost 1.58 bug
+#if BOOST_VERSION == 105800
+#include <boost/serialization/type_info_implementation.hpp> // This
+#endif
 
 #include <boost/serialization/shared_ptr.hpp>


So basically I needed the exact same hack as for 1.57 with 1.58 and it seems to work.
Those guys and their includes... unbelievable.

_________________
Attached patches are released under GPL 2.0 or later.


Top
 Profile  
 
PostPosted: Sun May 24, 2015 10:01 pm 
Offline
Programming, Design, Admin
User avatar

Joined: Wed Oct 08, 2003 1:33 am
Posts: 12041
Location: Munich
Perhaps the version check for that include should just be removed entirely?


Top
 Profile  
 
PostPosted: Sun May 24, 2015 10:06 pm 
Offline
AI Lead, Programmer
User avatar

Joined: Sat Sep 22, 2012 6:25 pm
Posts: 4390
Geoff the Medio wrote:
Perhaps the version check for that include should just be removed entirely?
I think that might instead lead to different problems with future Boost versions; I would recommend just doing these for the specific versions where we know they are needed, as we discover it. Now that we know what to check for it is fairly straightforward.

_________________
If I provided any code, scripts or other content here, it's released under GPL 2.0 and CC-BY-SA 3.0


Top
 Profile  
 
PostPosted: Mon May 25, 2015 9:06 am 
Offline
Release Manager, Design
User avatar

Joined: Wed Nov 16, 2011 12:56 pm
Posts: 4289
Location: Sol III
Chriss wrote:
Those guys and their includes... unbelievable.
Ok, this is getting truly weird... what's going on over there? I assume this bug must have been reported over and over now, what's keeping them from fixing it?


Top
 Profile  
 
PostPosted: Mon May 25, 2015 12:18 pm 
Offline
Dyson Forest

Joined: Sun May 11, 2008 10:50 am
Posts: 231
http://imgur.com/gallery/HTisMpC ? ;)

Anyway... I'm trying to narrow it down, had some issues earlier and ended up fixing my boost install because it started to annoy me... That hack above didn't help, didn't know where to hack it otherwise...

_________________
Attached patches are released under GPL 2.0 or later.


Top
 Profile  
 
PostPosted: Mon May 25, 2015 1:07 pm 
Offline
Release Manager, Design
User avatar

Joined: Wed Nov 16, 2011 12:56 pm
Posts: 4289
Location: Sol III
Chriss wrote:
http://imgur.com/gallery/HTisMpC ? ;)
:lol: :lol: :lol: :lol: :lol:
Quote:
That hack above didn't help, didn't know where to hack it otherwise...
Wait, you mean, our hack to work around the problem for boost versions prior to 1.58 doesn't work for 1.58 anymore? So, instead of getting better, or at least stay as it is, things are getting worse now?

Wow... just wow... *facepalm*


Top
 Profile  
 
PostPosted: Mon May 25, 2015 1:44 pm 
Offline
AI Lead, Programmer
User avatar

Joined: Sat Sep 22, 2012 6:25 pm
Posts: 4390
there is another recent thread about some folks having trouble with boost 1.58 and missing includes. You might want to look for that, I seem to recall there were multiple people & some needed different resolutions than the others, and I'm not sure it all made it into the master branch.

_________________
If I provided any code, scripts or other content here, it's released under GPL 2.0 and CC-BY-SA 3.0


Top
 Profile  
 
PostPosted: Mon May 25, 2015 2:17 pm 
Offline
Dyson Forest

Joined: Sun May 11, 2008 10:50 am
Posts: 231
For me, regarding the missing include(s) in boost 1.58, I added the following hack:
Code:
[chris@desk freeorion.git]$ git diff util/Serialize.ipp
diff --git a/util/Serialize.ipp b/util/Serialize.ipp
index b4027b2..c230721 100644
--- a/util/Serialize.ipp
+++ b/util/Serialize.ipp
@@ -5,12 +5,19 @@
 #include <boost/static_assert.hpp>
 #include <boost/detail/endian.hpp>
 
+#include <boost/version.hpp>
 #if BOOST_VERSION == 105600
 // HACK: The following two includes work around a bug in boost 1.56,
 // which uses them without including. They can be removed once the bug is gone.
 #include <boost/serialization/singleton.hpp> // This
 #include <boost/serialization/extended_type_info.hpp> //This
 #endif
+// HACK: For a similar boost 1.58 bug
+#if BOOST_VERSION == 105800
+#include <boost/serialization/type_info_implementation.hpp> // This
+#include <boost/archive/basic_archive.hpp> // And this
+#endif
+
 
 #include <boost/serialization/export.hpp>
 #include <boost/serialization/deque.hpp>


It is necessary to add both includes. No hack in Process.h (tried that, did not help, was not in the error message, too).

_________________
Attached patches are released under GPL 2.0 or later.


Top
 Profile  
 
PostPosted: Mon May 25, 2015 2:22 pm 
Offline
Dyson Forest

Joined: Sun May 11, 2008 10:50 am
Posts: 231
Vezzra wrote:
Wait, you mean, our hack to work around the problem for boost versions prior to 1.58 doesn't work for 1.58 anymore?

I first tried to copy the 1.57 hack so that it is active for 1.58 too, but that did not change the situation. So it seems to be another issue in 1.58 than in 1.57, and the issue in 1.57 is gone.

_________________
Attached patches are released under GPL 2.0 or later.


Top
 Profile  
 
PostPosted: Sat May 30, 2015 12:00 pm 
Offline
Space Floater
User avatar

Joined: Tue May 05, 2015 10:38 am
Posts: 18
Chriss wrote:
Vezzra wrote:
Wait, you mean, our hack to work around the problem for boost versions prior to 1.58 doesn't work for 1.58 anymore?

I first tried to copy the 1.57 hack so that it is active for 1.58 too, but that did not change the situation. So it seems to be another issue in 1.58 than in 1.57, and the issue in 1.57 is gone.


The hack actually works on my case. Also you need to add these options at your CMakeCache.txt or with ccmake ,

Quote:
With ccmake
CMAKE_CXX_FLAGS -DBOOST_VERSION=105800
CMAKE_C_FLAGS -DBOOST_VERSION=105800


Quote:
Or modify CMakeCache.txt,
CMAKE_CXX_FLAGS:STRING=-DBOOST_VERSION=105800
CMAKE_C_FLAGS:STRING=-DBOOST_VERSION=105800


Without above options the hacked block of #IF #ELSE are not executed.


Top
 Profile  
 
PostPosted: Sat May 30, 2015 6:25 pm 
Offline
AI Lead, Programmer
User avatar

Joined: Sat Sep 22, 2012 6:25 pm
Posts: 4390
adesst wrote:
Also you need to add these options at your CMakeCache.txt or with ccmake ,

Quote:
With ccmake
CMAKE_CXX_FLAGS -DBOOST_VERSION=105800
CMAKE_C_FLAGS -DBOOST_VERSION=105800


Quote:
Or modify CMakeCache.txt,
CMAKE_CXX_FLAGS:STRING=-DBOOST_VERSION=105800
CMAKE_C_FLAGS:STRING=-DBOOST_VERSION=105800


Without above options the hacked block of #IF #ELSE are not executed.
That should not be the case, the value should be set by including the header boost/version.hpp-- was there some file where it is needed but missing?

_________________
If I provided any code, scripts or other content here, it's released under GPL 2.0 and CC-BY-SA 3.0


Top
 Profile  
 
PostPosted: Sun May 31, 2015 8:39 pm 
Offline
Dyson Forest

Joined: Sun May 11, 2008 10:50 am
Posts: 231
Yes, see:
Already had a Hack for 1.57, but no version.h

Chriss wrote:
For me, regarding the missing include(s) in boost 1.58, I added the following hack:
Code:
[chris@desk freeorion.git]$ git diff util/Serialize.ipp
diff --git a/util/Serialize.ipp b/util/Serialize.ipp
index b4027b2..c230721 100644
--- a/util/Serialize.ipp
+++ b/util/Serialize.ipp
@@ -5,12 +5,19 @@
 #include <boost/static_assert.hpp>
 #include <boost/detail/endian.hpp>
 
+#include <boost/version.hpp>
 #if BOOST_VERSION == 105600
 // HACK: The following two includes work around a bug in boost 1.56,
 // which uses them without including. They can be removed once the bug is gone.
 #include <boost/serialization/singleton.hpp> // This
 #include <boost/serialization/extended_type_info.hpp> //This
 #endif
+// HACK: For a similar boost 1.58 bug
+#if BOOST_VERSION == 105800
+#include <boost/serialization/type_info_implementation.hpp> // This
+#include <boost/archive/basic_archive.hpp> // And this
+#endif
+
 
 #include <boost/serialization/export.hpp>
 #include <boost/serialization/deque.hpp>


It is necessary to add both includes. No hack in Process.h (tried that, did not help, was not in the error message, too).

_________________
Attached patches are released under GPL 2.0 or later.


Top
 Profile  
 
PostPosted: Mon Jun 01, 2015 3:32 pm 
Offline
Space Floater
User avatar

Joined: Tue May 05, 2015 10:38 am
Posts: 18
Chriss wrote:
Yes, see:
Already had a Hack for 1.57, but no version.h

Chriss wrote:
For me, regarding the missing include(s) in boost 1.58, I added the following hack:
Code:
[chris@desk freeorion.git]$ git diff util/Serialize.ipp
diff --git a/util/Serialize.ipp b/util/Serialize.ipp
index b4027b2..c230721 100644
--- a/util/Serialize.ipp
+++ b/util/Serialize.ipp
@@ -5,12 +5,19 @@
 #include <boost/static_assert.hpp>
 #include <boost/detail/endian.hpp>
 
+#include <boost/version.hpp>
 #if BOOST_VERSION == 105600
 // HACK: The following two includes work around a bug in boost 1.56,
 // which uses them without including. They can be removed once the bug is gone.
 #include <boost/serialization/singleton.hpp> // This
 #include <boost/serialization/extended_type_info.hpp> //This
 #endif
+// HACK: For a similar boost 1.58 bug
+#if BOOST_VERSION == 105800
+#include <boost/serialization/type_info_implementation.hpp> // This
+#include <boost/archive/basic_archive.hpp> // And this
+#endif
+
 
 #include <boost/serialization/export.hpp>
 #include <boost/serialization/deque.hpp>


It is necessary to add both includes. No hack in Process.h (tried that, did not help, was not in the error message, too).


Sorry i did not carefully read Chriss previous post. That he did add the version.hpp so no need to add the build options.

@Dilvish, i am catching up with boost and thanks for the link.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 13 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group