From 41283a36c59b30e2a155329506006a6ee1c54a56 Mon Sep 17 00:00:00 2001 From: dcnieho Date: Tue, 13 Mar 2012 08:24:20 +0000 Subject: [PATCH] added a quick tut for using cmake, adapted from http://mash-project.eu/wiki/index.php/CMake:_Quick_Start_Guide git-svn-id: https://svn.code.sf.net/p/freeglut/code/trunk@1122 7f0cb862-5218-0410-a997-914c9d46530a --- .gitattributes | 1 + freeglut/freeglut/README.cmake | 33 +++++++++++++++++++++++++++++++++ 2 files changed, 34 insertions(+) create mode 100644 freeglut/freeglut/README.cmake diff --git a/.gitattributes b/.gitattributes index e2aa225..2a4886c 100644 --- a/.gitattributes +++ b/.gitattributes @@ -11,6 +11,7 @@ freeglut/freeglut/Makefile.wat svn_keywords=Author+Date+Id+Revision freeglut/freeglut/NEWS svn_keywords=Author+Date+Id+Revision freeglut/freeglut/README svn_keywords=Author+Date+Id+Revision freeglut/freeglut/README.android -text +freeglut/freeglut/README.cmake -text freeglut/freeglut/README.cygwin_mingw svn_keywords=Author+Date+Id+Revision freeglut/freeglut/README.mac -text freeglut/freeglut/README.mingw_cross svn_keywords=Author+Date+Id+Revision diff --git a/freeglut/freeglut/README.cmake b/freeglut/freeglut/README.cmake new file mode 100644 index 0000000..51ab817 --- /dev/null +++ b/freeglut/freeglut/README.cmake @@ -0,0 +1,33 @@ +How to build freeglut with CMake: +1. Download CMake (http://www.cmake.org/cmake/resources/software.html). + Get one of the releases from the binary distribution section. +2. Run the CMake installer, install wherever you like. +3. Launch CMake via Start > Program Files > CMake 2.8 > CMake (GUI) + (note that the shortcut put by the installer on your desktop does NOT + point to the CMake GUI program!) +4. In the "Where is the source code" box, type or browse to the root + directory of your freeglut source (so that's /freeglut, not + /freeglut/src). +5. In the "Where to build the binaries" box, type or browse to any + folder you like - this will be where the Visual Studio solution will be + generated. This folder does not have to exist yet. +6. Hit the Configure button near the bottom of the window. +7. Pick your target compiler, make sure that its installed on your + system of course! +8. Answer Ok when asked if you want to create the build directory. +9. Wait for the configure process to finish. +10. The screen will now have some configuration options on it, for + instance specifying whether you want to build static and/or shared + libraries (see below for a complete list). When you've selected your + options, click the Configure button again. +11. The Generate button at the bottom will now be enabled. Click Generate. +12. The build files will now be generated in the location you picked. + +You can now navigate to the build directory you specified in step 5. +Open the freeglut.sln file that was generated in your build directory, +and compile as usual + + + +Breakdown of CMake configuration options: +TODO