CMake and SDL 1.3

I was recently looking into compiling SDL 1.3 on windows and noticed there were no cmake files or code::blocks project files. I’ve noticed a number of other people on these forums that also had a hiccup in their progress as a result of this.

I’ve already tried a number of things to get it to work, from making a project from scratch and adding all the SDL files, to attempting to import the VS project files, all to no avail.

I won’t ask for C::B project files, but is there any way cmake support could be added to SDL? Admittedly I’m not an expert on Cmake, nor the SDL project as a whole, but this seems like it would be a simple thing to setup and would allow SDL to work with more IDE’s without the tedium of maintaining several different project files.

I thought using cmake would be a good idea and mentioned it to Sam. I plan to
look into it once i can focus on SDL 1.3, unless someone beats me to it.________________________________
From: mako_energy02@yahoo.com (Mako_energy)
To: sdl at lists.libsdl.org
Sent: Tue, February 22, 2011 2:07:10 PM
Subject: [SDL] CMake and SDL 1.3

I was recently looking into compiling SDL 1.3 on windows and noticed there were
no cmake files or code::blocks project files. I’ve noticed a number of other
people on these forums that also had a hiccup in their progress as a result of
this.

I’ve already tried a number of things to get it to work, from making a project
from scratch and adding all the SDL files, to attempting to import the VS
project files, all to no avail.

I won’t ask for C::B project files, but is there any way cmake support could be
added to SDL? Admittedly I’m not an expert on Cmake, nor the SDL project as a
whole, but this seems like it would be a simple thing to setup and would allow
SDL to work with more IDE’s without the tedium of maintaining several different
project files.

Hello
I think that adding CMake support to the SDL should be one of the important
task. The benefits of using CMake are clear:
one code base for many “buildsystems” and dropping autoconf black magic,
installation and unit-tests management.
I may try to estimate what efforts are needed in order to migrate to the
cmake.

Best
IgorOn Tue, Feb 22, 2011 at 10:46 PM, Scott Smith wrote:

I thought using cmake would be a good idea and mentioned it to Sam. I plan
to look into it once i can focus on SDL 1.3, unless someone beats me to it.


From: Mako_energy <mako_energy02 at yahoo.com>
To: sdl at lists.libsdl.org
Sent: Tue, February 22, 2011 2:07:10 PM
Subject: [SDL] CMake and SDL 1.3

I was recently looking into compiling SDL 1.3 on windows and noticed there
were no cmake files or code::blocks project files. I’ve noticed a number of
other people on these forums that also had a hiccup in their progress as a
result of this.

I’ve already tried a number of things to get it to work, from making a
project from scratch and adding all the SDL files, to attempting to import
the VS project files, all to no avail.

I won’t ask for C::B project files, but is there any way cmake support
could be added to SDL? Admittedly I’m not an expert on Cmake, nor the SDL
project as a whole, but this seems like it would be a simple thing to setup
and would allow SDL to work with more IDE’s without the tedium of
maintaining several different project files.


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

I am a big CMake advocate. In general, I think this is a good idea.
But I need to caveat this saying it will probably be a lot of work and
we may not be free of specialized build systems. I helped spearhead
the effort to move OpenSceneGraph to CMake and I totally burned out on
that effort. It was massive amount of work. (It also really sucked not
using a distributed SCM because I needed to exchange/sync changes with
others while still syncing with mainline. Fortunately, SDL is using
distributed.) The end result was good and I think it was a huge win
for OSG. But OSG targets fewer platforms and needs to do fewer strange
things than SDL.

For example, our Mac Xcode project is a real scary piece of work.
Originally, we did some really difficult things to support Universal
Binaries which also included selecting different compilers and
different SDKs depending on the architecture. I don’t think CMake
supports these things still.

Another example is the slew of esoteric devices and emerging mobile
devices. I don’t think platforms like Amiga or Nintendo are on CMake’s
list. And I think CMake’s support for iOS is pretty weak right now. I
have no idea about Android.

And time-wise, I’m not even keeping up with the FindSDL*.cmake modules
which I’m technically the maintainer for still. I should probably
mention my final gripe is with the CMake scripting language. I love
CMake as a generator, but I really dislike the language. There is a
CMakeLua experimental fork that I’ve neglected even more so than the
FindSDL.* modules.

That said, I would love to see this happen. I think it will be useful
and off the top, knocking off the need for autoconf and manual Visual
Studio projects might be considered big enough wins. I would also hope
this might attract more patches to the generators to CMake itself to
support more platforms and the weird things we need to do.

-EricOn 2/22/11, Igor Gutnik <igor.gutnik at gmail.com> wrote:

Hello
I think that adding CMake support to the SDL should be one of the important
task. The benefits of using CMake are clear:
one code base for many “buildsystems” and dropping autoconf black magic,
installation and unit-tests management.
I may try to estimate what efforts are needed in order to migrate to the
cmake.


Beginning iPhone Games Development
http://playcontrol.net/iphonegamebook/

As far as I understand, CMake will run on any platform where gcc exists.
So, in order to estimate what is the amount of work for porting SDL to
CMake,
we need to determine (at least) to things:

  1. What compilers do SDL support
  2. What OS/platforms do SDL support.
    Anyway, I think that we will be able to use CMake on any platform which
    supports GNU Make and
    some flavor of non-esoteric compiler. I mean, that XCode support will be
    nice, but it is not essential.

IgorOn Tue, Feb 22, 2011 at 11:34 PM, Eric Wing wrote:

On 2/22/11, Igor Gutnik <@Igor_Gutnik> wrote:

Hello
I think that adding CMake support to the SDL should be one of the
important
task. The benefits of using CMake are clear:
one code base for many “buildsystems” and dropping autoconf black magic,
installation and unit-tests management.
I may try to estimate what efforts are needed in order to migrate to the
cmake.

I am a big CMake advocate. In general, I think this is a good idea.
But I need to caveat this saying it will probably be a lot of work and
we may not be free of specialized build systems. I helped spearhead
the effort to move OpenSceneGraph to CMake and I totally burned out on
that effort. It was massive amount of work. (It also really sucked not
using a distributed SCM because I needed to exchange/sync changes with
others while still syncing with mainline. Fortunately, SDL is using
distributed.) The end result was good and I think it was a huge win
for OSG. But OSG targets fewer platforms and needs to do fewer strange
things than SDL.

For example, our Mac Xcode project is a real scary piece of work.
Originally, we did some really difficult things to support Universal
Binaries which also included selecting different compilers and
different SDKs depending on the architecture. I don’t think CMake
supports these things still.

Another example is the slew of esoteric devices and emerging mobile
devices. I don’t think platforms like Amiga or Nintendo are on CMake’s
list. And I think CMake’s support for iOS is pretty weak right now. I
have no idea about Android.

And time-wise, I’m not even keeping up with the FindSDL*.cmake modules
which I’m technically the maintainer for still. I should probably
mention my final gripe is with the CMake scripting language. I love
CMake as a generator, but I really dislike the language. There is a
CMakeLua experimental fork that I’ve neglected even more so than the
FindSDL.* modules.

That said, I would love to see this happen. I think it will be useful
and off the top, knocking off the need for autoconf and manual Visual
Studio projects might be considered big enough wins. I would also hope
this might attract more patches to the generators to CMake itself to
support more platforms and the weird things we need to do.

-Eric

Beginning iPhone Games Development
http://playcontrol.net/iphonegamebook/


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

That said, I would love to see this happen. I think it will be useful
and off the top, knocking off the need for autoconf and manual Visual
Studio projects might be considered big enough wins.

Why are these projects needed? On Mac/OSX, Linux, and Windows
all compilers are available as command line tools.

I don’t see any role for projects for building libraries like SDL, even if
developers want to write their applications with an IDE.

If you really want to solve the build system problem you need
something like Erick Tryzelaars fbuild.

one high power scripting language: Python.
one script for all platforms to build something, written in Python.

There is a downside and an upside here: the downside is immaturity
of the product. The upside is the author would probably write the script
for SDL himself (as an alternative build system to start with), just for
the opportuntity to expands its ability to handle a wide variety of
platforms.

fbuild already handles C, C++, Ocaml and a few other languages
on Linux, Windows, and OSX. Hosted on GitHub.On 23/02/2011, at 8:34 AM, Eric Wing wrote:

On 2/22/11, Igor Gutnik <igor.gutnik at gmail.com> wrote:


john skaller
@john_skaller

It would allow the library to be more accessible to a broader range of people looking for a solution to all the things SDL solves. Some people want to use the tools they are familiar with and telling them “use this other completely different thing” won’t cut it. For example, at the risk of being open to flames, I have no concept of how to use GCC on the command line. My work flow is best in GUI’s. Now I’m sure there are plenty of resources out there for me to learn the usage of GCC on the command line which would take me an undetermined amount of time to learn, and even more time to apply, but I am trying to create an entire framework of libraries, SDL being one small part, and to have to break that workflow and consolidation to address SDL is a bit cumbersome.

Even if the decision is made to update SDL to support Cmake, it’ll still take longer then what I have to complete my immediate tasks, so I’m not trying to push this to be lazy. I’ll be doing the inconveniently time consuming things I mentioned above. But in a library as popular as SDL that shouldn’t be necessary. Adding support for Cmake is better for everyone. The ability to compile SDL on the command line obviously isn’t going anywhere. Supporting more IDE’s just allows more people to focus on the needed parts of their project faster. That is afterall why we all use open source libraries in the first place, isn’t it? I don’t know anything about windowing systems, so I use SDL, same for rendering so I use OGRE. Why should a project file be different?

