Commit Graph

50 Commits

Author SHA1 Message Date
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 e33d8d2d77 Drop builtin command documentation
Drop all GetTerseDocumentation and GetFullDocumentation methods from
commands.  The command documentation is now in Help/command/*.rst files.
2013-10-16 09:22:36 -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
Bjoern Ricks 0d2f5c8d6a Fix crash if app bundle executeable couldn't be found
Fix a crash on Mac OS X if a programm can't be found as an
application bundle. CFRelease MUST NOT be called on a
NULL value.

See https://developer.apple.com/library/mac/documentation/CoreFOundation/Reference/CFTypeRef/Reference/reference.html#//apple_ref/doc/c_ref/CFRelease
2012-02-25 18:20:36 +01:00
Brad King b41ad3b399 Teach find_(library|package) about Linux multiarch (#12037)
Implement support for multiarch as specified here:

  http://wiki.debian.org/Multiarch
  https://wiki.ubuntu.com/MultiarchSpec

Detect the <arch> part of <prefix>/lib/<arch> from the implicit library
search path from each compiler to set CMAKE_<lang>_LIBRARY_ARCHITECTURE.
Define CMAKE_LIBRARY_ARCHITECTURE using one of these values (they should
all be the same).  Teach the find_library and find_package commands to
search <prefix>/lib/<arch> whenever they would search <prefix>/lib.
2011-06-08 10:04:44 -04:00
Brad King 5303fbf09e Speedup find_* commands (#11412)
Delay computation of the command documentation until it is needed.
It is wasteful to do it in the constructor on every call.

Inspired-By: Christian Ehrlicher <Ch.Ehrlicher@gmx.de>
2010-11-12 10:47:28 -05: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 6706f84cd9 ENH: Refactor find_* command framework/appbundle search order impl.
- CMAKE_FIND_FRAMEWORK and CMAKE_FIND_APPBUNDLE are supposed to specify
    whether to find frameworks/appbundles FIRST, LAST, ONLY, or NEVER.
  - Previously this affected only the placement of CMAKE_FRAMEWORK_PATH
    and CMAKE_APPBUNDLE_PATH with respect to the other path specifiers.
  - Now it behaves as documented.  The entire search path is inspected for
    each kind of program, library, or header before trying the next kind.
  - Additionally the ONLY mode is now honored for headers so that users
    do not end up with a library in framework and a header from elsewhere.
2008-06-09 11:58:29 -04: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
Brad King b424df917d ENH: Major improvements to the FIND_PACKAGE command. See bug #3659.
- Use CMAKE_PREFIX_PATH and CMAKE_SYSTEM_PREFIX_PATH among other means
    to locate package configuration files.
  - Create cmFindCommon as base for cmFindBase and cmFindPackageCommand
  - Move common functionality up to cmFindCommon
  - Improve documentation of FIND_* commands.
  - Fix FIND_* commands to not add framework/app paths in wrong place.
2008-01-17 09:02:31 -05:00
Alexander Neundorf 0398d8ad38 ENH: add support for CMAKE_FIND_PREFIX_PATH as discussed with Brad.
CMAKE_FIND_PREFIX_PATH is both an environment variable and a cmake variable,
which is a list of base directories where FIND_PATH, FIND_FILE, FIND_PROGRAM
and FIND_LIBRARY will search in the respective subdirectories

Alex
2007-10-26 09:55:40 -04:00
Ken Martin 8d32d229a3 ENH: make commands lower case by default 2007-10-10 11:47:43 -04:00
Alexander Neundorf 0ddc9f62e5 ENH: add cmExternalMakefileProjectGenerator, which should make it easier to
write generators for IDE projects, which use already existing makefiles
(current the kdevelop generator)
-first stept of the export interface, iniitial export() command
-more replacements for the FIND_XXX docs

Alex
2007-06-08 11:57:16 -04:00
Brad King ec637248da BUG: If the user specifies a cache entry on the command line without a type, the FIND_* commands should add the type and docstring to the given value and put it back in the cache. 2006-07-18 15:21:26 -04:00
Ken Martin 2af4710525 STYLE: fix line length 2006-05-10 15:46:45 -04:00
Bill Hoffman 1871a74153 ENH: fix warning 2006-04-13 23:24:09 -04:00
Bill Hoffman cae4e6b37a ENH: add patch for finding applications on OSX 2006-04-13 11:00:52 -04:00
Ken Martin 3d96e52261 STYLE: some m_ to this-> cleanup 2006-03-15 11:02:08 -05:00
Bill Hoffman e97157feb1 ENH: make sure system path is not added unless asked for 2006-03-08 18:16:01 -05:00
Bill Hoffman a5825cd11a ENH: check in new find stuff 2006-03-02 13:30:22 -05:00
Ken Martin 072db6ad70 removed redundent includes 2003-08-10 18:30:54 -04:00
Bill Hoffman f58d7df66a ENH: add checking for NOTFOUND 2003-01-31 13:50:42 -05:00
Brad King 4888c088ae ENH: Moved ExpandListVariables out of individual commands. Argument evaluation rules are now very consistent. Double quotes can always be used to create exactly one argument, regardless of contents inside. 2002-12-11 18:13:33 -05: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
Andy Cedilnik c3007233ec Rename variables to remove warnings 2002-10-17 10:51:23 -04:00
Andy Cedilnik bef93dc5c1 Couple of changes: cache variables now have a map of properties. ADVANCED and HELPSTRING are now properties of cache variable, IsAdvanced is gone, so is GetCacheEntry, since cache entries are now all private. To access them, you use the iterator. -ADVANCED cache entries are gone and are replaced by the property of cache variables. The cache file still looks the same, but the -ADVANCED cache entries are created when writing file. MarkAsAdvanced and VariableRequires are fixed. So are curses gui and wizard 2002-09-11 14:05:45 -04:00
Ken Martin d0be2896d7 changed cache manager and registered generators to no longer be singletons 2002-08-28 14:51:10 -04:00
Sebastien Barre 1ad05f9e6d ENH/FIX: add NO_SYSTEM_PATH option + fix command usage 2002-05-12 11:31:45 -04:00
Bill Hoffman 7d76de4403 make sure ; expansion is done in all commands 2002-03-29 14:20:32 -05:00
Bill Hoffman 809b32fe59 ENH: remove several compiler warnings 2002-03-13 10:25:11 -05:00
Bill Hoffman 4651dbcfc6 ENH: expand variables in arguments before the commands get them 2002-03-05 18:41:24 -05:00
Will Schroeder a6a43d5320 ENH:Updated copyright 2002-01-21 15:30:43 -05:00
Berk Geveci e452849640 FIX: Entry doc. should never be overwritten. This may cause cmake to be re-run very often. 2002-01-15 13:20:22 -05:00
Bill Hoffman 3e24edcd04 ENH: add possibility to add doc strings to varibles created by find type commands 2001-11-26 18:24:47 -05:00
Bill Hoffman baa28efd10 ENH: change InitialPass to take a const reference to the argument string, to avoid changes to the file cache 2001-09-20 15:08:30 -04:00
Brad King 65ef85320a ENH: Added cmSystemTools::GlobDirs function to allow wildcards in paths (like /foo/bar/*). 2001-09-20 10:54:29 -04:00
Bill Hoffman db1303aa7d ENH: big change, only allow commands access to the cache via the cmMakefile class and GetDefinition, also the cmMakefile is the only way for commands to add to the cache. Also, some changes to configure.in that check for for scoping 2001-08-08 11:54:46 -04:00
Bill Hoffman 9922155423 ENH: rename Invoke to InitialPass 2001-06-06 13:19:15 -04:00
Ken Martin dbfc72c6b5 expands reg values 2001-05-11 11:07:05 -04:00
Brad King 68ac32e60a ERR: Removed unused variable 2001-05-10 11:18:52 -04:00
Bill Hoffman f07ee5b817 ENH: change find library and find program to look for more than one name 2001-05-09 14:53:32 -04:00
Bill Hoffman de10cfc72e ENH: move testing stuff to cmake from configure, good bye dashboard... :) 2001-05-04 11:30:46 -04:00
Brad King 5079efdc68 ENH: Added cmSystemTools::FindProgram() and full-path detection utilities. 2001-05-03 16:55:18 -04:00
Will Schroeder 54cfe84f3f ENH:New copyright 2001-04-27 08:01:17 -04:00
Bill Hoffman 2c1fb789d7 ENH: add help for cache entries 2001-04-26 14:53:44 -04:00
Ken Martin 7cde8fd0f4 fixed bug and modified functionality 2001-02-26 17:14:33 -05:00
Brad King d31ce24413 ERR: Fixed warnings (int->unsigned int and a few others). 2001-02-23 10:40:13 -05:00
Bill Hoffman 89e037ee19 ENH: first pass at cache, clean up the unix generator, clean up configure.in some 2001-02-19 15:13:48 -05:00
Ken Martin 43859e36cf ENH: add new commands fro find library and find program 2001-02-16 11:34:23 -05:00
Will Schroeder 658614ff6a ENH:Reworked CMake for consistency 2001-01-18 11:20:24 -05:00