[brlcad-commits] SF.net SVN: brlcad:[51654] brlcad/trunk/CMakeLists.txt
Open Source Solid Modeling CAD
Brought to you by:
brlcad
From: <sta...@us...> - 2012-07-24 14:26:59
|
Revision: 51654 http://brlcad.svn.sourceforge.net/brlcad/?rev=51654&view=rev Author: starseeker Date: 2012-07-24 13:23:10 +0000 (Tue, 24 Jul 2012) Log Message: ----------- Restore build type vs. installation directory check, but just print a warning instead of overriding. Modified Paths: -------------- brlcad/trunk/CMakeLists.txt Modified: brlcad/trunk/CMakeLists.txt =================================================================== --- brlcad/trunk/CMakeLists.txt 2012-07-24 08:43:51 UTC (rev 51653) +++ brlcad/trunk/CMakeLists.txt 2012-07-24 13:23:10 UTC (rev 51654) @@ -634,6 +634,16 @@ set(BRLCAD_PREFIX ${CMAKE_INSTALL_PREFIX} CACHE STRING "BRL-CAD install prefix") mark_as_advanced(BRLCAD_PREFIX) +# If we've got a Release build with a Debug path or vice versa, warn about it +# A "make install" of a Release build into a dev install directory or vice +# versa is going to result in an install that doesn't respect BRL-CAD standard +# naming conventions +if("${CMAKE_BUILD_TYPE}" MATCHES "Release" AND ${CMAKE_INSTALL_PREFIX} STREQUAL "/usr/brlcad/dev-${BRLCAD_VERSION}") + message(WARNING "\nInstallation directory (CMAKE_INSTALL_PREFIX) is set to /usr/brlcad/dev-${BRLCAD_VERSION}, but build type is set to Release!\n") +endif("${CMAKE_BUILD_TYPE}" MATCHES "Release" AND ${CMAKE_INSTALL_PREFIX} STREQUAL "/usr/brlcad/dev-${BRLCAD_VERSION}") +if("${CMAKE_BUILD_TYPE}" MATCHES "Debug" AND ${CMAKE_INSTALL_PREFIX} STREQUAL "/usr/brlcad/rel-${BRLCAD_VERSION}") + message(WARNING "\nInstallation directory (CMAKE_INSTALL_PREFIX) is set to /usr/brlcad/rel-${BRLCAD_VERSION}, but build type is set to Debug!\n") +endif("${CMAKE_BUILD_TYPE}" MATCHES "Debug" AND ${CMAKE_INSTALL_PREFIX} STREQUAL "/usr/brlcad/rel-${BRLCAD_VERSION}") #--------------------------------------------------------------------- # The following logic is what allows binaries to run successfully in This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |