This is an example libcinder project that should demonstrate the cinder-app build process as an individual and stand-alone project. This example utilises the official libcinder-cmake approach that can be found here: github.com/cinder. Please make sure to check the android_linux branch. The related discussion should be available here on the libcinder community forum : [RFC] Cross-platform CMake support
-
From within the
./build
folder, run the following command:cmake .. -DCINDER_VERBOSE=On -DCMAKE_BUILD_TYPE=Release
-
After the build process is complete, run
make
to compile the application. Once the application is successfully compiled theBezierPathIteration.app
folder will be created inside the following location:./build/<build_type>/BezierPathIteration.app
-
To run the application, just run
open BezierPathIteration.app
-
The first item that is critical to this process is the
CINDER_PATH
variable. This should be pointing to thelibcinder
folder structure. -
The initial
CMakeLists.txt
file is providing some basic information regarding the project. -
The required CMake module
cinderMakeApp
is located inside the${CINDER_PATH}/proj/cmake/modules
folder. Once the remote modules folder${CINDER_PATH}/proj/cmake/modules
is appended to the${CMAKE_MODULE_PATH}
, thecinderMakeApp.cmake
file is included and theci_make_app
function becomes available. -
The
ci_make_app
function is a wrapper that accepts various arguments and the intention is to fecth the configuration from the CMake chain located inside theCINDER_PATH
structure. -
The first script accessed from the remote
CINDER_PATH
location is${CINDER_PATH}/proj/cmake/configure.cmake
-
After that,
libcinder
is imported from the following location:${CINDER_PATH}/lib/<platform>/<build_type>
which underOSX
would be${CINDER_PATH}/lib/macosx/Release
. At this stage,libcinder
is imported as anIMPORTED_TARGET
. This is done through thecinderConfig.cmake
file that is in the same folder asthe static lib archivelibcinder.a
(yes, we havelibcinder
built as a STATIC target). The file is created as part of the build process that compiles thelibcinder
target. -
The
cinderConfig.cmake
inside${CINDER_PATH}/lib/macosx/Release
will be invoking a file calledcinderTargets.cmake
. This file should have been created as part of the build process that originally compiledlibcinder
. ThecinderTargets.cmake
file should be located inside thebuild
folder oflibcinder
, in that case it is${CINDER_PATH}/build/lib/macosx/Release/cinderTargets.cmake
. -
At the final stage,
icons
andassets
are copied to theResources
folder.