Getting Started With CMake (An End-User's Perspective) For Cross-Platform Building


170px-cmake_logo_textmedium

I have posted a series of videos (actually one video that I chopped up into YouTube sized chunks) that demonstrate how to use CMake to build a project with your operating system and IDE of choice.


This is not a tutorial on how to code CMake. This is a tutorial on how to build a project that uses CMake. It's not hard, but I've found that a lot of newbies and outsiders don't know where to start or fully understand what CMake actually does and all the cool things CMake is capable of doing such as generating Visual Studio, Xcode, and Eclipse projects.


So this video shows off some of the generator capabilities of CMake. I also do some useful tips and tricks.


Specifically, this video uses a new OpenGL related project called Chaskii (which I helped write the CMake build system for). And using virtualization (via VMWare), I do a side-by-side(-by-side-by-side) comparison of building the same project under Linux (Ubuntu), Mac (Leopard) and Windows (XP), demonstrating the Makefile, Eclipse, Xcode, and Visual Studio generators.


This screencast was originally made to help the Chaskii users, but in hindsight, I realized that this video covers a lot of general ideas that would be useful for CMake users in general. So I am making this available for all.


For best results, please watch the HD version so you can read any small text. (I've also significantly improved my recording and encoding quality techniques over my last videos.) The videos were recorded at 1280x800. This Sandvox website template isn't designed for widescreen, so for best results, you may want to watch this on YouTube directly, or use a download grabber and watch the movie directly in a movie player. (My original files had chapter bookmarks.)



Part 1: Introduction, Out-of-source builds, and Makefile generator on Ubuntu Linux.


Part 2: Makefiles continued, CMake Targets, Automatic Dependency Tracking, Output Directories, rpath, make install & make uninstall


Part 3: Eclipse Generator


Part 4: CMake GUIs (ccmake), Xcode generator on Mac OS X 10.5, CPack to make .pkg installer


Part 5: CMake-GUI on Windows XP, environmental variable tricks, Visual Studio


Part 6: Install target and Windows Registry entries, Back to Linux/Makefiles, Debug  and Release types for Makefiles, Auto-regeneration by CMake


Part 1:



Part 2:



Part 3:




Part 4:



Part 5:




Part 6:



Chaskii is open source and can be found here:

http://chaskii.org

Subversion:

svn co https://www.andesengineering.com/svn/Chaskii/branches/Chaskii_1.0/


CMake as always can be found here:

http://www.cmake.org



Copyright © PlayControl Software, LLC / Eric Wing