This post was just meant to address the parts I quoted, I have no comment on the rest of your post as I am completely unfamiliar with fbuild.

john skaller wrote:> On 23/02/2011, at 8:34 AM, Eric Wing wrote:

Why are these projects needed? On Mac/OSX, Linux, and Windows
all compilers are available as command line tools.

I don’t see any role for projects for building libraries like SDL, even if
developers want to write their applications with an IDE.

It seems to me that you have a pretty good handle on things :wink:

The goal of software engineering is to:

  1. Make it work, make it work right, and make it easy for the user to use.
  2. Make it so it doesn’t misbehave if the user does something stupid.
  3. Make it easily maintainable and extensible.

Everything else is nit-picking.

As Larry the cable guy says, “Git 'er done.”

JeffOn Tuesday 22 February 2011 19:31, Mako_energy wrote:

It would allow the library to be more accessible to a broader range of
people looking for a solution to all the things SDL solves. Some people
want to use the tools they are familiar with and telling them “use this
other completely different thing” won’t cut it. For example, at the risk
of being open to flames, I have no concept of how to use GCC on the command
line. My work flow is best in GUI’s. Now I’m sure there are plenty of
resources out there for me to learn the usage of GCC on the command line
which would take me an undetermined amount of time to learn, and even more
time to apply, but I am trying to create an entire framework of libraries,
SDL being one small part, and to have to break that workflow and
consolidation to address SDL is a bit cumbersome.

FYI, everytime I change build systems I spend months getting it
working everywhere again. I don’t mind adding CMake support,
especially if it lets me generate all the Visual Studio projects, but
I’m not going to write it at this point. :slight_smile:

As Eric said, the Xcode project is a hairy beast with several custom
targets. I would be impressed if anyone can create a CMakefile that
can actually generate everything that SDL needs on all platforms. :)On Tue, Feb 22, 2011 at 1:34 PM, Eric Wing wrote:

On 2/22/11, Igor Gutnik <igor.gutnik at gmail.com> wrote:

Hello
I think that adding CMake support to the SDL should be one of the important
task. The benefits of using CMake are clear:
one code base for many “buildsystems” and dropping autoconf black magic,
installation and unit-tests management.
I may try to estimate what efforts are needed in order to migrate to the
cmake.

I am a big CMake advocate. In general, I think this is a good idea.
But I need to caveat this saying it will probably be a lot of work and
we may not be free of specialized build systems. I helped spearhead
the effort to move OpenSceneGraph to CMake and I totally burned out on
that effort. It was massive amount of work. (It also really sucked not
using a distributed SCM because I needed to exchange/sync changes with
others while still syncing with mainline. Fortunately, SDL is using
distributed.) The end result was good and I think it was a huge win
for OSG. But OSG targets fewer platforms and needs to do fewer strange
things than SDL.

For example, our Mac Xcode project is a real scary piece of work.
Originally, we did some really difficult things to support Universal
Binaries which also included selecting different compilers and
different SDKs depending on the architecture. I don’t think CMake
supports these things still.

Another example is the slew of esoteric devices and emerging mobile
devices. I don’t think platforms like Amiga or Nintendo are on CMake’s
list. And I think CMake’s support for iOS is pretty weak right now. I
have no idea about Android.

And time-wise, I’m not even keeping up with the FindSDL*.cmake modules
which I’m technically the maintainer for still. I should probably
mention my final gripe is with the CMake scripting language. I love
CMake as a generator, but I really dislike the language. There is a
CMakeLua experimental fork that I’ve neglected even more so than the
FindSDL.* modules.

That said, I would love to see this happen. I think it will be useful
and off the top, knocking off the need for autoconf and manual Visual
Studio projects might be considered big enough wins. I would also hope
this might attract more patches to the generators to CMake itself to
support more platforms and the weird things we need to do.

-Eric

Beginning iPhone Games Development
http://playcontrol.net/iphonegamebook/


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


? ? -Sam Lantinga, Founder and CEO, Galaxy Gameworks

For what it’s worth, there’s no reason why there couldn’t be CMake
support for some platforms and custom projects for others. It’s a
better situation than custom projects for every platform. For
example, if we can consolicate the Makefile.* and the Visual Studio
projects, that would be a good improvement.On Tue, Feb 22, 2011 at 8:03 PM, Sam Lantinga <@slouken> wrote:

FYI, everytime I change build systems I spend months getting it
working everywhere again. ?I don’t mind adding CMake support,
especially if it lets me generate all the Visual Studio projects, but
I’m not going to write it at this point. :slight_smile:

As Eric said, the Xcode project is a hairy beast with several custom
targets. ?I would be impressed if anyone can create a CMakefile that
can actually generate everything that SDL needs on all platforms. :slight_smile:

On Tue, Feb 22, 2011 at 1:34 PM, Eric Wing wrote:

On 2/22/11, Igor Gutnik <igor.gutnik at gmail.com> wrote:

Hello
I think that adding CMake support to the SDL should be one of the important
task. The benefits of using CMake are clear:
one code base for many “buildsystems” and dropping autoconf black magic,
installation and unit-tests management.
I may try to estimate what efforts are needed in order to migrate to the
cmake.

I am a big CMake advocate. In general, I think this is a good idea.
But I need to caveat this saying it will probably be a lot of work and
we may not be free of specialized build systems. I helped spearhead
the effort to move OpenSceneGraph to CMake and I totally burned out on
that effort. It was massive amount of work. (It also really sucked not
using a distributed SCM because I needed to exchange/sync changes with
others while still syncing with mainline. Fortunately, SDL is using
distributed.) The end result was good and I think it was a huge win
for OSG. But OSG targets fewer platforms and needs to do fewer strange
things than SDL.

For example, our Mac Xcode project is a real scary piece of work.
Originally, we did some really difficult things to support Universal
Binaries which also included selecting different compilers and
different SDKs depending on the architecture. I don’t think CMake
supports these things still.

Another example is the slew of esoteric devices and emerging mobile
devices. I don’t think platforms like Amiga or Nintendo are on CMake’s
list. And I think CMake’s support for iOS is pretty weak right now. I
have no idea about Android.

And time-wise, I’m not even keeping up with the FindSDL*.cmake modules
which I’m technically the maintainer for still. I should probably
mention my final gripe is with the CMake scripting language. I love
CMake as a generator, but I really dislike the language. There is a
CMakeLua experimental fork that I’ve neglected even more so than the
FindSDL.* modules.

That said, I would love to see this happen. I think it will be useful
and off the top, knocking off the need for autoconf and manual Visual
Studio projects might be considered big enough wins. I would also hope
this might attract more patches to the generators to CMake itself to
support more platforms and the weird things we need to do.

-Eric

Beginning iPhone Games Development
http://playcontrol.net/iphonegamebook/


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org


? ? -Sam Lantinga, Founder and CEO, Galaxy Gameworks


? ? -Sam Lantinga, Founder and CEO, Galaxy Gameworks

For what it’s worth, there’s no reason why there couldn’t be CMake
support for some platforms and custom projects for others. ?It’s a
better situation than custom projects for every platform. ?For
example, if we can consolicate the Makefile.* and the Visual Studio
projects, that would be a good improvement.

For Adonthell, we’re having both CMake and autotools as build system
(initially CMake was the only way to get it built for Windows, in the
meantime I figured how to do it with autotools too). Adonthell
consists of a dozen dynamic libraries, loadable modules and Python
bindings for each of the libraries. For the fun of it, I once let it
generate an XCode project and while it worked in principle, the
resulting project was far from simple and well structured and
basically anybody not familiar with the intrinsics would be lost at
the multitude of targets and custom build scripts. That said, the
makefile generators of cmake work great and I’ve used them to compile
Adonthell on Linux, Windows (MSYS) and OSX. But to be entirely honest,
I still prefer the autotools build and mostly use that (which is why
we support both).

It would allow the library to be more accessible to a broader range of
people looking for a solution to all the things SDL solves. Some people
want to use the tools they are familiar with and telling them “use this
other completely different thing” won’t cut it.

True. I’m always frustrated if I need to install something that
doesn’t support the usual ./configure && make && sudo make install
steps.

OTOH, once an official SDL 1.3 (or 2.0) release is available, people
can get that, add libs and headers to their own project in their
preferred IDE and don’t have to worry about anything else. So as long
as SDL developers themselves are able to produce binaries for all
needed platforms, I don’t see much value in changing build systems
that late in the game.

As for all the SDL IDE projects in general: wouldn’t it work to set
them up as project with an external build system? That’s what I do
with Adonthell in XCode and Eclipse. That means you get to use the
development environment of your choice, but for the actual building
you still trigger make. I doubt that VS allows something like that,
however.

KaiOn Wed, Feb 23, 2011 at 5:05 AM, Sam Lantinga wrote:

If someone wants to do it, fine. But from my experience with
CMake, all I can say is: “live is too short”.

– KeesOn 22 Feb, 2011, at 20:07 , Mako_energy wrote:

I was recently looking into compiling SDL 1.3 on windows and noticed there were no cmake files or code::blocks project files. I’ve noticed a number of other people on these forums that also had a hiccup in their progress as a result of this.

I’ve already tried a number of things to get it to work, from making a project from scratch and adding all the SDL files, to attempting to import the VS project files, all to no avail.

