SFML community forums

Help => General => Topic started by: cristaloleg on May 05, 2013, 05:08:19 pm

Title: Problem with compiling SFML project in 2008
Post by: cristaloleg on May 05, 2013, 05:08:19 pm
Ok, I have created SFML solution 2008 with CMake. Now I want to build it, but I get errors like this:

Error   25   error LNK2019: unresolved external symbol __imp__glEnable@4 referenced in function "private: void __thiscall sf::priv::GlContext::initialize(void)" (?initialize@GlContext@priv@sf@@AAEXXZ)   GlContext.obj   sfml-window

and so on. I understand that it can't find external libraries, but how can I fix this?

full build log:
http://pastebin.com/M1m24hMY (http://pastebin.com/M1m24hMY)

Thank's for help.
PS Windows 7 x64(but I'm using SFML for x32 platform), CMake 2.8.10.2, latest SFML source,
Title: Re: Problem with compiling SFML project in 2008
Post by: Laurent on May 05, 2013, 07:21:33 pm
Why don't you use the 2.0 precompiled binaries?
Title: Re: Problem with compiling SFML project in 2008
Post by: cristaloleg on May 06, 2013, 07:25:52 am
After finding this ticket for testing idea CDS_RESET
https://github.com/SFML/SFML/issues/306 (https://github.com/SFML/SFML/issues/306)

BTW: I have finished building with CMake for Visual Studio 2012, but I had some problems because I didn't run CMake with admininistrator permission, maybe adding this hint in tutorial would be very nice. =)
http://www.sfml-dev.org/tutorials/2.0/compile-with-cmake.php (http://www.sfml-dev.org/tutorials/2.0/compile-with-cmake.php)
Title: Re: Problem with compiling SFML project in 2008
Post by: Laurent on May 06, 2013, 07:53:07 am
You don't need to run CMake with admin privileges.
Title: Re: Problem with compiling SFML project in 2008
Post by: cristaloleg on May 06, 2013, 07:56:00 am
But without admin privileges it doesn't found that I have Visual Studio 11 compiler. Sounds weird but it is a fact.
Title: Re: Problem with compiling SFML project in 2008
Post by: Laurent on May 06, 2013, 07:58:59 am
There's something wrong in your environment. Maybe you installed VS in a directory that requires admin priviledges to be accessed.
Title: Re: Problem with compiling SFML project in 2008
Post by: cristaloleg on May 06, 2013, 08:02:15 am
I installed by default in "Program Files (x86)". Everything in installation was default too.

offtop: check my solution https://github.com/SFML/SFML/issues/306 (https://github.com/SFML/SFML/issues/306) =)
Title: Re: Problem with compiling SFML project in 2008
Post by: Laurent on May 06, 2013, 08:52:28 am
Where did you choose to create the build tree, and what was the exact error message?
Title: Re: Problem with compiling SFML project in 2008
Post by: cristaloleg on May 06, 2013, 02:06:34 pm
Error about unsupported architecture: http://pastebin.com/ZqkFxWNh (http://pastebin.com/ZqkFxWNh)
As I said running as administrator solves this problem.
Title: AW: Problem with compiling SFML project in 2008
Post by: eXpl0it3r on May 06, 2013, 02:14:38 pm
Have you tried reinstalling CMake?
Sometimes it gets screwed up. ;)
Title: Re: Problem with compiling SFML project in 2008
Post by: cristaloleg on May 06, 2013, 02:28:55 pm
I already seen before your advices about reinstall in another threads, but it didn't work for me.
This is weird, anyway.