OpenXcom Forum
Contributions => Programming => Topic started by: RogerBennett on February 13, 2016, 04:33:23 pm
-
Guys, I've had to include <algorithm> to a bunch of files for min, max, transform, foreach.
Have I missed a trick?
How does this work for anybody else?
-
I guess it's because you are using a more recent version of yaml-cpp than the devs.
-
OK
I must have missed the instructions
I grabbed from here
https://github.com/jbeder/yaml-cpp
Is there a fixed version for YAML, and for SDL, SDL_mixer, SDL_image and SDL_gfx I should be using?
Once I got all those built, I get an YAML unresolved external, so I was pretty sure I had the wrong version and/or a header/library mismatch.
-
The standard version of a fresh yaml-cpp clone (which defaults to "master") needs C++11, OXC is not fully compatible with that version (if i understood the forum posts correct).
You will need to checkout a tagged commit before building your yaml version:
git checkout release-0.5.3
You can opt for older versions .. as long as you treat 0.5.2 as a primed proximity grenade ;)
Good luck
-
Aces thanks.
cmake 0.5.3 gives me boost errors, so I'll work through those and carry on trying. I can't be too far off.
-
You are getting close indeed.
According to the linux part of the build instructions (https://www.ufopaedia.org/index.php?title=Compiling_%28OpenXcom%29) libboost and xmlto are also needed.
And unless you want to do some work on SDL2 compatibility it is wise to use the 1.2 versions of the SDL libs.
-
Thanks for the encouragement.
If SDL 1.2.* is sufficient then I should be fine then. I'll read the SDL2 specifications and check there is nothing there I'm going to need, as far as I know I'll be fine. The 1.2 spec looks like it has enough input, timing, and OpenGL is already an option so I'll be fine on that side.
FYI - That build instructions link doesn't open for me. I just get a database error for everything from https://www.ufopaedia.org/
My problem is Yaml-CPPs CMake is missing a path to my boost libs - I just need to learn where to set BOOST_ROOT and I could be golden.
-
FYI - That build instructions link doesn't open for me. I just get a database error for everything from https://www.ufopaedia.org/
Oh yes apparently the website is down for the moment. Meanwhile you could try using the cached versions of your favorite search engine.
My problem is Yaml-CPPs CMake is missing a path to my boost libs - I just need to learn where to set BOOST_ROOT and I could be golden.
Hmm, i am not sure which OS you are using, but in my case installing boost was enough to make it visible to YAML-CPP (did you forget to rerun CMake to make it pickup the new libraries?)
-
Thanks!
I got boost and yaml-cpp to build, but following an unresolved external in yaml::node while linking OpenXcom I decided to download the prebuilt libs.
I'm building for Win32.
I kind of feel like I've failed at the first hurdle, but at least I can write code and run the game which is all I was after. My Algorithm #include was caused by a mismatch in my yaml-cpp version.
Either way, I'm up and running. I didn't get time to write any features yet but I'll post a separate thread.
Cheers.
-
`yaml::node` is trash that you should ignore. Recent yaml-cpp commit removed it.