I won’t ask for C::B project files, but is there any way cmake support could be added to SDL? Admittedly I’m not an expert on Cmake, nor the SDL project as a whole, but this seems like it would be a simple thing to setup and would allow SDL to work with more IDE’s without the tedium of maintaining several different project files.


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

That said, I would love to see this happen. I think it will be useful
and off the top, knocking off the need for autoconf and manual Visual
Studio projects might be considered big enough wins.

Why are these projects needed? On Mac/OSX, Linux, and Windows
all compilers are available as command line tools.

I don’t see any role for projects for building libraries like SDL, even if
developers want to write their applications with an IDE.

If you really want to solve the build system problem you need
something like Erick Tryzelaars fbuild.

one high power scripting language: Python.
one script for all platforms to build something, written in Python.

There is a downside and an upside here: the downside is immaturity
of the product. The upside is the author would probably write the script
for SDL himself (as an alternative build system to start with), just for
the opportuntity to expands its ability to handle a wide variety of
platforms.

There are really two separate issues. One issue is letting developers
use the tools they are most productive in. The other issue is just
getting binaries produced for our own distributions.

In the first case, it advantageous to offer IDE projects because as an
open source project, we can tap a wider pool of developers that might
actually help improve the code base. Allowing developers to work with
the tools they are most productive in is a serious advantage.

To emphasize how CMake brings this advantage to the table, I did a
screencast (posted on YouTube) awhile back showing how users can use
CMake to generate native build systems on their chosen IDEs and
platforms so they can work with the tools they are comfortable with.
http://playcontrol.net/ewing/screencasts/getting_started_with_cmake_.html

In the second case, as I said with Mac/Xcode, we do some very
complicated things to produce a binary that is reliable enough to ship
for the official distribution. This means dealing with multiple
compilers, multiple SDKs, multiple architectures, plus dealing with
other Apple specific things such as anchor paths, framework
construction, Info.plists, and setting Mac OS deployment versions
correctly. While we might theoretically reverse engineer every command
incantation needed to do this, this is extremely fragile and outside
the scope of SDL to maintain. I have seen the simple reordering of
flags (like -arch i386 ppc vs -arch ppc i386) completely break older
versions of Apple’s gcc. CMake actually has figured out/dealt with
some of these issues and I have successfully lobbied CMake to get some
of these features supported, but there are still ones missing and the
features are complex to access. Also Xcode is a constantly moving
target. For example, Apple is moving to llvm too so assuming we could
figure out everything with gcc, this all is going to change again.

Furthermore with iOS, there are additional codesigning requirements
and magical things that let you toggle simulator vs. device builds and
debug/execute and much of this process is hidden in Xcode and not
accessible through any public command line tool. (Trust me, I’ve
tried?I’m doing some slick things with Scripting Bridge (via LuaCocoa
of course) and Xcode to work around this, but even Xcode’s Scripting
Bridge support is limited and buggy.)

As for fbuild, I don’t know it and can’t comment it on it directly.
But CMake has been around for over a decade and is proven software.
Big projects like KDE, VTK, and OpenSceneGraph use CMake so we know it
works. Kitware has to maintain large projects that use CMake and gets
large government contracts to make sure things work. They are also
very serious about automated unit testing so their product has a
certain degree of reliability. You only have to see the number
cross-platform build systems come and go over the past decade (or
more) to recognize how hard it is to do well. CMake is far from
perfect, but the problem I see with all the newcomers is they fail to
learn from what CMake (or other successful tools) does right and
wrong, tend to focus on a subset of a particular problem and
ignore/dismiss a lot of the other hard problems that are required to
make things actually work, and instead reinvent the wheel in the dark
which pretty much always fails to produce a superior product.

-EricOn 2/22/11, john skaller wrote:

On 23/02/2011, at 8:34 AM, Eric Wing wrote:

On 2/22/11, Igor Gutnik <igor.gutnik at gmail.com> wrote:

Beginning iPhone Games Development
http://playcontrol.net/iphonegamebook/

The associate of mine that setup our project with cmake for windows/linux whipped up this document to get you guys started with cmake in SDL. It’ll generate the project file (tested with code::blocks), but when you try to compile it it will fail on platform specific stuff.

This isn’t a solution obviously, but it’ll help get things going for whomever knows SDL well enough to put the necessary details into it. Sorry about the size of this, there wasn’t a cleaner way to post this. =\

Code:

The cmake build script for the SDL

cmake_minimum_required (VERSION 2.8)
project (SDL)

#Set some variables to make finding things easier later on in the build
set (${PROJECT_NAME}_ROOT_DIR “${${PROJECT_NAME}_SOURCE_DIR}/”)
set (${PROJECT_NAME}_SRC_DIR “${${PROJECT_NAME}_ROOT_DIR}/src/”)
set (${PROJECT_NAME}_INCLUDE_DIR “${${PROJECT_NAME}_ROOT_DIR}/include/”)

set (${PROJECT_NAME}_BINARY_DIR “${${PROJECT_NAME}_BINARY_DIR}/bin/”) #to put the binaries and any libraries where they are expected
set (PROJECT_BINARY_DIR “${${PROJECT_NAME}_BINARY_DIR}”)
set (LIBRARY_OUTPUT_PATH “${${PROJECT_NAME}_BINARY_DIR}”)
#If all cmake commands that need to reference Binaries or Src files use the above variables instead of hard paths the
#user/gameprogrammer can have all the build files in another folder (which can make his/her life easier in several of ways)

#Some logic should go here that does something to include of exclude files based on the platform
#This logic could also right after the really list of source files
#if (${UNIX})
#set(${PROJECT_NAME}_sources “${${PROJECT_NAME}_SRC_DIR}UnixOrLinuxSrcFile.c” ${${PROJECT_NAME}_sources} )
#endif(${UNIX})

#if (${WINDOWS})
#set(${PROJECT_NAME}_sources “${${PROJECT_NAME}_SRC_DIR}WindowsOnlySrcFile.c” ${${PROJECT_NAME}_sources} )
#endif(${WINDOWS})

