Trying to merge SFML and BOX2D with Eclipse

Started by
6 comments, last by DejaimeNeto 9 years, 11 months ago

Hello Everyone

Like the Titel says, im trying to make that SFML combined with BOX2D works on Eclipse. I already managed to make SFML work on Eclipse but i haven't found anyway to combine BOX2D with it aswell. I been looking around forums and google in generall to see if there is something i could use. Sadly many don't seem to enjoy working with Eclipse so it makes it even harder to find something. If someone could help me with the setup of BOX2D i would be very gratefull about that.

If your asking yourself why exactly eclipse and not Microsoft Visuall C++ or any other C++ compiler, il explain it gladly. Since im working in a webdesign company and mostly comfronted with PHP. I was given the task to use Eclipse to program certain things in our CMS with Eclipse. Eclipse is also good since we work combined and use SVN to commit our projects to the server.

Im thankfull for any feedback

Yours Truely

Advertisement

http://stackoverflow.com/questions/3219171/c-how-to-link-a-library-located-in-my-project-folder

http://adventuresinandroidland.blogspot.ro/2011/06/box2d-and-eclipse.html

"Don't gain the world and lose your soul. Wisdom is better than silver or gold." - Bob Marley

Thank you for the feedback

I'm gonna try it and report if theirs any kind of issue or problem

Sorry for the double post. But tried what was explained on the post. I still haven't achieved to make it work on eclipse. I keep messing up the Cmake part.

Any advice on that?

The Error Message from Cmake:

CMake Error: CMake was unable to find a build program corresponding to "MinGW Makefiles". CMAKE_MAKE_PROGRAM is not set. You probably need to select a different build tool.

CMake Error: CMake was unable to find a build program corresponding to "MinGW Makefiles". CMAKE_MAKE_PROGRAM is not set. You probably need to select a different build tool.

CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_C_COMPILER_ENV_VAR

CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_C_COMPILER

CMake Error: Could not find cmake module file: S:/Box2D_v2.3.0/Box2D/Build/CMakeFiles/2.8.12.2/CMakeCCompiler.cmake

CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_CXX_COMPILER_ENV_VAR

CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_CXX_COMPILER

CMake Error: Could not find cmake module file: S:/Box2D_v2.3.0/Box2D/Build/CMakeFiles/2.8.12.2/CMakeCXXCompiler.cmake

CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage

CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage

Configuring incomplete, errors occurred!

Yes. Describe what exactly you did and what error messages you are getting. The description "keep messing up" is useless without a crystal ball.

Yes. Describe what exactly you did and what error messages you are getting. The description "keep messing up" is useless without a crystal ball.

Sorry i edited my previous reply. There you can see the Error message. I tried to aim my Cmake to the build folder in Box2D and tried to Configure on Eclipse CDT4

CMake cannot locate your compiler. Either make sure the default environment variables are set or point CMAKE_MAKE_PROGRAM manually to the full path to your compiler's make utility.
SFML and Box2D are two completely independent libraries; you are able to use both without one interfering with the other in any level.
This means that if you can use them separately, you can use them together with no problem.

You'll need to get the binary files, either by downloading them directly or compiling them yourself.
iirc, there are no official binaries available for download on Box2D's project site, but it should be easy to find a build guide on the web with something like "Box2D Build MinGW".

Now fixing these missing internal environment variables is highly dependent on your system.

At some point, the CMake should test for a working compiler, as below.
In this case, the compiler was found under 'C:/MinGW/bin' :
imagem.PNG

Keep an eye out for this error here:
imagem.PNG

If you spot this one, you should add MinGW to your windows' environment variables.
Actually, I add both MinGW bin and CMake to my env variables, personally.

This topic is closed to new replies.

Advertisement