Commit Graph

27 Commits

Author SHA1 Message Date
Christoph Grüninger 098fc4a862 cmCMakeMinimumRequired: Use unsigned int for version numbers 2014-12-23 09:05:25 -05:00
Stephen Kelly af8a1643c1 Remove c_str calls when using stream APIs.
Use an ad-hoc clang tool for matching the calls which should be
ported.
2014-03-11 15:03:50 +01:00
Stephen Kelly 21c573f682 Remove some c_str() calls.
Use the clang RemoveCStrCalls tool to automatically migrate the
code. This was only run on linux, so does not have any positive or
negative effect on other platforms.
2014-03-11 15:03:50 +01:00
Brad King 7d47c69365 Drop compatibility with CMake < 2.4
Drop all behavior activated by setting CMAKE_BACKWARDS_COMPATIBILITY to
a value lower than 2.4, and generate an error when projects or the user
attempt to do so.  In the error suggest using a CMake 2.8.x release.

Teach cmake_minimum_required to warn about projects that do not require
at least CMake 2.4.  They are not supported by CMake >= 3.0.

Replace the documentation of CMAKE_BACKWARDS_COMPATIBILITY with a
reference to policy CMP0001.
2013-10-23 08:54:31 -04:00
Kitware Robot 7bbaa4283d Remove trailing whitespace from most CMake and C/C++ code
Our Git commit hooks disallow modification or addition of lines with
trailing whitespace.  Wipe out all remnants of trailing whitespace
everywhere except third-party code.

Run the following shell code:

git ls-files -z -- \
 bootstrap doxygen.config '*.readme' \
 '*.c' '*.cmake' '*.cpp' '*.cxx' \
 '*.el' '*.f' '*.f90' '*.h' '*.in' '*.in.l' '*.java' \
 '*.mm' '*.pike' '*.py' '*.txt' '*.vim' |
egrep -z -v '^(Utilities/cm|Source/(kwsys|CursesDialog/form)/)' |
egrep -z -v '^(Modules/CPack\..*\.in)' |
xargs -0 sed -i 's/ \+$//'
2012-08-13 14:18:39 -04:00
Brad King 378acb1d4d Teach cmake_minimum_required about tweak version
The command now accepts four version components in the format

  major[.minor[.patch[.tweak]]]

This corresponds to the new versioning scheme introduced recently.
2010-04-23 09:50:02 -04:00
Brad King 96afb12087 Convert CMake to OSI-approved BSD License
This converts the CMake license to a pure 3-clause OSI-approved BSD
License.  We drop the previous license clause requiring modified
versions to be plainly marked.  We also update the CMake copyright to
cover the full development time range.
2009-09-28 11:43:28 -04:00
Brad King b41a548d86 Add parentheses around '&&' between '||' for gcc
The GNU compiler warns about possible operator precedence mistakes and
asks for explicit parentheses (-Wparentheses).  We add the parentheses
to silence the warning.  This also fixes one real logic error in the
find_package() implementation by correcting expression evaluation order.
2009-09-11 08:18:15 -04:00
Brad King cd7585df22 ENH: Ignore unknown cmake_minimum_required args
When cmake_minimum_required is called with an unknown argument it should
not complain about it if the version specified is in the future.  This
allows the proper error to be shown about the current CMake being too
old.
2009-01-03 15:47:58 -05:00
Brad King 1655dce2a5 ENH: Cleanup policy version interface presented to user.
- In cmake_minimum_required do not set policy version if current
    CMake is too old
  - In cmPolicies::ApplyPolicyVersion report error if version is too
    new or cannot be parsed
2008-03-24 10:56:26 -04:00
Ken Martin 55eede4b13 ENH: clean up some policy stuff and interactions with CMAKE_BACKWARDS_COMPATIBILITY and CMAKE_MINIMUM_REQUIRED 2008-03-07 11:43:47 -05:00
Ken Martin adddcea5d7 BUG: change the handling of CMAKE_MINIMUM_REQUIRED and BACKWARDS_COMPATIBILITY and extend the documentaiton quite a bit 2008-03-06 10:57:59 -05:00
Brad King 2f922c6220 ENH: Make CMAKE_MINIMUM_REQUIRED command FATAL_ERROR option implicit (always on). Accept but ignore the existing option. 2008-03-04 18:42:06 -05:00
Ken Martin cd4d2acbe6 ENH: more policy changes 2008-03-04 14:51:25 -05:00
Ken Martin 0e69d38004 ENH: add return and break support to cmake, also change basic command invocation signature to be able to return extra informaiton via the cmExecutionStatus class 2008-01-23 10:28:26 -05:00
Bill Hoffman ccb77b65c6 ENH: unify version stuff, get rid of it out of cmake and cmMakefile and only use cmVersion 2006-11-29 15:59:16 -05:00
Ken Martin 3d96e52261 STYLE: some m_ to this-> cleanup 2006-03-15 11:02:08 -05:00
Andy Cedilnik 634343c3e8 STYLE: Fix some style issues 2006-03-10 13:06:26 -05:00
Brad King aea456a91a ENH: Added FATAL_ERROR option and fixed check to not have floating point roundoff problems. 2006-02-14 17:16:14 -05:00
Brad King 65e2c18d73 ENH: Enabling ability for CMAKE_MINIMUM_REQUIRED version to include patch level. Submitted by Alexander Neundorf. 2005-06-17 09:49:06 -04:00
Ken Martin 072db6ad70 removed redundent includes 2003-08-10 18:30:54 -04:00
Brad King 1f6a3c67b1 ENH: Added reference to Copyright.txt. Removed old reference to ITK copyright. Changed program name to CMake instead of Insight in source file header. Also removed tabs. 2002-10-23 18:03:27 -04:00
Brad King 281f7519e1 ENH: Renamed cmStringStream to cmOStringStream and added cmIStringStream. Removed cmInputStringStream. 2002-10-10 10:43:59 -04:00
Brad King 07d35e662d ENH: Added cmStringStream class to wrap std::stringstream or std::strstream depending on the platform. The interface is that of std::stringstream, so no "ends" or "rdbuf()->freeze(0)" lines are needed. 2002-06-19 15:21:49 -04:00
Bill Hoffman 945c4a8b5b WAR: remove warnings for .NET compiler 2002-04-25 07:59:57 -04:00
Bill Hoffman da63a7574d BUG: add missing include 2002-04-18 07:58:08 -04:00
Bill Hoffman 0415b58573 ENH: backwards compatible for VTK 4.0, add cmake version requires 2002-04-17 16:16:06 -04:00