#Make on big arrary with all the source and header files
set(${PROJECT_NAME}_sources

#Headers
"${${PROJECT_NAME}_INCLUDE_DIR}begin_code.h"
"${${PROJECT_NAME}_INCLUDE_DIR}close_code.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_assert.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_atomic.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_audio.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_blendmode.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_clipboard.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_compat.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config_android.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config_iphoneos.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config_macosx.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config_minimal.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config_nintendods.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config_pandora.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config_windows.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config_wiz.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_copying.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_cpuinfo.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_endian.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_error.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_events.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_gesture.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_haptic.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_hints.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_input.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_joystick.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_keyboard.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_keycode.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_loadso.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_log.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_main.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_mouse.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_mutex.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_name.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_opengles2.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_opengles.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_opengl.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_pixels.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_platform.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_power.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_quit.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_rect.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_render.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_revision.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_rwops.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_scancode.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_shape.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_stdinc.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_surface.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_syswm.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_thread.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_timer.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_touch.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_types.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_version.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_video.h"

#Source Files
"${${PROJECT_NAME}_SRC_DIR}SDL_assert.c"
"${${PROJECT_NAME}_SRC_DIR}SDL_assert_c.h"
"${${PROJECT_NAME}_SRC_DIR}SDL.c"
"${${PROJECT_NAME}_SRC_DIR}SDL_compat.c"
"${${PROJECT_NAME}_SRC_DIR}SDL_error.c"
"${${PROJECT_NAME}_SRC_DIR}SDL_error_c.h"
"${${PROJECT_NAME}_SRC_DIR}SDL_fatal.c"
"${${PROJECT_NAME}_SRC_DIR}SDL_fatal.h"
"${${PROJECT_NAME}_SRC_DIR}SDL_hints.c"
"${${PROJECT_NAME}_SRC_DIR}SDL_log.c"

#src/atomic:
"${${PROJECT_NAME}_SRC_DIR}atomic/SDL_atomic.c"
"${${PROJECT_NAME}_SRC_DIR}atomic/SDL_spinlock.c"

#src/audio:
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_audio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_audio_c.h"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_audiocvt.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_audiodev.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_audiodev_c.h"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_audiomem.h"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_audiotypecvt.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_mixer.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_mixer_m68k.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_mixer_m68k.h"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_mixer_MMX.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_mixer_MMX.h"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_mixer_MMX_VC.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_mixer_MMX_VC.h"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_sysaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_wave.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_wave.h"

#src/cpuinfo:
"${${PROJECT_NAME}_SRC_DIR}cpuinfo/SDL_cpuinfo.c"

#src/events:
"${${PROJECT_NAME}_SRC_DIR}events/blank_cursor.h"
"${${PROJECT_NAME}_SRC_DIR}events/default_cursor.h"
"${${PROJECT_NAME}_SRC_DIR}events/scancodes_darwin.h"
"${${PROJECT_NAME}_SRC_DIR}events/scancodes_linux.h"
"${${PROJECT_NAME}_SRC_DIR}events/scancodes_windows.h"
"${${PROJECT_NAME}_SRC_DIR}events/scancodes_xfree86.h"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_clipboardevents.c"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_clipboardevents_c.h"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_events.c"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_events_c.h"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_gesture.c"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_gesture_c.h"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_keyboard.c"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_keyboard_c.h"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_mouse.c"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_mouse_c.h"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_quit.c"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_sysevents.h"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_touch.c"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_touch_c.h"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_windowevents.c"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_windowevents_c.h"

#src/file:
"${${PROJECT_NAME}_SRC_DIR}file/SDL_rwops.c"

#src/haptic:
"${${PROJECT_NAME}_SRC_DIR}haptic/SDL_haptic.c"
"${${PROJECT_NAME}_SRC_DIR}haptic/SDL_haptic_c.h"
"${${PROJECT_NAME}_SRC_DIR}haptic/SDL_syshaptic.h"

#src/joystick:
"${${PROJECT_NAME}_SRC_DIR}joystick/SDL_joystick.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/SDL_joystick_c.h"
"${${PROJECT_NAME}_SRC_DIR}joystick/SDL_sysjoystick.h"

#src/libm:
"${${PROJECT_NAME}_SRC_DIR}libm/e_atan2.c"
"${${PROJECT_NAME}_SRC_DIR}libm/e_log.c"
"${${PROJECT_NAME}_SRC_DIR}libm/e_pow.c"
"${${PROJECT_NAME}_SRC_DIR}libm/e_rem_pio2.c"
"${${PROJECT_NAME}_SRC_DIR}libm/e_sqrt.c"
"${${PROJECT_NAME}_SRC_DIR}libm/k_cos.c"
"${${PROJECT_NAME}_SRC_DIR}libm/k_rem_pio2.c"
"${${PROJECT_NAME}_SRC_DIR}libm/k_sin.c"
"${${PROJECT_NAME}_SRC_DIR}libm/math.h"
"${${PROJECT_NAME}_SRC_DIR}libm/math_private.h"
"${${PROJECT_NAME}_SRC_DIR}libm/s_atan.c"
"${${PROJECT_NAME}_SRC_DIR}libm/s_copysign.c"
"${${PROJECT_NAME}_SRC_DIR}libm/s_cos.c"
"${${PROJECT_NAME}_SRC_DIR}libm/s_fabs.c"
"${${PROJECT_NAME}_SRC_DIR}libm/s_floor.c"
"${${PROJECT_NAME}_SRC_DIR}libm/s_scalbn.c"
"${${PROJECT_NAME}_SRC_DIR}libm/s_sin.c"

#src/power:
"${${PROJECT_NAME}_SRC_DIR}power/SDL_power.c"

#src/render:
"${${PROJECT_NAME}_SRC_DIR}render/mmx.h"
"${${PROJECT_NAME}_SRC_DIR}render/SDL_render.c"
"${${PROJECT_NAME}_SRC_DIR}render/SDL_sysrender.h"
"${${PROJECT_NAME}_SRC_DIR}render/SDL_yuv_mmx.c"
"${${PROJECT_NAME}_SRC_DIR}render/SDL_yuv_sw.c"
"${${PROJECT_NAME}_SRC_DIR}render/SDL_yuv_sw_c.h"

#src/stdlib:
"${${PROJECT_NAME}_SRC_DIR}stdlib/SDL_getenv.c"
"${${PROJECT_NAME}_SRC_DIR}stdlib/SDL_iconv.c"
"${${PROJECT_NAME}_SRC_DIR}stdlib/SDL_malloc.c"
"${${PROJECT_NAME}_SRC_DIR}stdlib/SDL_qsort.c"
"${${PROJECT_NAME}_SRC_DIR}stdlib/SDL_stdlib.c"
"${${PROJECT_NAME}_SRC_DIR}stdlib/SDL_string.c"

#src/thread:
"${${PROJECT_NAME}_SRC_DIR}thread/SDL_systhread.h"
"${${PROJECT_NAME}_SRC_DIR}thread/SDL_thread.c"
"${${PROJECT_NAME}_SRC_DIR}thread/SDL_thread_c.h"

#src/timer:
"${${PROJECT_NAME}_SRC_DIR}timer/SDL_timer.c"
"${${PROJECT_NAME}_SRC_DIR}timer/SDL_timer_c.h"

#src/video:
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_0.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_1.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_A.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_auto.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_auto.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_copy.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_copy.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_N.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_slow.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_slow.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_bmp.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_clipboard.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_fillrect.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_pixels.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_pixels_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_rect.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_rect_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_RLEaccel.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_RLEaccel_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_shape.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_shape_internals.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_stretch.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_surface.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_sysvideo.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_video.c"

#more deeply nested files that may need some platform specific logic to determine inclusion
"${${PROJECT_NAME}_SRC_DIR}audio/alsa/SDL_alsa_audio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/alsa/SDL_alsa_audio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/android/SDL_androidaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/android/SDL_androidaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/arts/SDL_artsaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/arts/SDL_artsaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/baudio/SDL_beaudio.cc"
"${${PROJECT_NAME}_SRC_DIR}audio/baudio/SDL_beaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/bsd/SDL_bsdaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/bsd/SDL_bsdaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/disk/SDL_diskaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/disk/SDL_diskaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/dma/SDL_dmaaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/dma/SDL_dmaaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/dmedia/SDL_irixaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/dmedia/SDL_irixaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/dsp/SDL_dspaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/dsp/SDL_dspaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/dummy/SDL_dummyaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/dummy/SDL_dummyaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/esd/SDL_esdaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/esd/SDL_esdaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/fusionsound/SDL_fsaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/fusionsound/SDL_fsaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/iphoneos/SDL_coreaudio_iphone.c"
"${${PROJECT_NAME}_SRC_DIR}audio/iphoneos/SDL_coreaudio_iphone.h"
"${${PROJECT_NAME}_SRC_DIR}audio/macosx/SDL_coreaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/macosx/SDL_coreaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/mme/SDL_mmeaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/mme/SDL_mmeaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/nas/SDL_nasaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/nas/SDL_nasaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/nds/SDL_ndsaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/nds/SDL_ndsaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/paudio/SDL_paudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/paudio/SDL_paudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/pulseaudio/SDL_pulseaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/pulseaudio/SDL_pulseaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/qsa/SDL_qsa_audio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/qsa/SDL_qsa_audio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/sun/SDL_sunaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/sun/SDL_sunaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/ums/SDL_umsaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/ums/SDL_umsaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/windib/SDL_dibaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/windib/SDL_dibaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/windx5/directx.h"
"${${PROJECT_NAME}_SRC_DIR}audio/windx5/SDL_dx5audio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/windx5/SDL_dx5audio.h"
"${${PROJECT_NAME}_SRC_DIR}core/android/SDL_android.cpp"
"${${PROJECT_NAME}_SRC_DIR}core/android/SDL_android.h"
"${${PROJECT_NAME}_SRC_DIR}core/windows/SDL_windows.c"
"${${PROJECT_NAME}_SRC_DIR}core/windows/SDL_windows.h"
"${${PROJECT_NAME}_SRC_DIR}events/nds/SDL_ndsgesture.c"
"${${PROJECT_NAME}_SRC_DIR}file/cocoa/SDL_rwopsbundlesupport.h"
"${${PROJECT_NAME}_SRC_DIR}haptic/darwin/SDL_syshaptic.c"
"${${PROJECT_NAME}_SRC_DIR}haptic/dummy/SDL_syshaptic.c"
"${${PROJECT_NAME}_SRC_DIR}haptic/linux/SDL_syshaptic.c"
"${${PROJECT_NAME}_SRC_DIR}haptic/nds/SDL_syshaptic.c"
"${${PROJECT_NAME}_SRC_DIR}haptic/windows/SDL_syshaptic.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/android/SDL_sysjoystick.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/beos/SDL_bejoystick.cc"
"${${PROJECT_NAME}_SRC_DIR}joystick/bsd/SDL_sysjoystick.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/darwin/SDL_sysjoystick.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/darwin/SDL_sysjoystick_c.h"
"${${PROJECT_NAME}_SRC_DIR}joystick/dummy/SDL_sysjoystick.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/iphoneos/SDLUIAccelerationDelegate.h"
"${${PROJECT_NAME}_SRC_DIR}joystick/linux/SDL_sysjoystick.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/linux/SDL_sysjoystick_c.h"
"${${PROJECT_NAME}_SRC_DIR}joystick/nds/SDL_sysjoystick.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/windows/SDL_dxjoystick.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/windows/SDL_dxjoystick_c.h"
"${${PROJECT_NAME}_SRC_DIR}joystick/windows/SDL_mmjoystick.c"
"${${PROJECT_NAME}_SRC_DIR}loadso/beos/SDL_sysloadso.c"
"${${PROJECT_NAME}_SRC_DIR}loadso/dlopen/SDL_sysloadso.c"
"${${PROJECT_NAME}_SRC_DIR}loadso/dummy/SDL_sysloadso.c"
"${${PROJECT_NAME}_SRC_DIR}loadso/macosx/SDL_dlcompat.c"
"${${PROJECT_NAME}_SRC_DIR}loadso/windows/SDL_sysloadso.c"
"${${PROJECT_NAME}_SRC_DIR}main/android/SDL_android_main.cpp"
"${${PROJECT_NAME}_SRC_DIR}main/beos/SDL_BeApp.cc"
"${${PROJECT_NAME}_SRC_DIR}main/beos/SDL_BeApp.h"
"${${PROJECT_NAME}_SRC_DIR}main/dummy/SDL_dummy_main.c"
"${${PROJECT_NAME}_SRC_DIR}main/windows/SDL_windows_main.c"
"${${PROJECT_NAME}_SRC_DIR}power/beos/SDL_syspower.c"
"${${PROJECT_NAME}_SRC_DIR}power/linux/SDL_syspower.c"
"${${PROJECT_NAME}_SRC_DIR}power/macosx/SDL_syspower.c"
"${${PROJECT_NAME}_SRC_DIR}power/nds/SDL_syspower.c"
"${${PROJECT_NAME}_SRC_DIR}power/windows/SDL_syspower.c"
"${${PROJECT_NAME}_SRC_DIR}render/direct3d/SDL_render_d3d.c"
"${${PROJECT_NAME}_SRC_DIR}render/opengles2/SDL_render_gles2.c"
"${${PROJECT_NAME}_SRC_DIR}render/opengles2/SDL_shaders_gles2.c"
"${${PROJECT_NAME}_SRC_DIR}render/opengles2/SDL_shaders_gles2.h"
"${${PROJECT_NAME}_SRC_DIR}render/opengles/SDL_render_gles.c"
"${${PROJECT_NAME}_SRC_DIR}render/opengl/SDL_glfuncs.h"
"${${PROJECT_NAME}_SRC_DIR}render/opengl/SDL_render_gl.c"
"${${PROJECT_NAME}_SRC_DIR}render/opengl/SDL_shaders_gl.c"
"${${PROJECT_NAME}_SRC_DIR}render/opengl/SDL_shaders_gl.h"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_blendfillrect.c"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_blendfillrect.h"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_blendline.c"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_blendline.h"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_blendpoint.c"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_blendpoint.h"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_draw.h"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_drawline.c"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_drawline.h"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_drawpoint.c"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_drawpoint.h"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_render_sw.c"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_render_sw_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/beos/SDL_syssem.c"
"${${PROJECT_NAME}_SRC_DIR}thread/beos/SDL_systhread.c"
"${${PROJECT_NAME}_SRC_DIR}thread/beos/SDL_systhread_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/generic/SDL_syscond.c"
"${${PROJECT_NAME}_SRC_DIR}thread/generic/SDL_sysmutex.c"
"${${PROJECT_NAME}_SRC_DIR}thread/generic/SDL_sysmutex_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/generic/SDL_syssem.c"
"${${PROJECT_NAME}_SRC_DIR}thread/generic/SDL_systhread.c"
"${${PROJECT_NAME}_SRC_DIR}thread/generic/SDL_systhread_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/irix/SDL_syssem.c"
"${${PROJECT_NAME}_SRC_DIR}thread/irix/SDL_systhread.c"
"${${PROJECT_NAME}_SRC_DIR}thread/irix/SDL_systhread_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/nds/SDL_syscond.c"
"${${PROJECT_NAME}_SRC_DIR}thread/nds/SDL_syscond_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/nds/SDL_sysmutex.c"
"${${PROJECT_NAME}_SRC_DIR}thread/nds/SDL_sysmutex_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/nds/SDL_syssem.c"
"${${PROJECT_NAME}_SRC_DIR}thread/nds/SDL_syssem_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/nds/SDL_systhread.c"
"${${PROJECT_NAME}_SRC_DIR}thread/nds/SDL_systhread_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/pthread/SDL_syscond.c"
"${${PROJECT_NAME}_SRC_DIR}thread/pthread/SDL_sysmutex.c"
"${${PROJECT_NAME}_SRC_DIR}thread/pthread/SDL_sysmutex_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/pthread/SDL_syssem.c"
"${${PROJECT_NAME}_SRC_DIR}thread/pthread/SDL_systhread.c"
"${${PROJECT_NAME}_SRC_DIR}thread/pthread/SDL_systhread_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/windows/SDL_sysmutex.c"
"${${PROJECT_NAME}_SRC_DIR}thread/windows/SDL_syssem.c"
"${${PROJECT_NAME}_SRC_DIR}thread/windows/SDL_systhread.c"
"${${PROJECT_NAME}_SRC_DIR}thread/windows/SDL_systhread_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/windows/win_ce_semaphore.c"
"${${PROJECT_NAME}_SRC_DIR}thread/windows/win_ce_semaphore.h"
"${${PROJECT_NAME}_SRC_DIR}timer/beos/SDL_systimer.c"
"${${PROJECT_NAME}_SRC_DIR}timer/dummy/SDL_systimer.c"
"${${PROJECT_NAME}_SRC_DIR}timer/nds/SDL_systimer.c"
"${${PROJECT_NAME}_SRC_DIR}timer/unix/SDL_systimer.c"
"${${PROJECT_NAME}_SRC_DIR}timer/wince/SDL_systimer.c"
"${${PROJECT_NAME}_SRC_DIR}timer/windows/SDL_systimer.c"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidevents.c"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidevents.h"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidgl.c"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidkeyboard.c"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidkeyboard.h"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidtouch.c"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidtouch.h"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidvideo.c"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidvideo.h"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidwindow.c"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidwindow.h"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_BView.h"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_BWin.h"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_lowvideo.h"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_sysevents.cc"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_sysevents_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_sysmouse.cc"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_sysmouse_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_sysvideo.cc"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_syswm.cc"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_syswm_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_sysyuv.cc"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_sysyuv.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoaclipboard.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoaevents.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoakeyboard.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoamodes.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoamouse.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoaopengl.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoashape.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoavideo.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoawindow.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_dyn.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_dyn.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_events.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_events.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_modes.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_modes.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_mouse.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_mouse.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_opengl.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_opengl.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_render.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_render.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_video.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_video.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_window.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_window.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_WM.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_WM.h"
"${${PROJECT_NAME}_SRC_DIR}video/dummy/SDL_nullevents.c"
"${${PROJECT_NAME}_SRC_DIR}video/dummy/SDL_nullevents_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/dummy/SDL_nullframebuffer.c"
"${${PROJECT_NAME}_SRC_DIR}video/dummy/SDL_nullframebuffer_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/dummy/SDL_nullvideo.c"
"${${PROJECT_NAME}_SRC_DIR}video/dummy/SDL_nullvideo.h"
"${${PROJECT_NAME}_SRC_DIR}video/nds/SDL_ndsevents.c"
"${${PROJECT_NAME}_SRC_DIR}video/nds/SDL_ndsevents_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/nds/SDL_ndsrender.c"
"${${PROJECT_NAME}_SRC_DIR}video/nds/SDL_ndsrender_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/nds/SDL_ndsvideo.c"
"${${PROJECT_NAME}_SRC_DIR}video/nds/SDL_ndsvideo.h"
"${${PROJECT_NAME}_SRC_DIR}video/pandora/SDL_pandora.c"
"${${PROJECT_NAME}_SRC_DIR}video/pandora/SDL_pandora_events.c"
"${${PROJECT_NAME}_SRC_DIR}video/pandora/SDL_pandora_events.h"
"${${PROJECT_NAME}_SRC_DIR}video/pandora/SDL_pandora.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/jumphack.c"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/jumphack.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/keyinfotable.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/SDL_uikitappdelegate.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/SDL_uikitevents.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/SDL_uikitkeyboard.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/SDL_uikitopengles.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/SDL_uikitopenglview.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/SDL_uikitvideo.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/SDL_uikitview.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/SDL_uikitwindow.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_msctf.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_vkeys.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsclipboard.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsclipboard.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsevents.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsevents.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsframebuffer.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsframebuffer.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowskeyboard.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowskeyboard.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsmodes.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsmodes.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsmouse.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsmouse.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsopengl.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsopengl.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsshape.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsshape.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsvideo.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsvideo.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowswindow.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowswindow.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/wmmsg.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/imKStoUCS.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/imKStoUCS.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11clipboard.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11clipboard.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11dyn.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11dyn.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11events.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11events.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11framebuffer.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11framebuffer.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11keyboard.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11keyboard.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11modes.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11modes.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11mouse.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11mouse.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11opengl.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11opengles.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11opengles.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11opengl.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11shape.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11shape.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11sym.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11touch.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11touch.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11video.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11video.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11window.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11window.h"

"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/extutil.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/panoramiXext.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/panoramiXproto.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/Xext.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/xf86dga1.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/xf86dga1str.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/xf86dga.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/xf86dgastr.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/xf86vmode.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/xf86vmstr.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/Xinerama.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/Xv.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/Xvlib.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/Xvproto.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/Xinerama/Xinerama.c"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/XME/xme.c"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/Xv/Xv.c"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/Xv/Xvlibint.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/Xxf86vm/XF86VMode.c"

# If you had you platform specific logic above you would probably want to include more those Source files here by unremarking the next lines
#${${PROJECT_NAME}_sources}

)

