[CMake] Installing FindCGAL.cmake

Fernando Cacciola fernando.cacciola at gmail.com
Thu Nov 13 22:18:59 EST 2008


Hi,

In preparing the cmake build system for CGAL I'm having this issue:

Users can define CGAL_DIR explicitely when configuring their own 
programs in order to allow find_package(CGAL) to locate CGALConfig.cmake.

OTOH, if FindCGAL.cmake is in the cmake modules path, they don't need to 
define CGAL_DIR at all.

However, I'm not sure how to go about installing FindCGAL.cmake.

If I merely add an install rule to put it in the actual cmake directory, 
users are then *forced* to run the install target with access privileges 
and they may not want or be allowed to do that.

So, is there a way to create a "normal user" install target and a 
separate "super user" install target??
Something that would allow my users to do something like:

   make install
   sudo make root-install

TIA

Fernando Cacciola




More information about the CMake mailing list