Skip to content
Jebbs edited this page Aug 29, 2013 · 4 revisions

The first step to building DSFML-C is to build SFML static libraries. Currently, DSFML uses SFML 2.0, which you can find the source for here. SFML also has a very good tutorial detailing how to build from source. Make sure you select static libraries!

Once you have built SFML, you need to make sure that CMake knows all about it so that we don't get any problems building DSFML-C. The easiest way is to copy the FindSFML.cmake file from "sfmlSourceDirectory\cmake\Modules" to "CMake 2.8\share\cmake-2.8\Modules" (or what ever version of CMake you happen to be using). Download the source from the DSFML-C repository, an then fire up CMake again.Set up the source code and build directories, and set up your compiler just like when building SFML. Pressing the Configure button should get everything going, and then CMake will say that it needs to know where the SFML include directory is, as well as the SFML static libraries. I'm assuming you are a competent person, but here's an example because I feel like this page needs some pictures.

Finding Everything

Pressing configure again should cause CMake to be happy about the libraries, and it should also find libsndfile and OpenAL. That means we're ready to generate our make files! Press you some Generate button, and then go build yourself a great library.

Clone this wiki locally