#Some logic should go here that does something to find any build dependencies based on the platform
#if (${UNIX})
#Some code for finding the dependencies
#set(LibraryNames X11 Mesa3d)
#endif(${UNIX})

#if (${WINDOWS})
#Some code for finding the dependencies
#set(LibraryNames Directx)
#endif(${WINDOWS})

include_directories(
#don’t forget library include dirs
${${PROJECT_NAME}_INCLUDE_DIR}
)

#Tells the compiler what is expected, and gives users the choice of a static lib or dynamic lib, that defaults to static
option(SDLStaticLib “Should this be built as a static Library” ON)
if(${SDLStaticLib})
add_library(${PROJECT_NAME} STATIC ${${PROJECT_NAME}_sources} )
else(${SDLStaticLib})
add_library(${PROJECT_NAME} SHARED ${${PROJECT_NAME}_sources})
endif(${SDLStaticLib})

#Tells the linker what to do
target_link_libraries( ${PROJECT_NAME} ${LibraryNames} OpenGL )

D: You don’t have to list the files out like at all you know.
Here’s[1] a “saner” solution. Note: I don’t know the SDL source layout
all too well, so I didn’t actually place any true globbing expressions
in it, but you should get the idea :slight_smile:

[1]: https://gist.github.com/eb2fe391d1eaa029dce7On Wed, Feb 23, 2011 at 11:39 AM, Mako_energy <mako_energy02 at yahoo.com> wrote:

The associate of mine that setup our project with cmake for windows/linux whipped up this document to get you guys started with cmake in SDL. It’ll generate the project file (tested with code::blocks), but when you try to compile it it will fail on platform specific stuff.

This isn’t a solution obviously, but it’ll help get things going for whomever knows SDL well enough to put the necessary details into it. Sorry about the size of this, there wasn’t a cleaner way to post this. =\

EXTREMELY HUGE AMOUNT OF TEXT snipped for sanity

Tres Walsh wrote:> On Wed, Feb 23, 2011 at 11:39 AM, Mako_energy <@Mako_energy> wrote:

D: You don’t have to list the files out like at all you know.
Here’s1 a “saner” solution. Note: I don’t know the SDL source layout
all too well, so I didn’t actually place any true globbing expressions
in it, but you should get the idea :slight_smile:


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

That is a good thing to know! Thanks.

D: You don’t have to list the files out like at all you know.
Here’s[1] a “saner” solution. Note: I don’t know the SDL source layout
all too well, so I didn’t actually place any true globbing expressions
in it, but you should get the idea :slight_smile:

globs have a lot of downsides and this is a philosophical debate. I’m
rather opposed to them. It is too easy to accidentally introduce files
you don’t necessarily mean to include with globs.

Also, I think there are negative implications with globs with CMake’s
dependency analysis and you lose out.

-Eric–
Beginning iPhone Games Development
http://playcontrol.net/iphonegamebook/

Hi,

not sure when I will have free time, probably only around next week, but I
could have a go at it.

It is a good excuse to learn CMake. :)–
Paulo

On Wed, Feb 23, 2011 at 8:39 PM, Mako_energy <mako_energy02 at yahoo.com>wrote:

The associate of mine that setup our project with cmake for windows/linux
whipped up this document to get you guys started with cmake in SDL. It’ll
generate the project file (tested with code::blocks), but when you try to
compile it it will fail on platform specific stuff.

This isn’t a solution obviously, but it’ll help get things going for
whomever knows SDL well enough to put the necessary details into it. Sorry
about the size of this, there wasn’t a cleaner way to post this. =\

Code:

The cmake build script for the SDL

cmake_minimum_required (VERSION 2.8)
project (SDL)

#Set some variables to make finding things easier later on in the build
set (${PROJECT_NAME}_ROOT_DIR “${${PROJECT_NAME}_SOURCE_DIR}/”)
set (${PROJECT_NAME}_SRC_DIR “${${PROJECT_NAME}_ROOT_DIR}/src/”)
set (${PROJECT_NAME}_INCLUDE_DIR “${${PROJECT_NAME}_ROOT_DIR}/include/”)

set (${PROJECT_NAME}_BINARY_DIR “${${PROJECT_NAME}_BINARY_DIR}/bin/”)
#to put the binaries and any libraries where they are expected
set (PROJECT_BINARY_DIR “${${PROJECT_NAME}_BINARY_DIR}”)
set (LIBRARY_OUTPUT_PATH “${${PROJECT_NAME}_BINARY_DIR}”)
#If all cmake commands that need to reference Binaries or Src files use the
above variables instead of hard paths the
#user/gameprogrammer can have all the build files in another folder (which
can make his/her life easier in several of ways)

#Some logic should go here that does something to include of exclude files
based on the platform
#This logic could also right after the really list of source files
#if (${UNIX})
#set(${PROJECT_NAME}_sources
"${${PROJECT_NAME}_SRC_DIR}UnixOrLinuxSrcFile.c" ${${PROJECT_NAME}_sources}
)
#endif(${UNIX})

#if (${WINDOWS})
#set(${PROJECT_NAME}_sources
"${${PROJECT_NAME}_SRC_DIR}WindowsOnlySrcFile.c" ${${PROJECT_NAME}_sources}
)
#endif(${WINDOWS})

#Make on big arrary with all the source and header files
set(${PROJECT_NAME}_sources

#Headers
"${${PROJECT_NAME}_INCLUDE_DIR}begin_code.h"
"${${PROJECT_NAME}_INCLUDE_DIR}close_code.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_assert.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_atomic.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_audio.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_blendmode.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_clipboard.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_compat.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config_android.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config_iphoneos.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config_macosx.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config_minimal.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config_nintendods.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config_pandora.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config_windows.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_config_wiz.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_copying.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_cpuinfo.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_endian.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_error.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_events.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_gesture.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_haptic.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_hints.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_input.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_joystick.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_keyboard.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_keycode.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_loadso.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_log.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_main.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_mouse.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_mutex.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_name.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_opengles2.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_opengles.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_opengl.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_pixels.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_platform.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_power.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_quit.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_rect.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_render.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_revision.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_rwops.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_scancode.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_shape.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_stdinc.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_surface.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_syswm.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_thread.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_timer.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_touch.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_types.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_version.h"
"${${PROJECT_NAME}_INCLUDE_DIR}SDL_video.h"

#Source Files
"${${PROJECT_NAME}_SRC_DIR}SDL_assert.c"
"${${PROJECT_NAME}_SRC_DIR}SDL_assert_c.h"
"${${PROJECT_NAME}_SRC_DIR}SDL.c"
"${${PROJECT_NAME}_SRC_DIR}SDL_compat.c"
"${${PROJECT_NAME}_SRC_DIR}SDL_error.c"
"${${PROJECT_NAME}_SRC_DIR}SDL_error_c.h"
"${${PROJECT_NAME}_SRC_DIR}SDL_fatal.c"
"${${PROJECT_NAME}_SRC_DIR}SDL_fatal.h"
"${${PROJECT_NAME}_SRC_DIR}SDL_hints.c"
"${${PROJECT_NAME}_SRC_DIR}SDL_log.c"

#src/atomic:
"${${PROJECT_NAME}_SRC_DIR}atomic/SDL_atomic.c"
"${${PROJECT_NAME}_SRC_DIR}atomic/SDL_spinlock.c"

#src/audio:
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_audio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_audio_c.h"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_audiocvt.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_audiodev.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_audiodev_c.h"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_audiomem.h"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_audiotypecvt.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_mixer.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_mixer_m68k.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_mixer_m68k.h"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_mixer_MMX.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_mixer_MMX.h"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_mixer_MMX_VC.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_mixer_MMX_VC.h"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_sysaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_wave.c"
"${${PROJECT_NAME}_SRC_DIR}audio/SDL_wave.h"

#src/cpuinfo:
"${${PROJECT_NAME}_SRC_DIR}cpuinfo/SDL_cpuinfo.c"

#src/events:
"${${PROJECT_NAME}_SRC_DIR}events/blank_cursor.h"
"${${PROJECT_NAME}_SRC_DIR}events/default_cursor.h"
"${${PROJECT_NAME}_SRC_DIR}events/scancodes_darwin.h"
"${${PROJECT_NAME}_SRC_DIR}events/scancodes_linux.h"
"${${PROJECT_NAME}_SRC_DIR}events/scancodes_windows.h"
"${${PROJECT_NAME}_SRC_DIR}events/scancodes_xfree86.h"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_clipboardevents.c"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_clipboardevents_c.h"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_events.c"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_events_c.h"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_gesture.c"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_gesture_c.h"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_keyboard.c"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_keyboard_c.h"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_mouse.c"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_mouse_c.h"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_quit.c"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_sysevents.h"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_touch.c"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_touch_c.h"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_windowevents.c"
"${${PROJECT_NAME}_SRC_DIR}events/SDL_windowevents_c.h"

#src/file:
"${${PROJECT_NAME}_SRC_DIR}file/SDL_rwops.c"

#src/haptic:
"${${PROJECT_NAME}_SRC_DIR}haptic/SDL_haptic.c"
"${${PROJECT_NAME}_SRC_DIR}haptic/SDL_haptic_c.h"
"${${PROJECT_NAME}_SRC_DIR}haptic/SDL_syshaptic.h"

#src/joystick:
"${${PROJECT_NAME}_SRC_DIR}joystick/SDL_joystick.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/SDL_joystick_c.h"
"${${PROJECT_NAME}_SRC_DIR}joystick/SDL_sysjoystick.h"

#src/libm:
"${${PROJECT_NAME}_SRC_DIR}libm/e_atan2.c"
"${${PROJECT_NAME}_SRC_DIR}libm/e_log.c"
"${${PROJECT_NAME}_SRC_DIR}libm/e_pow.c"
"${${PROJECT_NAME}_SRC_DIR}libm/e_rem_pio2.c"
"${${PROJECT_NAME}_SRC_DIR}libm/e_sqrt.c"
"${${PROJECT_NAME}_SRC_DIR}libm/k_cos.c"
"${${PROJECT_NAME}_SRC_DIR}libm/k_rem_pio2.c"
"${${PROJECT_NAME}_SRC_DIR}libm/k_sin.c"
"${${PROJECT_NAME}_SRC_DIR}libm/math.h"
"${${PROJECT_NAME}_SRC_DIR}libm/math_private.h"
"${${PROJECT_NAME}_SRC_DIR}libm/s_atan.c"
"${${PROJECT_NAME}_SRC_DIR}libm/s_copysign.c"
"${${PROJECT_NAME}_SRC_DIR}libm/s_cos.c"
"${${PROJECT_NAME}_SRC_DIR}libm/s_fabs.c"
"${${PROJECT_NAME}_SRC_DIR}libm/s_floor.c"
"${${PROJECT_NAME}_SRC_DIR}libm/s_scalbn.c"
"${${PROJECT_NAME}_SRC_DIR}libm/s_sin.c"

#src/power:
"${${PROJECT_NAME}_SRC_DIR}power/SDL_power.c"

#src/render:
"${${PROJECT_NAME}_SRC_DIR}render/mmx.h"
"${${PROJECT_NAME}_SRC_DIR}render/SDL_render.c"
"${${PROJECT_NAME}_SRC_DIR}render/SDL_sysrender.h"
"${${PROJECT_NAME}_SRC_DIR}render/SDL_yuv_mmx.c"
"${${PROJECT_NAME}_SRC_DIR}render/SDL_yuv_sw.c"
"${${PROJECT_NAME}_SRC_DIR}render/SDL_yuv_sw_c.h"

#src/stdlib:
"${${PROJECT_NAME}_SRC_DIR}stdlib/SDL_getenv.c"
"${${PROJECT_NAME}_SRC_DIR}stdlib/SDL_iconv.c"
"${${PROJECT_NAME}_SRC_DIR}stdlib/SDL_malloc.c"
"${${PROJECT_NAME}_SRC_DIR}stdlib/SDL_qsort.c"
"${${PROJECT_NAME}_SRC_DIR}stdlib/SDL_stdlib.c"
"${${PROJECT_NAME}_SRC_DIR}stdlib/SDL_string.c"

#src/thread:
"${${PROJECT_NAME}_SRC_DIR}thread/SDL_systhread.h"
"${${PROJECT_NAME}_SRC_DIR}thread/SDL_thread.c"
"${${PROJECT_NAME}_SRC_DIR}thread/SDL_thread_c.h"

#src/timer:
"${${PROJECT_NAME}_SRC_DIR}timer/SDL_timer.c"
"${${PROJECT_NAME}_SRC_DIR}timer/SDL_timer_c.h"

#src/video:
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_0.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_1.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_A.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_auto.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_auto.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_copy.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_copy.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_N.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_slow.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_blit_slow.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_bmp.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_clipboard.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_fillrect.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_pixels.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_pixels_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_rect.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_rect_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_RLEaccel.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_RLEaccel_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_shape.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_shape_internals.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_stretch.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_surface.c"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_sysvideo.h"
"${${PROJECT_NAME}_SRC_DIR}video/SDL_video.c"

#more deeply nested files that may need some platform specific logic to
determine inclusion
"${${PROJECT_NAME}_SRC_DIR}audio/alsa/SDL_alsa_audio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/alsa/SDL_alsa_audio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/android/SDL_androidaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/android/SDL_androidaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/arts/SDL_artsaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/arts/SDL_artsaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/baudio/SDL_beaudio.cc"
"${${PROJECT_NAME}_SRC_DIR}audio/baudio/SDL_beaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/bsd/SDL_bsdaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/bsd/SDL_bsdaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/disk/SDL_diskaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/disk/SDL_diskaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/dma/SDL_dmaaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/dma/SDL_dmaaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/dmedia/SDL_irixaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/dmedia/SDL_irixaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/dsp/SDL_dspaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/dsp/SDL_dspaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/dummy/SDL_dummyaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/dummy/SDL_dummyaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/esd/SDL_esdaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/esd/SDL_esdaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/fusionsound/SDL_fsaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/fusionsound/SDL_fsaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/iphoneos/SDL_coreaudio_iphone.c"
"${${PROJECT_NAME}_SRC_DIR}audio/iphoneos/SDL_coreaudio_iphone.h"
"${${PROJECT_NAME}_SRC_DIR}audio/macosx/SDL_coreaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/macosx/SDL_coreaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/mme/SDL_mmeaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/mme/SDL_mmeaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/nas/SDL_nasaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/nas/SDL_nasaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/nds/SDL_ndsaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/nds/SDL_ndsaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/paudio/SDL_paudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/paudio/SDL_paudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/pulseaudio/SDL_pulseaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/pulseaudio/SDL_pulseaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/qsa/SDL_qsa_audio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/qsa/SDL_qsa_audio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/sun/SDL_sunaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/sun/SDL_sunaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/ums/SDL_umsaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/ums/SDL_umsaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/windib/SDL_dibaudio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/windib/SDL_dibaudio.h"
"${${PROJECT_NAME}_SRC_DIR}audio/windx5/directx.h"
"${${PROJECT_NAME}_SRC_DIR}audio/windx5/SDL_dx5audio.c"
"${${PROJECT_NAME}_SRC_DIR}audio/windx5/SDL_dx5audio.h"
"${${PROJECT_NAME}_SRC_DIR}core/android/SDL_android.cpp"
"${${PROJECT_NAME}_SRC_DIR}core/android/SDL_android.h"
"${${PROJECT_NAME}_SRC_DIR}core/windows/SDL_windows.c"
"${${PROJECT_NAME}_SRC_DIR}core/windows/SDL_windows.h"
"${${PROJECT_NAME}_SRC_DIR}events/nds/SDL_ndsgesture.c"
"${${PROJECT_NAME}_SRC_DIR}file/cocoa/SDL_rwopsbundlesupport.h"
"${${PROJECT_NAME}_SRC_DIR}haptic/darwin/SDL_syshaptic.c"
"${${PROJECT_NAME}_SRC_DIR}haptic/dummy/SDL_syshaptic.c"
"${${PROJECT_NAME}_SRC_DIR}haptic/linux/SDL_syshaptic.c"
"${${PROJECT_NAME}_SRC_DIR}haptic/nds/SDL_syshaptic.c"
"${${PROJECT_NAME}_SRC_DIR}haptic/windows/SDL_syshaptic.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/android/SDL_sysjoystick.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/beos/SDL_bejoystick.cc"
"${${PROJECT_NAME}_SRC_DIR}joystick/bsd/SDL_sysjoystick.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/darwin/SDL_sysjoystick.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/darwin/SDL_sysjoystick_c.h"
"${${PROJECT_NAME}_SRC_DIR}joystick/dummy/SDL_sysjoystick.c"

“${${PROJECT_NAME}_SRC_DIR}joystick/iphoneos/SDLUIAccelerationDelegate.h”
"${${PROJECT_NAME}_SRC_DIR}joystick/linux/SDL_sysjoystick.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/linux/SDL_sysjoystick_c.h"
"${${PROJECT_NAME}_SRC_DIR}joystick/nds/SDL_sysjoystick.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/windows/SDL_dxjoystick.c"
"${${PROJECT_NAME}_SRC_DIR}joystick/windows/SDL_dxjoystick_c.h"
"${${PROJECT_NAME}_SRC_DIR}joystick/windows/SDL_mmjoystick.c"
"${${PROJECT_NAME}_SRC_DIR}loadso/beos/SDL_sysloadso.c"
"${${PROJECT_NAME}_SRC_DIR}loadso/dlopen/SDL_sysloadso.c"
"${${PROJECT_NAME}_SRC_DIR}loadso/dummy/SDL_sysloadso.c"
"${${PROJECT_NAME}_SRC_DIR}loadso/macosx/SDL_dlcompat.c"
"${${PROJECT_NAME}_SRC_DIR}loadso/windows/SDL_sysloadso.c"
"${${PROJECT_NAME}_SRC_DIR}main/android/SDL_android_main.cpp"
"${${PROJECT_NAME}_SRC_DIR}main/beos/SDL_BeApp.cc"
"${${PROJECT_NAME}_SRC_DIR}main/beos/SDL_BeApp.h"
"${${PROJECT_NAME}_SRC_DIR}main/dummy/SDL_dummy_main.c"
"${${PROJECT_NAME}_SRC_DIR}main/windows/SDL_windows_main.c"
"${${PROJECT_NAME}_SRC_DIR}power/beos/SDL_syspower.c"
"${${PROJECT_NAME}_SRC_DIR}power/linux/SDL_syspower.c"
"${${PROJECT_NAME}_SRC_DIR}power/macosx/SDL_syspower.c"
"${${PROJECT_NAME}_SRC_DIR}power/nds/SDL_syspower.c"
"${${PROJECT_NAME}_SRC_DIR}power/windows/SDL_syspower.c"
"${${PROJECT_NAME}_SRC_DIR}render/direct3d/SDL_render_d3d.c"
"${${PROJECT_NAME}_SRC_DIR}render/opengles2/SDL_render_gles2.c"
"${${PROJECT_NAME}_SRC_DIR}render/opengles2/SDL_shaders_gles2.c"
"${${PROJECT_NAME}_SRC_DIR}render/opengles2/SDL_shaders_gles2.h"
"${${PROJECT_NAME}_SRC_DIR}render/opengles/SDL_render_gles.c"
"${${PROJECT_NAME}_SRC_DIR}render/opengl/SDL_glfuncs.h"
"${${PROJECT_NAME}_SRC_DIR}render/opengl/SDL_render_gl.c"
"${${PROJECT_NAME}_SRC_DIR}render/opengl/SDL_shaders_gl.c"
"${${PROJECT_NAME}_SRC_DIR}render/opengl/SDL_shaders_gl.h"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_blendfillrect.c"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_blendfillrect.h"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_blendline.c"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_blendline.h"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_blendpoint.c"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_blendpoint.h"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_draw.h"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_drawline.c"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_drawline.h"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_drawpoint.c"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_drawpoint.h"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_render_sw.c"
"${${PROJECT_NAME}_SRC_DIR}render/software/SDL_render_sw_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/beos/SDL_syssem.c"
"${${PROJECT_NAME}_SRC_DIR}thread/beos/SDL_systhread.c"
"${${PROJECT_NAME}_SRC_DIR}thread/beos/SDL_systhread_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/generic/SDL_syscond.c"
"${${PROJECT_NAME}_SRC_DIR}thread/generic/SDL_sysmutex.c"
"${${PROJECT_NAME}_SRC_DIR}thread/generic/SDL_sysmutex_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/generic/SDL_syssem.c"
"${${PROJECT_NAME}_SRC_DIR}thread/generic/SDL_systhread.c"
"${${PROJECT_NAME}_SRC_DIR}thread/generic/SDL_systhread_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/irix/SDL_syssem.c"
"${${PROJECT_NAME}_SRC_DIR}thread/irix/SDL_systhread.c"
"${${PROJECT_NAME}_SRC_DIR}thread/irix/SDL_systhread_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/nds/SDL_syscond.c"
"${${PROJECT_NAME}_SRC_DIR}thread/nds/SDL_syscond_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/nds/SDL_sysmutex.c"
"${${PROJECT_NAME}_SRC_DIR}thread/nds/SDL_sysmutex_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/nds/SDL_syssem.c"
"${${PROJECT_NAME}_SRC_DIR}thread/nds/SDL_syssem_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/nds/SDL_systhread.c"
"${${PROJECT_NAME}_SRC_DIR}thread/nds/SDL_systhread_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/pthread/SDL_syscond.c"
"${${PROJECT_NAME}_SRC_DIR}thread/pthread/SDL_sysmutex.c"
"${${PROJECT_NAME}_SRC_DIR}thread/pthread/SDL_sysmutex_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/pthread/SDL_syssem.c"
"${${PROJECT_NAME}_SRC_DIR}thread/pthread/SDL_systhread.c"
"${${PROJECT_NAME}_SRC_DIR}thread/pthread/SDL_systhread_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/windows/SDL_sysmutex.c"
"${${PROJECT_NAME}_SRC_DIR}thread/windows/SDL_syssem.c"
"${${PROJECT_NAME}_SRC_DIR}thread/windows/SDL_systhread.c"
"${${PROJECT_NAME}_SRC_DIR}thread/windows/SDL_systhread_c.h"
"${${PROJECT_NAME}_SRC_DIR}thread/windows/win_ce_semaphore.c"
"${${PROJECT_NAME}_SRC_DIR}thread/windows/win_ce_semaphore.h"
"${${PROJECT_NAME}_SRC_DIR}timer/beos/SDL_systimer.c"
"${${PROJECT_NAME}_SRC_DIR}timer/dummy/SDL_systimer.c"
"${${PROJECT_NAME}_SRC_DIR}timer/nds/SDL_systimer.c"
"${${PROJECT_NAME}_SRC_DIR}timer/unix/SDL_systimer.c"
"${${PROJECT_NAME}_SRC_DIR}timer/wince/SDL_systimer.c"
"${${PROJECT_NAME}_SRC_DIR}timer/windows/SDL_systimer.c"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidevents.c"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidevents.h"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidgl.c"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidkeyboard.c"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidkeyboard.h"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidtouch.c"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidtouch.h"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidvideo.c"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidvideo.h"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidwindow.c"
"${${PROJECT_NAME}_SRC_DIR}video/android/SDL_androidwindow.h"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_BView.h"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_BWin.h"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_lowvideo.h"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_sysevents.cc"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_sysevents_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_sysmouse.cc"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_sysmouse_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_sysvideo.cc"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_syswm.cc"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_syswm_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_sysyuv.cc"
"${${PROJECT_NAME}_SRC_DIR}video/bwindow/SDL_sysyuv.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoaclipboard.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoaevents.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoakeyboard.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoamodes.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoamouse.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoaopengl.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoashape.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoavideo.h"
"${${PROJECT_NAME}_SRC_DIR}video/cocoa/SDL_cocoawindow.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_dyn.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_dyn.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_events.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_events.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_modes.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_modes.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_mouse.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_mouse.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_opengl.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_opengl.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_render.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_render.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_video.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_video.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_window.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_window.h"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_WM.c"
"${${PROJECT_NAME}_SRC_DIR}video/directfb/SDL_DirectFB_WM.h"
"${${PROJECT_NAME}_SRC_DIR}video/dummy/SDL_nullevents.c"
"${${PROJECT_NAME}_SRC_DIR}video/dummy/SDL_nullevents_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/dummy/SDL_nullframebuffer.c"
"${${PROJECT_NAME}_SRC_DIR}video/dummy/SDL_nullframebuffer_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/dummy/SDL_nullvideo.c"
"${${PROJECT_NAME}_SRC_DIR}video/dummy/SDL_nullvideo.h"
"${${PROJECT_NAME}_SRC_DIR}video/nds/SDL_ndsevents.c"
"${${PROJECT_NAME}_SRC_DIR}video/nds/SDL_ndsevents_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/nds/SDL_ndsrender.c"
"${${PROJECT_NAME}_SRC_DIR}video/nds/SDL_ndsrender_c.h"
"${${PROJECT_NAME}_SRC_DIR}video/nds/SDL_ndsvideo.c"
"${${PROJECT_NAME}_SRC_DIR}video/nds/SDL_ndsvideo.h"
"${${PROJECT_NAME}_SRC_DIR}video/pandora/SDL_pandora.c"
"${${PROJECT_NAME}_SRC_DIR}video/pandora/SDL_pandora_events.c"
"${${PROJECT_NAME}_SRC_DIR}video/pandora/SDL_pandora_events.h"
"${${PROJECT_NAME}_SRC_DIR}video/pandora/SDL_pandora.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/jumphack.c"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/jumphack.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/keyinfotable.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/SDL_uikitappdelegate.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/SDL_uikitevents.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/SDL_uikitkeyboard.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/SDL_uikitopengles.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/SDL_uikitopenglview.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/SDL_uikitvideo.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/SDL_uikitview.h"
"${${PROJECT_NAME}_SRC_DIR}video/uikit/SDL_uikitwindow.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_msctf.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_vkeys.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsclipboard.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsclipboard.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsevents.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsevents.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsframebuffer.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsframebuffer.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowskeyboard.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowskeyboard.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsmodes.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsmodes.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsmouse.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsmouse.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsopengl.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsopengl.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsshape.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsshape.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsvideo.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowsvideo.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowswindow.c"
"${${PROJECT_NAME}_SRC_DIR}video/windows/SDL_windowswindow.h"
"${${PROJECT_NAME}_SRC_DIR}video/windows/wmmsg.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/imKStoUCS.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/imKStoUCS.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11clipboard.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11clipboard.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11dyn.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11dyn.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11events.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11events.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11framebuffer.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11framebuffer.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11keyboard.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11keyboard.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11modes.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11modes.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11mouse.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11mouse.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11opengl.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11opengles.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11opengles.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11opengl.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11shape.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11shape.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11sym.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11touch.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11touch.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11video.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11video.h"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11window.c"
"${${PROJECT_NAME}_SRC_DIR}video/x11/SDL_x11window.h"

“${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/extutil.h”
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/panoramiXext.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/panoramiXproto.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/Xext.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/xf86dga1.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/xf86dga1str.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/xf86dga.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/xf86dgastr.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/xf86vmode.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/xf86vmstr.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/Xinerama.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/Xv.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/Xvlib.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/extensions/Xvproto.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/Xinerama/Xinerama.c"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/XME/xme.c"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/Xv/Xv.c"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/Xv/Xvlibint.h"
"${${PROJECT_NAME}_SRC_DIR}video/Xext/Xxf86vm/XF86VMode.c"

If you had you platform specific logic above you would probably want

to include more those Source files here by unremarking the next lines
#${${PROJECT_NAME}_sources}
)

#Some logic should go here that does something to find any build
dependencies based on the platform
#if (${UNIX})
#Some code for finding the dependencies
#set(LibraryNames X11 Mesa3d)
#endif(${UNIX})

#if (${WINDOWS})
#Some code for finding the dependencies
#set(LibraryNames Directx)
#endif(${WINDOWS})

include_directories(
#don’t forget library include dirs
${${PROJECT_NAME}_INCLUDE_DIR}
)

#Tells the compiler what is expected, and gives users the choice of a
static lib or dynamic lib, that defaults to static
option(SDLStaticLib “Should this be built as a static Library” ON)
if(${SDLStaticLib})
add_library(${PROJECT_NAME} STATIC ${${PROJECT_NAME}_sources} )
else(${SDLStaticLib})
add_library(${PROJECT_NAME} SHARED ${${PROJECT_NAME}_sources})
endif(${SDLStaticLib})

#Tells the linker what to do
target_link_libraries( ${PROJECT_NAME} ${LibraryNames} OpenGL )


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

I usually make my directory structure for cmake, so I use globs a lot, but
never recursively. One folder per dependency, and one glob per dependency.
with such a convention, you get all the good stuff from globs without the
downsides. But I’ve been using cmake from the start of my projects, SDL has
a legacy structure.

2011/2/26 Eric Wing > > D: You don’t have to list the files out like at all you know.

Here’s[1] a “saner” solution. Note: I don’t know the SDL source layout
all too well, so I didn’t actually place any true globbing expressions
in it, but you should get the idea :slight_smile:

globs have a lot of downsides and this is a philosophical debate. I’m
rather opposed to them. It is too easy to accidentally introduce files
you don’t necessarily mean to include with globs.

Also, I think there are negative implications with globs with CMake’s
dependency analysis and you lose out.

-Eric

Beginning iPhone Games Development
http://playcontrol.net/iphonegamebook/


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org