From 43b73602f1847431adb68e6019b5b0bf269137d3 Mon Sep 17 00:00:00 2001 From: "Troy D. Straszheim" Date: Sat, 31 Jan 2009 18:44:38 +0000 Subject: Dont mangle version into include directory name when making package if BUILD_VERSIONED is off. [SVN r50930] --- CMakeLists.txt | 26 ++++++++++++++++++-------- 1 file changed, 18 insertions(+), 8 deletions(-) (limited to 'CMakeLists.txt') diff --git a/CMakeLists.txt b/CMakeLists.txt index d404928ab8..f0aecfea0f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -103,6 +103,12 @@ option(BUILD_SINGLE_THREADED "Whether to build single-threaded libraries" ${BUILD_SINGLE_THREADED_DEFAULT}) option(BUILD_MULTI_THREADED "Whether to build multi-threaded libraries" ON) +if(UNIX) + option(BUILD_VERSIONED "Add versioning information to names of built files" OFF) +else(UNIX) + option(BUILD_VERSIONED "Add versioning information to names of built files" ON) +endif(UNIX) + # For now, we only actually support static/dynamic run-time variants for # Visual C++. Provide both options for Visual C++ users, but just fix # the values of the variables for all other platforms. @@ -128,17 +134,21 @@ boost_add_extra_variant(PYTHON_NODEBUG PYTHON_DEBUG) ########################################################################## # Installation # ########################################################################## -if(BOOST_VERSION_SUBMINOR GREATER 0) - set(BOOST_HEADER_DIR +if(BUILD_VERSIONED) + if(BOOST_VERSION_SUBMINOR GREATER 0) + set(BOOST_HEADER_DIR "include/boost-${BOOST_VERSION_MAJOR}_${BOOST_VERSION_MINOR}_${BOOST_VERSION_SUBMINOR}") -else(BOOST_VERSION_SUBMINOR GREATER 0) - set(BOOST_HEADER_DIR + else(BOOST_VERSION_SUBMINOR GREATER 0) + set(BOOST_HEADER_DIR "include/boost-${BOOST_VERSION_MAJOR}_${BOOST_VERSION_MINOR}") -endif(BOOST_VERSION_SUBMINOR GREATER 0) + endif(BOOST_VERSION_SUBMINOR GREATER 0) +else(BUILD_VERSIONED) + set(BOOST_HEADER_DIR "include/") +endif(BUILD_VERSIONED) install(DIRECTORY boost - DESTINATION ${BOOST_HEADER_DIR} - PATTERN "CVS" EXCLUDE - PATTERN ".svn" EXCLUDE) + DESTINATION ${BOOST_HEADER_DIR} + PATTERN "CVS" EXCLUDE + PATTERN ".svn" EXCLUDE) # # TDS 20080526: Getting a segfault here even with the ifs. At r45780, with these lines # uncommented: -- cgit v1.2.1