diff options
28 files changed, 1510 insertions, 48 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index c9ff2fc..b1d5930 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -422,26 +422,13 @@ ENDIF() # The main section of the CMakeLists file # #----------------------------------------------------------------------- -# The CMake version number. -SET(CMake_VERSION_MAJOR 2) -SET(CMake_VERSION_MINOR 8) -SET(CMake_VERSION_PATCH 7) -#SET(CMake_VERSION_TWEAK 0) -#SET(CMake_VERSION_RC 1) - -# Releases define a tweak level. -IF(DEFINED CMake_VERSION_TWEAK) +INCLUDE(Source/CMakeVersion.cmake) +# Releases define a small tweak level. +IF("${CMake_VERSION_TWEAK}" VERSION_LESS 20000000) SET(CMake_VERSION_IS_RELEASE 1) SET(CMake_VERSION_SOURCE "") ELSE() SET(CMake_VERSION_IS_RELEASE 0) - - # Use the date as the tweak level. - INCLUDE(${CMake_SOURCE_DIR}/Source/kwsys/kwsysDateStamp.cmake) - SET(CMake_VERSION_TWEAK - "${KWSYS_DATE_STAMP_YEAR}${KWSYS_DATE_STAMP_MONTH}${KWSYS_DATE_STAMP_DAY}" - ) - INCLUDE(${CMake_SOURCE_DIR}/Source/CMakeVersionSource.cmake) ENDIF() diff --git a/ChangeLog.manual b/ChangeLog.manual index f672b80..691ff94 100644 --- a/ChangeLog.manual +++ b/ChangeLog.manual @@ -1,3 +1,595 @@ +Changes in CMake 2.8.8 (since 2.8.8-rc2) +---------------------------------------- +Brad King (1): + CheckIncludeFiles: Shorten check description message + +David Cole (3): + CPackNSIS: Rewrite variable documentation to make it more readable. + OS X: Use correct extra path when searching for applicaton bundles (#13066) + OS X: Mark find_program results as advanced + +Eric NOULARD (1): + Fix some doc typo and add an undocumented var. + +Kashif Rasul (1): + OS X: Use OSX_DEVELOPER_ROOT for app search path (#13066) + +Rolf Eike Beer (1): + FindBoost: add support for 1.49 and 1.50 + +Changes in CMake 2.8.8-rc2 (since 2.8.8-rc1) +-------------------------------------------- +Alex Neundorf (4): + make cmLocalGenerator::EscapeForCMake() static + automoc: fix #13018, proper cmake escaping to avoid false rebuilds + automoc: add define to test which caused bug #13018 + fix #13054: support OBJECT libraries in Eclipse + +Ben Boeckel (1): + Create granular targets for Ninja generators too + +Brad King (6): + CTest.UpdateHG: Fix repo URL for leading slash + Always compile sources with known language + Classify known header file extensions as headers + VS: Add CMakeLists.txt re-run rules at start of generation + Test generated module .def files + Ninja: Fix module .def file path conversion + +David Cole (2): + CMake: Clarify SUFFIX target property documentation. + Xcode: Pay attention to custom configuration types (#13082) + +Peter Collingbourne (1): + Ninja: Substitute <OBJECT> and <CMAKE_C_COMPILER> in depfile flags + +Rolf Eike Beer (2): + FILE: mention that TO_CMAKE_PATH also handles list delimiters + FIND_LIBRARY: document FIND_LIBRARY_USE_LIB64_PATHS + +Sean McBride (1): + automoc: include <unistd.h> on Apple to get pathconf + +Tom Hughes (1): + Override topdir from rpm command line seems necessary on Amazon linux. + +Changes in CMake 2.8.8-rc1 (since 2.8.7) +---------------------------------------- +Aaron C. Meadows (1): + Visual Studio: Allow setting Single Byte Character Set (#12189) + +Alex Neundorf (34): + GNUInstallDirs: add support for Debian multiarch + FindRuby: fix usage of RUBY_VERSION_MAJOR (#12172) + FindRuby: add more possible library names (for ubuntu, #12172) + FindRuby.cmake: add more debug output + fix FeatureSummary for REQUIRED packages, they were reported as OPTIONAL + FindGetText: fix multiple targets with the same name problem (CMP0002) + fix #6976: FindX11 also searches for X11_Xxf86vm_LIB + GenerateExportHeader: use double quotes around _gcc_version + -remove trailing whitespace + -don't pull in CheckTypeSize.cmake from the cmake which is being built + bootstrap: move while() and endwhile() into the bootstrap build + Check*.cmake: Expand imported targets in CMAKE_REQUIRED_LIBRARIES + find_package: print error if an invalid CONFIGS name is used + find_package: rename NoModule to UseFindModules + find_package: improve error message when no Find module is present + find_package: add MODULE mode to use only Find-modules + find_package: add CONFIG mode keyword alias for NO_MODULE + find_package: mention requested version number in error message + add CMakePackageConfigHelpers: configure_package_config_file() + wrap write_basic_config_version_file as write_basic_package_version_file() + find_package: error out if REQUIRED Config has not been found + write_basic_package_version_file(): improve documentation + write_basic_package_version_file: add ExactVersion mode + WriteBasicConfigVersionFile: add test for ExactVersion mode + find_package: allow <pkg>Config.cmake to set <pkg>_FOUND to FALSE + find_package: add test for setting Foo_FOUND to FALSE in a Config file + find_package: additional test for checking the error message + find_package: add OPTIONAL_COMPONENTS keyword + FPHSA(): add missing "]" to documentation + find_package: add documentation for OPTIONAL_COMPONENTS + FPHSA(): add HANDLE_COMPONENTS option + add macro check_required_components() to configure_package_config_file() + Eclipse: fix #13036, make version detection work with symlinks + guard eCos.cmake against multiple inclusion (#12987) + +Alexandru Ciobanu (2): + CTest: Detect Xcode error "Command ... failed with exit code" + CTest: Match valgrind errors with "points to" (#12922) + +Alexey Ozeritsky (1): + FindBLAS/FindLAPACK: Work with MKL version 10.3 (#12924, #12925) + +Artur Kedzierski (1): + Add CURL_CA_BUNDLE option for SSL support (#12946) + +Bill Hoffman (12): + Add CMakeAddFortranSubdirectory to use MinGW gfortran in VS + VSGNUFortran: Add special case for SunPro Fortran runtime library + VSGNUFortran: Disable test in special cases + CMakeAddFortranSubdirectory: Make IMPORTED targets GLOBAL + Use upgraded qt on linux build machine. + Teach CTest what a ninja error looks like. + Allow two cmake_add_fortran_subdirectory calls in the same project. + Add ability to include a file in a project via a cache variable. + Fix typo in error message, and remove redundent test. + Ninja: Add a cache option CMAKE_ENABLE_NINJA to enable the ninja generator. + Ninja: Fix for PDB files with spaces in the path. + Fix FindMPI for the intel compiler on linux by looking in implict directories. + +Bjoern Ricks (1): + Fix crash if app bundle executeable couldn't be found + +Brad King (138): + CheckCCompilerFlag: Generalize "but not for C" case (#12633) + complex: Remove ancient unused ComplexRelativePaths test + complex: Sync Tests/ComplexOneConfig with Tests/Complex + complex: Remove dynamic loader tests + complex: Move GeneratedFileStream test to CMakeLibTests + complex: Simplify test for single-character exe name + complex: Move cmSystemTools::UpperCase test to CMakeLibTests + complex: Remove test dependence on cmSystemTools + complex: Remove unused option to test CMakeLib + Intel: Fix Windows per-config Fortran flags (#12642) + libarchive: Remove our copy to make room for new import + libarchive: Add .gitattributes for indentation with tab + libarchive: Add README-CMake.txt + libarchive: Do not build subdirectories not in reduced snapshot + libarchive: Remove -Wall -Werror from build with GNU + libarchive: Build one static cmlibarchive for CMake + libarchive: Include cm_zlib.h to get zlib used by CMake + Handle libarchive API change in archive_read_data_block + Configure libarchive build within CMake + libarchive: Install COPYING with CMake documentation + libarchive: Port to OSF operating system + libarchive: Fix typo in CheckFileOffsetBits + libarchive: Implement custom lseek for Borland + libarchive: Declare mbstate_t and wcrtomb for Borland + libarchive: Cast constants to int64_t instead of using LL suffix + libarchive: Workaround case-insensitive symbols on Borland + libarchive: Clean up configuration within CMake build + libarchive: Cast mode constants to mode_t in case it is signed + libarchive: Fix Windows NT API usage in VS 6 + libarchive: Suppress compiler warnings + libarchive: Fix var decl after statement in archive_string.c + libarchive: Do not use ST_NOATIME if not defined + libarchive: Check for 'struct statvfs' member 'f_iosize' + libarchive: Do not use MNT_NOATIME if not defined + libarchive: Use Apple copyfile.h API only if available + libarchive: Remove hard-coded build configuration + libarchive: Cleanup after ZLIB_WINAPI check + libarchive: Define _XOPEN_SOURCE=500 on HP-UX + libarchive: Include linux/types.h before linux/fiemap.h + libarchive: Rename isoent_rr_move_dir parameter isoent => curent + libarchive: Suppress PathScale compiler warnings + libarchive: Avoid bogus conversion warning from PGI compiler + libarchive: Set .gitattributes to allow trailing whitespace + libarchive: Update README-CMake.txt for new snapshot + libarchive: Restore CMake 2.6.3 as minimum version + bootstrap: Update copyright year in version report + bootstrap: Re-implement command line option processing + bootstrap: Forward options after '--' to cmake + VS10: Fix /pdb option vcxproj element name (#12328) + Add framework to detect compiler version with its id (#12408) + Detect GNU compiler version with its id (#6251) + Detect MSVC compiler version with its id + Detect Intel compiler version with its id (#11937) + Detect Borland compiler version with its id + Detect IBM XL compiler version with its id + Detect PGI compiler version with its id + Detect Clang compiler version with its id + Detect Watcom compiler version with its id + Detect SunPro compiler version with its id + Detect HP compiler version with its id + Document compiler version macro formats used for detection + Detect SGI MIPSpro compiler version with its id + ExternalProject: Fix git.cmd version detection + ExternalProject: Update copyright year + Include bzlib.h consistently across CMake build (#10950) + FindMPI: Append MPI C++ library correctly in non-compiler case (#12874) + Add infrastructure for CMake-only tests + Tolerate cycles in shared library link interfaces (#12647) + cmInstallCommand: Fix line length for style + cmake-mode.el: Indent after multiline argument (#12908) + Clarify IMPORTED_ target property documentation + Optionally allow IMPORTED targets to be globally visible + Add test covering imported target scope rules + VS: Simplify ;-separated attribute value parsing + Fix CXX/Fortran MODULE flags when enabled before C (#12929) + Remove unused test code + Allow directory names containing '=' and warn if necessary (#12934) + Add CheckLanguage module + CMakeAddFortranSubdirectory: Allow full paths to directories + CMakeAddFortranSubdirectory: Fix documentation format and typos + CMakeAddFortranSubdirectory: Find gfortran in PATH + CMakeAddFortranSubdirectory: Validate gfortran architecture + CMakeAddFortranSubdirectory: Always parse arguments + CMakeAddFortranSubdirectory: Add NO_EXTERNAL_INSTALL option + libarchive: Workaround mbsnrtowcs assertion failure on old glibc + Recognize OpenBSD versioned .so names (#12954) + try_compile: Use random executable file name (#12957) + Rename Modules/Platform/Windows-{Borland => Embarcadero}.cmake + Recognize Embarcadero compiler (#12604) + Factor cmInstallType out of cmTarget::TargetType + Add infrastructure for CMakeCommands tests + find_package: Reject mixed use of MODULE- and CONFIG-only options + find_package: Optionally warn when implicitly using Config mode + find_package: Test error and warning messages in failure cases + bootstrap: Convert MSYS paths to Windows format (#13001) + CTest.UpdateHG: Fix repo URL for local filesystem (#13001) + cmcurl: Do not hard-coded Windows check results for MinGW (#13001) + CheckSourceTree: Remove CVS checkout support (#13001) + Fix MSYS CVS local test repo path format (#13001) + find_package: Test that REQUIRED aborts processing correctly + Remove unused partial OBJECT_FILES property implementation + VS: Simplify object name computation + Hide Makefile local object info inside local generator + KWIML: Make test_INT robust to #define-d int#_t and INT#_C + Add stronger infrastructure for CMake-only tests + Use generalized RunCMake test infrastrucure for find_package test + Use generalized RunCMake test infrastrucure for build_command test + Document Fortran_MODULE_DIRECTORY as OUTPUT only (#13034) + Ninja: Constify use of cmCustomCommand + Ninja: Avoid using 'this' in member initializers + Write CMakeCache.txt atomically (#13040) + Add cmGeneratorTarget to represent a target during generation + Create a cmGeneratorTarget for each cmTarget during generation + Simplify cmMakefileTargetGenerator using cmGeneratorTarget + Simplify cmVisualStudio10TargetGenerator using cmGeneratorTarget + Pre-compute object file names before Makefile generation + Pre-compute object file names before VS project generation + Remove unused cmSourceGroup method + Rename/constify build-time config placeholder lookup + Pre-compute and store target object directory in cmGeneratorTarget + Add OBJECT_LIBRARY target type + Build object library targets in Makefiles + Build object library targets in VS + Add $<TARGET_OBJECTS:...> expression to use an object library + Test OBJECT library success cases + Test OBJECT library failure cases + Test OBJECT library language propagation + Test OBJECT library use without other sources + Document OBJECT library type in add_library command + Simplify cmNinjaTargetGenerator using cmGeneratorTarget + Pre-compute object file names before Ninja generation + Build object library targets in Ninja + Ninja: Honor $<TARGET_OBJECTS:...> source expressions + find_package: Test rejection of required+optional components + Simplify cmVisualStudio10TargetGenerator source classification + VS10: Fix external objects generated outside target (#13047) + Fix ObjectLibrary test on Watcom + KWIML: Avoid conflict with C++11 user-defined literals + +Christian Andersson (1): + FindPythonLibs: Search for single-user installs on Windows + +Christopher Sean Morrison (1): + cmake-mode.el: Make indentation case-insensitive (#12995) + +Clinton Stimpson (14): + GetPrerequisites: Add support for @rpath on Mac OS X. + GetPrerequisites: Add support for @rpath on Mac OS X. + GetPrerequisites: Add test for @rpath support. + Fix new BundleUtilities test failure on Mac 10.4.x + Fix BundleUtilities test failure with space in build path. + cmake-gui: Improve interrupt granularity to fix bug 12649. + FindQt4: clarify warning message about incorrect Qt installation. + FindQt4: Add include directories for lupdate. + Fix paths/hints for finding qtmain. + DragNDrop: Fix problem with relocated files in Xcode 4.3 + Add test for DeployQt4.cmake + Fix for Qt4Deploy on some test machines. + Remove QtGui dependency in Qt4Deploy test and verify QtSql existance. + DeployQt4: Add path to Qt dlls on Windows. + +Daniel Nelson (1): + CPack Add top level directory in component install for Archive Generators + +David Cole (33): + Begin post-2.8.7 development + Release: Increase timeout for slow-testing cygwin build + Update dashmacmini2 release script to use Qt 4.6.3 + Update dashmacmini2 release script to use Qt 4.8.0 + Tests: Update drop site value for the Trilinos contract test + Update version of Qt for dashmacmini5 produced release binaries + CTestCustom: Suppress clang warning on the dashboard + CMake: Eliminate cmMakefile::IncludeDirectories + Remove cmMakefile::GetIncludeDirectories + Make search paths ordered and unique + Call ExpandVariablesInString for each target's INCLUDE_DIRECTORIES + Update the documentation regarding INCLUDE_DIRECTORIES. + Fix compiler error reported on older Borland dashboard. + Fix compiler warning reported on older Borland dashboard. + Fix shadowed variable warning on dashboard results + Remove trailing white space + Use correct "requires" line in cygwin setup hint file + VS6: Avoid _MBCS define when _SBCS is defined (#12189) + VS6: Avoid SBCS test on VS6 (#12189) + Suppress warnings occurring on the dashboards using the PGI compiler. + CPack: Fix retry logic when calls to hdiutil fail + Ninja: CMake: Adapt Ninja generator for per-target include dirs + Ninja: Add friend struct so it can access the private ConvertToNinjaPath. + Xcode: Detect new default locations of Xcode 4.3 bits and pieces (#12621) + CPack: Use real path to PackageMaker to find its version file (#12621) + Xcode: Re-factor code into GetObjectsNormalDirectory method + Xcode: Re-factor some existing methods into "FromPath" variants + Add a default source group for object files. + Allow txt files as ExtraSources in object library targets + Pre-compute object file names before Xcode generation + Build object library targets in Xcode + Xcode: Honor $<TARGET_OBJECTS:...> source expressions + Tests: Relax restrictions on version variable contents + +Deborah Pickett (1): + CPackRPM flag direcories with %dir in the generated spec file + +Droscy (1): + FindCxxTest: Add support for CxxTest 4 (#13022) + +Eric NOULARD (41): + Document undocumented (but existing) cpack options (fix #0010134) + Enhance bash completion file for cmake and ctest + Do not add the content of a file if it's a symlink. + CPackArchive restore default behavior and provide new variable. + CPackNSIS fix #0012935 switch from LOG_WARNING to avoid final error. + CPack begin the implementation of --help-command* and --help-variables* + Implement simple CMake script comment markup language. + CPack Documentation extraction from CMake script begins to work + Update bash completion file in order to handle new CPack doc options. + Suppress unused var, beautify code, avoid 1 extra newline. + Fix potential bad memory access, thanks to Eike + Calm down compiler warning about unused var + Really avoid compiler warning about unused vars + Fix another compiler warning due to a typo + Make the load of script documentation more efficient and dynamic. + Example of builtin variable documentation (i.e. only used in C++ source code). + Add missing section markup for CPackComponent + Create getDocumentedModulesListInDir which may be used in other context. + Fix non existent std::string::clear on VS6 + Avoid discovering system infos for documentation. Adding some path is enough. + Dynamically add documentation section specified in documented script. + Add structured documentation for NSIS + Add structure documentation for CPack Bundle generator + Suppress unecessary (now empty) doc sections + Correct copy/paste section name mistake + Put CPack DMG and PackageMaker doc in separate files + More documentation concerning CPack Components + Fix typo in end markup + Try to fix compile error on Win32-vs70 + Do not build RPM if path of the build tree contains space + Fix layout of the CPack Bundle documentation + Fix CPack Drag and Drop generator documentation layout. + Review and update CPack variable documentation. + Update CPackConfig template. + Provide template for CPack Cygwin generator specific variables. + Update CPack PackageMaker variable doc layout + Typo: Add missing ##end for ##module + Fix some typos in CPACK_SET_DESTDIR doc + Add some missing CPACK_NSIS_xxx doc and move some to common CPack section. + CPack STGZ put execute permission on all packages files (component case) + Handle CPACK_MONOLITHIC_INSTALL in some rare use cases. + +Eugene Golushkov (1): + VS: Add support for WinRT project properties (#12930) + +James Bigler (1): + Added support for curand, cusparse, npp, nvcuenc and nvcuvid libraries. + +Jason Erb (1): + FindwxWidgets: Add webview library (#12636) + +LibArchive Upstream (2): + libarchive 3.0.1-r3950 (reduced) + libarchive 3.0.2-r4051 (reduced) + +Matthias Kretz (1): + Improve checks for Open64 and g++ incompatible flags (#12119) + +Mattias Helsing (1): + CPack: Fix NSIS handling of privileged users (#12923) + +Michael Wild (1): + GenerateExportHeader: Fix wrong use of IS_ABSOLUTE (#12645) + +Mike McQuaid (5): + Don't use QT_LIBRARIES_PLUGINS by default. + Fix mismatched arguments. + Fix bad plugin paths. + Ensure libs are passed to BundleUtilities. + Fix plugin installation issues. + +Modestas Vainius (3): + various typo and formatting fixes in manual pages (#12975) + KWIML: Teach ABI.h that MIPS is biendian + Tests: Escape metachars before embedding paths into the regex (#12999) + +Nicolas Despres (5): + ccmake: Factor clear line. + ccmake: Extend clear line. + java: Factor jar output path. + java: Add CMAKE_JAVA_TARGET_OUTPUT_DIR optional variable. + java: Add CMAKE_JAVA_JAR_ENTRY_POINT optional variable. + +Peter Collingbourne (19): + Add cmSystemTools::TrimWhitespace function + Add executable with exports flag support to cmLocalGenerator::GetTargetFlags + Provide dependency file flags to generator + Ninja: Add the Ninja generator + Ninja: Fix a 79-col violation + Ninja: Remove some default arguments + Ninja: Appease various compilers + Ninja: Partially revert "win fixes: escape back slash/colon, use cd. as cmd.exe nop" + Ninja: Identifier encoding rules for ' ' and ':' + Ninja: Backslash rules for Windows + Ninja: Shell encode paths used in "cd" commands + Ninja: Shell encode various CMake invocations + Ninja: Shell encode the command used in custom commands + Ninja: Import library support for Windows + Ninja: Add a missed license header + Ninja: Use cmSystemTools::ExpandListArgument to split compile/link commands + Ninja: Remove an unnecessary variable + Ninja: add support for OBJECT_OUTPUTS, fix PrecompiledHeader test case + Ninja: shell escape $(CMAKE_SOURCE_DIR) and $(CMAKE_BINARY_DIR) + +Peter Kuemmel (12): + Find VC Express during default generator selection (#12917) + Ninja: win fixes: escape back slash/colon, use cd. as cmd.exe nop + Ninja: don't define MSVC_IDE when using the ninja generator + Ninja: also build ninja support on Windows + Ninja: add some hacks for Windows + Ninja: disable unfinished Windows ninja support + Ninja: mark the Windows specific hacks with a comment only + Ninja: windows msvc: create for each target a .pdb file + Ninja: ensure the output dir exists at compile time + Ninja: add .def file support + Ninja: add /DEF: flag to linker call + Ninja: Fix <OBJECT_DIR> substitution + +Philip Lowman (5): + FindProtobuf: Merge patch that allows extra import dirs + FindProtobuf: Update documentation comment for 2.8.8 + Findosg: New modules for osgQt and osgPresentation + FindALSA: Fix incorrect include path detection + FindALSA: Fix version detection after last commit + +Rolf Eike Beer (95): + remove reference to CVS directory when installing files + CheckSymbolExists: force the compiler to keep the referenced symbol + add a test for Check{,CXX}SymbolExists + FindOpenSSL: improve version number handling + FindOpenSSL: only try to parse opensslv.h if it exists + FindOpenSSL: also parse version number define with uppercase letters + GenerateExportHeader test: add newlines before end of file + add a test that loops through most Find* modules + AllFindModules test: keep complete output + AllFindModules test: also check Qt3 modules if Qt4 is not found + FindPythonInterp: make version selectable + FindPythonInterp: fix version parsing + LoadCommand test: cleanup + FindThreads: Try pthreads with no special option first (#11333) + fix uninitialized var in if(NOT foo bar STREQUAL "foo bar") + use pkg_check_modules() quiet in other modules + FindLibXml2: support version selection + FindGnuTLS: partly support version selection + FindGit: support version number + FindCups: major overhaul + FindEXPAT: support version number + FindCURL: support version selection + FindFLEX: fix version parsing for old flex versions + FindFLEX: fix version parsing when the executable is quoted + FindJasper: find debug libraries + FindJasper: support version number + FindBZip2: add support for version checking + FindBZip2: add support for debug libraries (#12867) + FindImageMagick: make use of more FPHSA features + FindPNG: support version selection + FindRuby: do not blindly set version to 1.8.0 + FindTclsh: support version selection + SelectLibraryConfigurations: do not output identical configurations + FindLua51: add version support + FindTIFF: support version selection + FindCURL: detect version number also for older versions + FindLibXml2: detect version when PkgConfig is not used + FindPostgreSQL: support version selection + FindOpenSSL: properly parse the hex version components + FindBISON: add a version expression for GNU Bison 1.x + FindPythonInterp: try harder to get a version number + FindJasper: fix library name + FindGnuplot: add version selection + FindALSA: support version selection + FindGettext: support version selection + CheckCXXCompilerFlag test: make it a CMakeOnly test + CMakeOnly.AllFindModules: clean up the Qt3/Qt4 code + CMakeOnly.AllFindModules: always check FindQt + CMakeOnly.AllFindModules: suppress two modules from testing + CMakeOnly.AllFindModules: require version for some modules + CheckIncludeFiles: fix status output + FindPerl{,Libs}: move version detection into FindPerl + FindLibArchive: support version selection + FindX11: also search for Xmu (#12447) + detect "pgfortran" as PGI Fortran compiler (#12425) + FindSDL*: use FPHSA (#12467) + AllFindModules test: do not enforce GNUPLOT version + FindPerlLibs: properly detect libperl on Windows (#12224) + CTest: mark all gcov covered files as covered + FindGLUT: honor REQUIRED (#12466) + FindRuby: clean up querying variables from Ruby + FindLibXslt: support version selection + Tests: document where to put tests + FindPkgConfig: support version selection of pkg-config itself + fix the same typos as found by Debian in other places, too + Find_library(): allow searching for versioned shared objects + FindFreetype: support version selection + AllFindModules test: expect more modules to have a version number available + FindOpenMP: do not fail if only C or CXX is enabled (#11910) + FindOpenMP: try the most likely flags first + FindOpenMP: simplify check for enabled languages + UseSWIG: clean up string compares + FindPython{Interp,Libs}: document Python_ADDITIONAL_VERSIONS as input + FindPythonLibs: make the version selection work as for PythonInterp + FindPythonLibs: get the exact version of the found library (#3080) + FindPythonLibs: put debug libraries into PYTHON_LIBRARIES + FindPythonLibs: stop scanning when libraries are found + Check{C,CXX}CompilerFlag: detect ICC error messages + GenerateExportHeader: remove unneeded code + GenerateExportHeader: improve compiler identification + FindOpenSceneGraph: give every message() with an explicit level + FindHSPELL: set HSPELL_VERSION_STRING + FindImageMagick: fix fail if no components were given + FindPythonInterp: rework the version detection + document when version detection will not work + AllFindModules test: once again expand version checking + improve error message on a stray "endwhile()" + add testcases for while()/endwhile() errors + reflect that the QtAutomoc depends on QtGui + FindQt3: fix warning when Qt3 is not found + FindQt3: fix version extraction for versions with letters + FindQt3: let FPHSA handle the version selection + FindQt3: fix detection of Qt3 include directory + AllFindModules test: do not require TCLSH version + add test for get_property() errors + +Stephen Kelly (13): + Fix typos arguement -> argument. + Exit the loop when we have determined the language. + Add whitespace after '.' in CMAKE_SKIP_RPATH docs. + Fix documented function signature to match reality. + Add default initializers for WIN32_EXECUTABLE and MACOSX_BUNDLE + Add an option to skip RPATH during installation. + Refactor GetIncludeFlags to take includes instead of fetching them + Make it safe to call this method without creating duplicates. + Remove include flags memoization. + Add API to get the ordered includes for a target. + Keep the INCLUDE_DIRECTORIES target property up to date. + Extract and use the INCLUDE_DIRECTORIES target properties. + Fix some typos in the docs comments. + +Yury G. Kudryashov (23): + FindDoxygen: add DOXYGEN_VERSION variable + cmInstallCommand: Fix indentation error + cmInstallCommand: Remove duplicated sentence from docs + FindPkgConfig: respect REQUIRED (#12620) + FindPackageHandleStandardArgs: fix documentation + Remove unused file cmake.1 + Fix typo in documentation + Drop if(...) check because condition is always true + CMakeFindPackageMode: fix 32/64bit detection if 'file' is a symlink + Run vim spellcheck on some files + cmPropertyDefinition::IsChained is const + Add 'const' qualifier to some cmCommand members + doxygen: cmPropertyDefinition + doxygen: Improve API docs of GetRealDependency + doxygen: Use proper syntax to document enum + doxygen: Small fixes in cmake.h apidocs + doxygen: fix some comments in cmPolicies.h + doxygen: remove a few comments + doxygen: review cmake.h + doxygen: MathCommand is not about string operators + Rename UsedCommands to FinalPassCommands + Remove UnionsAvailable member from 2 classes + Remove cmExprParserHelper::SetLineFile() + Changes in CMake 2.8.7 (since 2.8.7-rc2) -------------------------------------------- None diff --git a/Modules/FindPythonLibs.cmake b/Modules/FindPythonLibs.cmake index fcd0838..591b3e6 100644 --- a/Modules/FindPythonLibs.cmake +++ b/Modules/FindPythonLibs.cmake @@ -82,7 +82,12 @@ FOREACH(_CURRENT_VERSION ${_Python_VERSIONS}) ENDIF(WIN32) FIND_LIBRARY(PYTHON_LIBRARY - NAMES python${_CURRENT_VERSION_NO_DOTS} python${_CURRENT_VERSION} + NAMES + python${_CURRENT_VERSION_NO_DOTS} + python${_CURRENT_VERSION}mu + python${_CURRENT_VERSION}m + python${_CURRENT_VERSION}u + python${_CURRENT_VERSION} PATHS [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\${_CURRENT_VERSION}\\InstallPath]/libs [HKEY_CURRENT_USER\\SOFTWARE\\Python\\PythonCore\\${_CURRENT_VERSION}\\InstallPath]/libs @@ -120,12 +125,14 @@ FOREACH(_CURRENT_VERSION ${_Python_VERSIONS}) [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\${_CURRENT_VERSION}\\InstallPath]/include [HKEY_CURRENT_USER\\SOFTWARE\\Python\\PythonCore\\${_CURRENT_VERSION}\\InstallPath]/include PATH_SUFFIXES + python${_CURRENT_VERSION}mu + python${_CURRENT_VERSION}m + python${_CURRENT_VERSION}u python${_CURRENT_VERSION} ) - # For backward compatibility, set PYTHON_INCLUDE_PATH, but make it internal. - SET(PYTHON_INCLUDE_PATH "${PYTHON_INCLUDE_DIR}" CACHE INTERNAL - "Path to where Python.h is found (deprecated)") + # For backward compatibility, set PYTHON_INCLUDE_PATH. + SET(PYTHON_INCLUDE_PATH "${PYTHON_INCLUDE_DIR}") IF(PYTHON_INCLUDE_DIR AND EXISTS "${PYTHON_INCLUDE_DIR}/patchlevel.h") FILE(STRINGS "${PYTHON_INCLUDE_DIR}/patchlevel.h" python_version_str diff --git a/Source/CMakeLists.txt b/Source/CMakeLists.txt index f9d1c03..c01c490 100644 --- a/Source/CMakeLists.txt +++ b/Source/CMakeLists.txt @@ -355,18 +355,18 @@ IF (WIN32) ENDIF(NOT UNIX) ENDIF (WIN32) -# turn on Ninja by default +# Turn on Ninja by default, but disable it +# on platforms where it does not pass all tests. +# Enforce Ninja support by setting CMAKE_USE_NINJA set(_CMAKE_DEFAULT_NINJA_VALUE TRUE) -# turn it off for platforms where it does not pass all the -# tests if(WIN32 OR APPLE) SET(_CMAKE_DEFAULT_NINJA_VALUE FALSE) endif() SET(CMAKE_ENABLE_NINJA ${_CMAKE_DEFAULT_NINJA_VALUE} CACHE BOOL - "Enable the ninja generator for CMake. currently not fully working for Windows or OSX") + "Enable the ninja generator for CMake. On Windows and OSX broken") MARK_AS_ADVANCED(CMAKE_ENABLE_NINJA) IF(CMAKE_ENABLE_NINJA) - MESSAGE(STATUS "Enable ninja generator.") + MESSAGE(STATUS "Ninja generator enabled.") SET(SRCS ${SRCS} cmGlobalNinjaGenerator.cxx cmGlobalNinjaGenerator.h @@ -382,7 +382,7 @@ IF(CMAKE_ENABLE_NINJA) ) ADD_DEFINITIONS(-DCMAKE_USE_NINJA) ELSE() - MESSAGE(STATUS "Disable ninja generator.") + MESSAGE(STATUS "Ninja generator disabled, enforce with -DCMAKE_ENABLE_NINJA=ON") ENDIF() # create a library used by the command line and the GUI diff --git a/Source/CMakeVersion.bash b/Source/CMakeVersion.bash new file mode 100755 index 0000000..126adba --- /dev/null +++ b/Source/CMakeVersion.bash @@ -0,0 +1,7 @@ +#!/usr/bin/env bash +# Update the version component if it looks like a date or -f is given. +if test "x$1" = "x-f"; then shift ; n='*' ; else n='\{8\}' ; fi +if test "$#" -gt 0; then echo 1>&2 "usage: CMakeVersion.bash [-f]"; exit 1; fi +sed -i -e ' +s/\(^SET(CMake_VERSION_TWEAK\) [0-9]'"$n"'\(.*\)/\1 '"$(date +%Y%m%d)"'\2/ +' "${BASH_SOURCE%/*}/CMakeVersion.cmake" diff --git a/Source/CMakeVersion.cmake b/Source/CMakeVersion.cmake new file mode 100644 index 0000000..33b8f04 --- /dev/null +++ b/Source/CMakeVersion.cmake @@ -0,0 +1,6 @@ +# CMake version number components. +SET(CMake_VERSION_MAJOR 2) +SET(CMake_VERSION_MINOR 8) +SET(CMake_VERSION_PATCH 8) +SET(CMake_VERSION_TWEAK 20120425) +#SET(CMake_VERSION_RC 1) diff --git a/Source/cmExtraCodeBlocksGenerator.cxx b/Source/cmExtraCodeBlocksGenerator.cxx index ccb17f0..5df8627 100644 --- a/Source/cmExtraCodeBlocksGenerator.cxx +++ b/Source/cmExtraCodeBlocksGenerator.cxx @@ -60,6 +60,9 @@ cmExtraCodeBlocksGenerator::cmExtraCodeBlocksGenerator() // disable until somebody actually tests it: // this->SupportedGlobalGenerators.push_back("MSYS Makefiles"); #endif +#ifdef CMAKE_USE_NINJA + this->SupportedGlobalGenerators.push_back("Ninja"); +#endif this->SupportedGlobalGenerators.push_back("Unix Makefiles"); } @@ -383,6 +386,7 @@ void cmExtraCodeBlocksGenerator case cmTarget::STATIC_LIBRARY: case cmTarget::SHARED_LIBRARY: case cmTarget::MODULE_LIBRARY: + case cmTarget::OBJECT_LIBRARY: { this->AppendTarget(fout, ti->first.c_str(), &ti->second, make.c_str(), makefile, compiler.c_str()); @@ -420,6 +424,7 @@ void cmExtraCodeBlocksGenerator case cmTarget::STATIC_LIBRARY: case cmTarget::SHARED_LIBRARY: case cmTarget::MODULE_LIBRARY: + case cmTarget::OBJECT_LIBRARY: case cmTarget::UTILITY: // can have sources since 2.6.3 { const std::vector<cmSourceFile*>&sources=ti->second.GetSourceFiles(); @@ -532,6 +537,31 @@ void cmExtraCodeBlocksGenerator } +// Write a dummy file for OBJECT libraries, so C::B can reference some file +std::string cmExtraCodeBlocksGenerator::CreateDummyTargetFile( + cmMakefile* mf, cmTarget* target) const +{ + // this file doesn't seem to be used by C::B in custom makefile mode, + // but we generate a unique file for each OBJECT library so in case + // C::B uses it in some way, the targets don't interfere with each other. + std::string filename = mf->GetCurrentOutputDirectory(); + filename += "/"; + filename += mf->GetLocalGenerator()->GetTargetDirectory(*target); + filename += "/"; + filename += target->GetName(); + filename += ".objlib"; + cmGeneratedFileStream fout(filename.c_str()); + if(fout) + { + fout << "# This is a dummy file for the OBJECT library " + << target->GetName() + << " for the CMake CodeBlocks project generator.\n" + << "# Don't edit, this file will be overwritten.\n"; + } + return filename; +} + + // Generate the xml code for one target. void cmExtraCodeBlocksGenerator::AppendTarget(cmGeneratedFileStream& fout, const char* targetName, @@ -570,7 +600,18 @@ void cmExtraCodeBlocksGenerator::AppendTarget(cmGeneratedFileStream& fout, } const char* buildType = makefile->GetDefinition("CMAKE_BUILD_TYPE"); - fout<<" <Option output=\"" << target->GetLocation(buildType) + std::string location; + if ( target->GetType()==cmTarget::OBJECT_LIBRARY) + { + location = this->CreateDummyTargetFile(const_cast<cmMakefile*>(makefile), + target); + } + else + { + location = target->GetLocation(buildType); + } + + fout<<" <Option output=\"" << location << "\" prefix_auto=\"0\" extension_auto=\"0\" />\n" " <Option working_dir=\"" << workingDir << "\" />\n" " <Option object_output=\"./\" />\n" @@ -728,7 +769,8 @@ int cmExtraCodeBlocksGenerator::GetCBTargetType(cmTarget* target) return 1; } } - else if ( target->GetType()==cmTarget::STATIC_LIBRARY) + else if (( target->GetType()==cmTarget::STATIC_LIBRARY) + || (target->GetType()==cmTarget::OBJECT_LIBRARY)) { return 2; } diff --git a/Source/cmExtraCodeBlocksGenerator.h b/Source/cmExtraCodeBlocksGenerator.h index 57751fc..e0a64ca 100644 --- a/Source/cmExtraCodeBlocksGenerator.h +++ b/Source/cmExtraCodeBlocksGenerator.h @@ -44,6 +44,8 @@ private: void CreateNewProjectFile(const std::vector<cmLocalGenerator*>& lgs, const std::string& filename); + std::string CreateDummyTargetFile(cmMakefile* mf, cmTarget* target) const; + std::string GetCBCompilerId(const cmMakefile* mf); int GetCBTargetType(cmTarget* target); std::string BuildMakeCommand(const std::string& make, const char* makefile, diff --git a/Source/cmNinjaNormalTargetGenerator.cxx b/Source/cmNinjaNormalTargetGenerator.cxx index 2bad32c..cf2b427 100644 --- a/Source/cmNinjaNormalTargetGenerator.cxx +++ b/Source/cmNinjaNormalTargetGenerator.cxx @@ -47,8 +47,7 @@ cmNinjaNormalTargetGenerator(cmTarget* target) { // on Windows the output dir is already needed at compile time // ensure the directory exists (OutDir test) - std::string outpath = target->GetDirectory(this->GetConfigName()); - cmSystemTools::MakeDirectory(outpath.c_str()); + EnsureDirectoryExists(target->GetDirectory(this->GetConfigName())); } } @@ -56,6 +55,21 @@ cmNinjaNormalTargetGenerator::~cmNinjaNormalTargetGenerator() { } +void +cmNinjaNormalTargetGenerator +::EnsureDirectoryExists(const std::string& dir) +{ + cmSystemTools::MakeDirectory(dir.c_str()); +} + +void +cmNinjaNormalTargetGenerator +::EnsureParentDirectoryExists(const std::string& path) +{ + EnsureDirectoryExists(cmSystemTools::GetParentDirectory(path.c_str())); +} + + void cmNinjaNormalTargetGenerator::Generate() { if (!this->TargetLinkLanguage) { @@ -380,13 +394,18 @@ void cmNinjaNormalTargetGenerator::WriteLinkStatement() } } + std::string path; if (!this->TargetNameImport.empty()) { - vars["TARGET_IMPLIB"] = this->GetLocalGenerator()->ConvertToOutputFormat( - targetOutputImplib.c_str(), cmLocalGenerator::SHELL); + path = this->GetLocalGenerator()->ConvertToOutputFormat( + targetOutputImplib.c_str(), cmLocalGenerator::SHELL); + vars["TARGET_IMPLIB"] = path; + EnsureParentDirectoryExists(path); } - vars["TARGET_PDB"] = this->GetLocalGenerator()->ConvertToOutputFormat( - this->GetTargetPDB().c_str(), cmLocalGenerator::SHELL); + path = this->GetLocalGenerator()->ConvertToOutputFormat( + this->GetTargetPDB().c_str(), cmLocalGenerator::SHELL); + vars["TARGET_PDB"] = path; + EnsureParentDirectoryExists(path); std::vector<cmCustomCommand> *cmdLists[3] = { &this->GetTarget()->GetPreBuildCommands(), @@ -413,7 +432,7 @@ void cmNinjaNormalTargetGenerator::WriteLinkStatement() // If we have any PRE_LINK commands, we need to go back to HOME_OUTPUT for // the link commands. if (!preLinkCmdLines.empty()) { - std::string path = this->GetLocalGenerator()->ConvertToOutputFormat( + path = this->GetLocalGenerator()->ConvertToOutputFormat( this->GetMakefile()->GetHomeOutputDirectory(), cmLocalGenerator::SHELL); preLinkCmdLines.push_back("cd " + path); diff --git a/Source/cmNinjaNormalTargetGenerator.h b/Source/cmNinjaNormalTargetGenerator.h index 1702caf..7acbe8f 100644 --- a/Source/cmNinjaNormalTargetGenerator.h +++ b/Source/cmNinjaNormalTargetGenerator.h @@ -35,6 +35,9 @@ private: void WriteObjectLibStatement(); std::vector<std::string> ComputeLinkCmd(); + void EnsureDirectoryExists(const std::string& dir); + void EnsureParentDirectoryExists(const std::string& path); + private: // Target name info. std::string TargetNameOut; diff --git a/Source/cmSystemTools.cxx b/Source/cmSystemTools.cxx index 1376a48..25975e0 100644 --- a/Source/cmSystemTools.cxx +++ b/Source/cmSystemTools.cxx @@ -104,6 +104,9 @@ public: private: HANDLE handle_; }; +#elif defined(__APPLE__) +#include <crt_externs.h> +#define environ (*_NSGetEnviron()) #endif bool cmSystemTools::s_RunCommandHideConsole = false; diff --git a/Source/cmTargetLinkLibrariesCommand.h b/Source/cmTargetLinkLibrariesCommand.h index be866c3..63114d2 100644 --- a/Source/cmTargetLinkLibrariesCommand.h +++ b/Source/cmTargetLinkLibrariesCommand.h @@ -64,7 +64,8 @@ public: "Specify libraries or flags to use when linking a given target. " "The named <target> must have been created in the current directory " "by a command such as add_executable or add_library. " - "The remaining arguments specify library names or flags." + "The remaining arguments specify library names or flags. " + "Repeated calls for the same <target> append items in the order called." "\n" "If a library name matches that of another target in the project " "a dependency will automatically be added in the build system to make " diff --git a/Source/kwsys/kwsysDateStamp.cmake b/Source/kwsys/kwsysDateStamp.cmake index 2f8913e..3d0f03d 100644 --- a/Source/kwsys/kwsysDateStamp.cmake +++ b/Source/kwsys/kwsysDateStamp.cmake @@ -18,4 +18,4 @@ SET(KWSYS_DATE_STAMP_YEAR 2012) SET(KWSYS_DATE_STAMP_MONTH 04) # KWSys version date day component. Format is DD. -SET(KWSYS_DATE_STAMP_DAY 13) +SET(KWSYS_DATE_STAMP_DAY 20) diff --git a/Utilities/.gitattributes b/Utilities/.gitattributes new file mode 100644 index 0000000..e3a9e61 --- /dev/null +++ b/Utilities/.gitattributes @@ -0,0 +1,2 @@ +/Git export-ignore +SetupForDevelopment.sh export-ignore diff --git a/Utilities/GitSetup/.gitattributes b/Utilities/GitSetup/.gitattributes new file mode 100644 index 0000000..facbbb2 --- /dev/null +++ b/Utilities/GitSetup/.gitattributes @@ -0,0 +1,7 @@ +.git* export-ignore + +# Exclude from source archives files specific to Git work tree. +* export-ignore + +tips eol=lf whitespace=indent-with-non-tab +setup-* eol=lf whitespace=indent-with-non-tab diff --git a/Utilities/GitSetup/LICENSE b/Utilities/GitSetup/LICENSE new file mode 100644 index 0000000..d645695 --- /dev/null +++ b/Utilities/GitSetup/LICENSE @@ -0,0 +1,202 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/Utilities/GitSetup/NOTICE b/Utilities/GitSetup/NOTICE new file mode 100644 index 0000000..0d32c02 --- /dev/null +++ b/Utilities/GitSetup/NOTICE @@ -0,0 +1,5 @@ +Kitware Local Git Setup Scripts +Copyright 2010-2012 Kitware, Inc. + +This product includes software developed at Kitware, Inc. +(http://www.kitware.com/). diff --git a/Utilities/GitSetup/README b/Utilities/GitSetup/README new file mode 100644 index 0000000..cf468fb --- /dev/null +++ b/Utilities/GitSetup/README @@ -0,0 +1,80 @@ +Kitware Local Git Setup Scripts + + +Introduction +------------ + +This is a collection of local Git development setup scripts meant for +inclusion in project source trees to aid their development workflow. +Project-specific information needed by the scripts may be configured +in a "config" file added next to them in the project. + + +Import +------ + +A project may import these scripts into their source tree by +initializing a subtree merge. Bring up a Git prompt and set the +current working directory inside a clone of the target project. +Fetch the "setup" branch from the GitSetup repository: + + $ git fetch ../GitSetup setup:setup + +Prepare to merge the branch but place the content in a subdirectory. +Any prefix (with trailing '/') may be chosen so long as it is used +consistently within a project through the rest of these instructions: + + $ git merge -s ours --no-commit setup + $ git read-tree -u --prefix=Utilities/GitSetup/ setup + +Commit the merge with an informative message: + + $ git commit + ------------------------------------------------------------------------ + Merge branch 'setup' + + Add Utilities/GitSetup/ directory using subtree merge from + the general GitSetup repository "setup" branch. + ------------------------------------------------------------------------ + + +Configuration +------------- + +Read the "Project configuration instructions" comment in each script. +Add a "config" file next to the scripts with desired configuration +(optionally copy and modify "config.sample"). For example, to +configure the "setup-hooks" script: + + $ git config -f Utilities/GitSetup/config hooks.url "$url" + +where "$url" is the project repository publishing the "hooks" branch. +When finished, add and commit the configuration file: + + $ git add Utilities/GitSetup/config + $ git commit + + +Update +------ + +A project may update these scripts from the GitSetup repository. +Bring up a Git prompt and set the current working directory inside a +clone of the target project. Fetch the "setup" branch from the +GitSetup repository: + + $ git fetch ../GitSetup setup:setup + +Merge the "setup" branch into the subtree: + + $ git merge -X subtree=Utilities/GitSetup setup + +where "Utilities/GitSetup" is the same prefix used during the import +setup, but without a trailing '/'. + + +License +------- + +Distributed under the Apache License 2.0. +See LICENSE and NOTICE for details. diff --git a/Utilities/GitSetup/config b/Utilities/GitSetup/config new file mode 100644 index 0000000..b7d5423 --- /dev/null +++ b/Utilities/GitSetup/config @@ -0,0 +1,9 @@ +[hooks] + url = http://cmake.org/cmake.git +[ssh] + host = cmake.org + key = id_git_cmake + request-url = https://www.kitware.com/Admin/SendPassword.cgi +[stage] + url = git://cmake.org/stage/cmake.git + pushurl = git@cmake.org:stage/cmake.git diff --git a/Utilities/GitSetup/config.sample b/Utilities/GitSetup/config.sample new file mode 100644 index 0000000..bba2382 --- /dev/null +++ b/Utilities/GitSetup/config.sample @@ -0,0 +1,22 @@ +# Kitware Local Git Setup Scripts - Sample Project Configuration +# +# Copy to "config" and edit as necessary. + +[hooks] + url = http://public.kitware.com/GitSetup.git + #branch = hooks + +[ssh] + host = public.kitware.com + key = id_git_public + request-url = https://www.kitware.com/Admin/SendPassword.cgi + +[stage] + #url = git://public.kitware.com/stage/Project.git + #pushurl = git@public.kitware.com:stage/Project.git + +[gerrit] + #project = Project + site = http://review.source.kitware.com + # pushurl placeholder "$username" is literal + pushurl = $username@review.source.kitware.com:Project diff --git a/Utilities/GitSetup/setup-gerrit b/Utilities/GitSetup/setup-gerrit new file mode 100755 index 0000000..9e8fa62 --- /dev/null +++ b/Utilities/GitSetup/setup-gerrit @@ -0,0 +1,142 @@ +#!/usr/bin/env bash +#============================================================================= +# Copyright 2010-2012 Kitware, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +#============================================================================= + +# Run this script to set up the local Git repository to push to +# a Gerrit Code Review instance for this project. + +# Project configuration instructions: +# +# - Run a Gerrit Code Review server +# +# - Populate adjacent "config" file with: +# gerrit.site = Top Gerrit URL (not project-specific) +# gerrit.project = Name of project in Gerrit +# gerrit.pushurl = Review site push URL with "$username" placeholder +# gerrit.remote = Gerrit remote name, if not "gerrit" +# gerrit.url = Gerrit project URL, if not "$site/p/$project" + +die() { + echo 1>&2 "$@" ; exit 1 +} + +# Make sure we are inside the repository. +cd "${BASH_SOURCE%/*}" && + +# Load the project configuration. +site=$(git config -f config --get gerrit.site) && +project=$(git config -f config --get gerrit.project) && +pushurl_=$(git config -f config --get gerrit.pushurl) && +remote=$(git config -f config --get gerrit.remote || + echo "gerrit") && +fetchurl=$(git config -f config --get gerrit.url || + echo "$site/p/$project") || +die 'This project is not configured to use Gerrit.' + +# Get current gerrit push URL. +pushurl=$(git config --get remote."$remote".pushurl || + git config --get remote."$remote".url || echo '') && + +# Tell user about current configuration. +if test -n "$pushurl"; then + echo 'Remote "'"$remote"'" is currently configured to push to + + '"$pushurl"' +' && + read -ep 'Reconfigure Gerrit? [y/N]: ' ans && + if [ "$ans" == "y" ] || [ "$ans" == "Y" ]; then + setup=1 + else + setup='' + fi +else + echo 'Remote "'"$remote"'" is not yet configured. + +'"$project"' changes must be pushed to our Gerrit Code Review site: + + '"$fetchurl"' + +Register a Gerrit account and select a username (used below). +You will need an OpenID: + + http://openid.net/get-an-openid/ +' && + read -ep 'Configure Gerrit? [Y/n]: ' ans && + if [ "$ans" == "n" ] || [ "$ans" == "N" ]; then + exit 0 + else + setup=1 + fi +fi && + +# Perform setup if necessary. +if test -n "$setup"; then + echo 'Sign-in to Gerrit to get/set your username at + + '"$site"'/#/settings + +Add your SSH public keys at + + '"$site"'/#/settings/ssh-keys +' && + read -ep "Gerrit username? [$USER]: " gu && + if test -z "$gu"; then + gu="$USER" + fi && + if test -z "$pushurl"; then + git remote add "$remote" "$fetchurl" + else + git config remote."$remote".url "$fetchurl" + fi && + pushurl="${pushurl_/\$username/$gu}" && + git config remote."$remote".pushurl "$pushurl" && + echo 'Remote "'"$remote"'" is now configured to push to + + '"$pushurl"' +' +fi && + +# Optionally test Gerrit access. +if test -n "$pushurl"; then + read -ep 'Test access to Gerrit (SSH)? [y/N]: ' ans && + if [ "$ans" == "y" ] || [ "$ans" == "Y" ]; then + echo -n 'Testing Gerrit access by SSH...' + if git ls-remote --heads "$pushurl" >/dev/null; then + echo 'passed.' + else + echo 'failed.' && + die 'Could not access Gerrit. Add your SSH public keys at + + '"$site"'/#/settings/ssh-keys +' + fi + fi +fi && + +# Set up GerritId hook. +hook=$(git config --get hooks.GerritId || echo '') && +if test -z "$hook"; then + echo ' +Enabling GerritId hook to add a "Change-Id" footer to commit +messages for interaction with Gerrit. Run + + git config hooks.GerritId false + +to disable this feature (but you will be on your own).' && + git config hooks.GerritId true +else + echo 'GerritId hook already configured to "'"$hook"'".' +fi diff --git a/Utilities/GitSetup/setup-hooks b/Utilities/GitSetup/setup-hooks new file mode 100755 index 0000000..c07985a --- /dev/null +++ b/Utilities/GitSetup/setup-hooks @@ -0,0 +1,63 @@ +#!/usr/bin/env bash +#============================================================================= +# Copyright 2010-2012 Kitware, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +#============================================================================= + +# Run this script to set up local Git hooks for this project. + +# Project configuration instructions: +# +# - Publish a "hooks" branch in the project repository such that +# clones will have "refs/remotes/origin/hooks". +# +# - Populate adjacent "config" file with: +# hooks.url = Repository URL publishing "hooks" branch +# hooks.branch = Repository branch instead of "hooks" + +egrep-q() { + egrep "$@" >/dev/null 2>/dev/null +} + +die() { + echo 1>&2 "$@" ; exit 1 +} + +# Make sure we are inside the repository. +cd "${BASH_SOURCE%/*}" && + +# Select a hooks branch. +if url=$(git config --get hooks.url); then + # Fetch hooks from locally configured repository. + branch=$(git config hooks.branch || echo hooks) +elif git for-each-ref refs/remotes/origin/hooks 2>/dev/null | + egrep-q 'refs/remotes/origin/hooks$'; then + # Use hooks cloned from origin. + url=.. && branch=remotes/origin/hooks +elif url=$(git config -f config --get hooks.url); then + # Fetch hooks from project-configured repository. + branch=$(git config -f config hooks.branch || echo hooks) +else + die 'This project is not configured to install local hooks.' +fi && + +# Populate ".git/hooks". +echo 'Setting up git hooks...' && +git_dir=$(git rev-parse --git-dir) && +cd "$git_dir/hooks" && +if ! test -e .git; then + git init -q || die 'Could not run git init for hooks.' +fi && +git fetch -q "$url" "$branch" && +git reset -q --hard FETCH_HEAD || die 'Failed to install hooks' diff --git a/Utilities/GitSetup/setup-ssh b/Utilities/GitSetup/setup-ssh new file mode 100755 index 0000000..8920a5b --- /dev/null +++ b/Utilities/GitSetup/setup-ssh @@ -0,0 +1,111 @@ +#!/usr/bin/env bash +#============================================================================= +# Copyright 2010-2012 Kitware, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +#============================================================================= + +# Run this script to set up ssh push access to the repository host. + +# Project configuration instructions: +# +# - Populate adjacent "config" file with: +# ssh.host = Repository host name +# ssh.user = Username on host, if not "git" +# ssh.key = Local ssh key name +# ssh.request-url = Web page URL to request ssh access + +egrep-q() { + egrep "$@" >/dev/null 2>/dev/null +} + +die() { + echo 1>&2 "$@" ; exit 1 +} + +# Make sure we are inside the repository. +cd "${BASH_SOURCE%/*}" && + +# Load the project configuration. +host=$(git config -f config --get ssh.host) && +user=$(git config -f config --get ssh.user || echo git) && +key=$(git config -f config --get ssh.key) && +request_url=$(git config -f config --get ssh.request-url) || +die 'This project is not configured for ssh push access.' + +# Check for existing configuration. +if test -r ~/.ssh/config && + egrep-q 'Host[= ]'"${host//\./\\.}" ~/.ssh/config; then + echo 'Host "'"$host"'" is already in ~/.ssh/config' && + setup= && + question='Test' +else + echo 'Host "'"$host"'" not found in ~/.ssh/config' && + setup=1 && + question='Setup and test' +fi && + +# Ask the user whether to make changes. +echo '' && +read -ep "${question} push access by ssh to $user@$host? [y/N]: " access && +if test "$access" != "y" -a "$access" != "Y"; then + exit 0 +fi && + +# Setup host configuration if necessary. +if test -n "$setup"; then + if ! test -d ~/.ssh; then + mkdir -p ~/.ssh && + chmod 700 ~/.ssh + fi && + if ! test -f ~/.ssh/config; then + touch ~/.ssh/config && + chmod 600 ~/.ssh/config + fi && + ssh_config='Host='"$host"' + IdentityFile ~/.ssh/'"$key" && + echo "Adding to ~/.ssh/config: + +$ssh_config +" && + echo "$ssh_config" >> ~/.ssh/config && + if ! test -e ~/.ssh/"$key"; then + if test -f ~/.ssh/id_rsa; then + # Take care of the common case. + ln -s id_rsa ~/.ssh/"$key" + echo ' +Assuming ~/.ssh/id_rsa is the private key corresponding to the public key for + + '"$user@$host"' + +If this is incorrect place private key at "~/.ssh/'"$key"'".' + else + echo ' +Place the private key corresponding to the public key registered for + + '"$user@$host"' + +at "~/.ssh/'"$key"'".' + fi + read -e -n 1 -p 'Press any key to continue...' + fi +fi || exit 1 + +# Test access configuration. +echo 'Testing ssh push access to "'"$user@$host"'"...' && +if ! ssh "$user@$host" info; then + die 'No ssh push access to "'"$user@$host"'". You may need to request access at + + '"$request_url"' +' +fi diff --git a/Utilities/GitSetup/setup-stage b/Utilities/GitSetup/setup-stage new file mode 100755 index 0000000..ef53b99 --- /dev/null +++ b/Utilities/GitSetup/setup-stage @@ -0,0 +1,53 @@ +#!/usr/bin/env bash +#============================================================================= +# Copyright 2010-2012 Kitware, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +#============================================================================= + +# Run this script to set up the topic stage for pushing changes. + +# Project configuration instructions: +# +# - Run a Topic Stage repository next to the main project repository. +# +# - Populate adjacent "config" file with: +# stage.url = Topic Stage repository URL +# stage.pushurl = Topic Stage push URL if not "$url" + +egrep-q() { + egrep "$@" >/dev/null 2>/dev/null +} + +die() { + echo 1>&2 "$@" ; exit 1 +} + +# Make sure we are inside the repository. +cd "${BASH_SOURCE%/*}" && + +# Load the project configuration. +url=$(git config -f config --get stage.url) && +pushurl=$(git config -f config --get stage.pushurl || echo '') || +die 'This project is not configured to use a topic stage.' + +# Configure the remote if necessary. +if git config remote.stage.url >/dev/null; then + echo 'Topic stage already configured.' +else + echo 'Setting up the topic stage...' && + git remote add stage "$url" && + if test -n "$pushurl"; then + git config remote.stage.pushurl "$pushurl" + fi +fi || die 'Could not add the topic stage remote.' diff --git a/Utilities/GitSetup/setup-user b/Utilities/GitSetup/setup-user new file mode 100755 index 0000000..1af439c --- /dev/null +++ b/Utilities/GitSetup/setup-user @@ -0,0 +1,39 @@ +#!/usr/bin/env bash +#============================================================================= +# Copyright 2010-2012 Kitware, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +#============================================================================= + +# Run this script to configure Git user info in this repository. + +# Project configuration instructions: NONE + +for (( ; ; )); do + user_name=$(git config user.name || echo '') && + user_email=$(git config user.email || echo '') && + if test -n "$user_name" -a -n "$user_email"; then + echo 'Your commits will record as Author: + + '"$user_name <$user_email>"' +' && + read -ep 'Is the author name and email address above correct? [Y/n] ' correct && + if test "$correct" != "n" -a "$correct" != "N"; then + break + fi + fi && + read -ep 'Enter your full name e.g. "John Doe": ' name && + read -ep 'Enter your email address e.g. "john@gmail.com": ' email && + git config user.name "$name" && + git config user.email "$email" +done diff --git a/Utilities/GitSetup/tips b/Utilities/GitSetup/tips new file mode 100755 index 0000000..784e1ed --- /dev/null +++ b/Utilities/GitSetup/tips @@ -0,0 +1,55 @@ +#!/usr/bin/env bash +#============================================================================= +# Copyright 2010-2012 Kitware, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +#============================================================================= + +# This script makes optional suggestions for working with Git. + +# Project configuration instructions: NONE + +egrep-q() { + egrep "$@" >/dev/null 2>/dev/null +} + +# Suggest color configuration. +if test -z "$(git config --get color.ui)"; then + echo ' +One may enable color output from Git commands with + + git config --global color.ui auto +' +fi + +# Suggest bash completion. +if ! bash -i -c 'echo $PS1' | egrep-q '__git_ps1'; then + echo ' +A dynamic, informative Git shell prompt can be obtained by sourcing +the git bash-completion script in your "~/.bashrc". Set the PS1 +environmental variable as suggested in the comments at the top of the +bash-completion script. You may need to install the bash-completion +package from your distribution to obtain it. +' +fi + +# Suggest merge tool. +if test -z "$(git config --get merge.tool)"; then + echo ' +One may configure Git to load a merge tool with + + git config merge.tool <toolname> + +See "git help mergetool" for more information. +' +fi diff --git a/Utilities/SetupForDevelopment.sh b/Utilities/SetupForDevelopment.sh new file mode 100755 index 0000000..0a9df7e --- /dev/null +++ b/Utilities/SetupForDevelopment.sh @@ -0,0 +1,13 @@ +#!/usr/bin/env bash + +cd "${BASH_SOURCE%/*}/.." && +Utilities/GitSetup/setup-user && echo && +Utilities/GitSetup/setup-hooks && echo && +Utilities/GitSetup/setup-stage && echo && +(Utilities/GitSetup/setup-ssh || + echo 'Failed to setup SSH. Run this again to retry.') && echo && +Utilities/GitSetup/tips + +# Rebase master by default +git config rebase.stat true +git config branch.master.rebase true @@ -18,18 +18,11 @@ die() { # Version number extraction function. cmake_version_component() { - cat "${cmake_source_dir}/CMakeLists.txt" | sed -n " + cat "${cmake_source_dir}/Source/CMakeVersion.cmake" | sed -n " /^SET(CMake_VERSION_${1}/ {s/SET(CMake_VERSION_${1} *\([0-9]*\))/\1/;p;} " } -cmake_date_stamp_component() -{ - cat "${cmake_source_dir}/Source/kwsys/kwsysDateStamp.cmake" | sed -n " -/KWSYS_DATE_STAMP_${1}/ {s/^.* \([0-9][0-9]*\))$/\1/;p;} -" -} - cmake_toupper() { echo "$1" | sed 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' @@ -46,9 +39,6 @@ cmake_version_minor="`cmake_version_component MINOR`" cmake_version_patch="`cmake_version_component PATCH`" cmake_version="${cmake_version_major}.${cmake_version_minor}.${cmake_version_patch}" cmake_version_tweak="`cmake_version_component TWEAK`" -if [ "x$cmake_version_tweak" = "x" ]; then - cmake_version_tweak="`cmake_date_stamp_component YEAR``cmake_date_stamp_component MONTH``cmake_date_stamp_component DAY`" -fi if [ "$cmake_version_tweak" != "0" ]; then cmake_version="${cmake_version}.${cmake_version_tweak}" fi |