← Back

ofxCMake

github.com/peterkolski/ofxCMake · @peterkolski
OF 0.9 Utilities Templates

CMake build system for openFrameworks. Usage of the CLion IDE is possible

99 29 Last commit 9y ago Created 10y ago

Forks

Forks pushed to more recently than peterkolski/ofxCMake itself, plus any admin-confirmed fork with commits of its own — worth checking if you're hitting issues with the original.

ofxyz/ofxCMake by @ofxyz · ★ 0 · pushed 5mo ago
TheTechnobear/ofxCMake by @TheTechnobear · ★ 0 · pushed 3y ago
mm318/ofxCMake by @mm318 · ★ 0 · pushed 5y ago
visualcamp-legacy/ofxCMake by @visualcamp-legacy · ★ 0 · pushed 7y ago
techtim/ofxCMake by @techtim · ★ 0 · pushed 8y ago
gilbertfrancois/ofxCMake by @gilbertfrancois · ★ 1 · pushed 8y ago
koreus7/ofxCMake by @koreus7 · ★ 0 · pushed 8y ago
mursisoy/ofxCMake by @mursisoy · ★ 1 · pushed 8y ago

Branches ahead of master

These branches have commits not yet on master — could be unmerged fixes or work in progress worth a look.

bildPeter/ofxDarkNet 7 commits ahead · last commit 9y ago
bildPeter/externalAddOns 3 commits ahead · last commit 9y ago
bildPeter/RPiPort 16 commits ahead · last commit 10y ago

README

ofxCMake Logo

CMake for OpenFrameworks [Vers. 0.1]

Quick Start Guide

1. Clone into of/addons/ofxCMake 2. In ofxCMake/project/CMakeLists.txt change the path of your OF folder. 3. Copy ofxCMake/project/CMakeLists.txt into your project folder 4. Open with CLion or compile via terminal

Discription

CMake is a meta build system, so it can generate different build systems like Visual Studio Projects, xCode, make etc. It can also create installers like DEB, RPM and MSI.

CMake Intro:

CMake is a universal, plattform independent build system. It tells which source files and libraries of OpenFrameworks, your project and addOns have to be compiled together so you have your application. CMake is supported e.g. by the IDEs: CLion, QTCreator, KDevelop.

Note

This is not an ofxAddOn in the normal way. So do not just copy it into the of/addons/ folder and expect it to work.

Installation

1. Clone the git files in your openframeworks addon folder
	$ cd of/addons
	$ git clone https://github.com/BildPeter/ofxCMake.git
	
Alternative: Extract in of/addons and rename into ofxCMake 2. In the file ofxCMake/project/CMakeLists.txt change the path of your OF folder.

Usage



Preperation

Command Line Compilation

	$ cd of/apps/myApps/newApp
	$ mkdir build
	$ cd build
	$ cmake ..
	$ make -j4
	

CLion IDE

1. Prepare your project as explained above 2. Choose via CLion in the 'Open File or Project' the CMakeLists.txt



Addons

Internal Addons – Usage

External Addons – Creation

include( ${OF_CMAKE_ADDONS}/external/ofxNAME.cmake ) Note: This approach is static and centralised. It is not a perfect solution, but it lets your openFramework file structure untouched, if you want to update OpenFrameworks or remove CMake. Future approach might include a configuration file in each new AddOn

Development Philosophy

Compatibility

At the moment (Feb 2017) only Mac OS is fully tested.

The infrastructure for other OS (Linux, Windows) is already set up.

Tested on MacOS 10.12.2 with cMake 3.2.1 and of 0.9.8

Special Thanks

Avilleret

Get this addon

HTTPS
SSH