summaryrefslogtreecommitdiff
path: root/Source/cmAddExecutableCommand.h
AgeCommit message (Collapse)AuthorLines
2020-09-03Modernize: Use #pragma once in all header filesKitware Robot-4/+1
#pragma once is a widely supported compiler pragma, even though it is not part of the C++ standard. Many of the issues keeping #pragma once from being standardized (distributed filesystems, build farms, hard links, etc.) do not apply to CMake - it is easy to build CMake on a single machine. CMake also does not install any header files which can be consumed by other projects (though cmCPluginAPI.h has been deliberately omitted from this conversion in case anyone is still using it.) Finally, #pragma once has been required to build CMake since at least August 2017 (7f29bbe6 enabled server mode unconditionally, which had been using #pragma once since September 2016 (b13d3e0d)). The fact that we now require C++11 filters out old compilers, and it is unlikely that there is a compiler which supports C++11 but does not support #pragma once.
2019-08-07cmA*Command: Turn into free functionsRegina Pfeifer-28/+2
Ref: #19499
2019-07-14modernize: manage cmCommand instances using unique_ptr.Marc Chevrier-1/+6
2017-09-15Use C++11 override instead of CM_OVERRIDEBrad King-2/+2
We now require C++11 support including `override`. Drop use of the old compatibility macro. Convert references as follows: git grep -l CM_OVERRIDE -- '*.h' '*.hxx' '*.cxx' | xargs sed -i 's/CM_OVERRIDE/override/g'
2017-08-26IWYU: Mark cmConfigure.h with pragma: keepDaniel Pfeifer-1/+1
Also remove `#include "cmConfigure.h"` from most source files.
2017-05-11cmCommand: remove unused methods from interface and all implementationsDaniel Pfeifer-5/+0
2017-04-11Use quotes for non-system includesDaniel Pfeifer-1/+1
Automate with: git grep -l '#include <cm_' -- Source \ | xargs sed -i 's/#include <\(cm_.*\)>/#include "\1"/g' git grep -l '#include <cmsys/' -- Source \ | xargs sed -i 's/#include <\(cmsys\/.*\)>/#include "\1"/g' git grep -l '#include <cm[A-Z]' -- Source \ | xargs sed -i 's/#include <\(cm[A-Z].*\)>/#include "\1"/g'
2017-04-11cmConfigure: Ensure separate include block in headersDaniel Pfeifer-0/+1
Make sure that `#include <cmConfigure.h>` is followed by an empty line in header files. This is necessary to make sure that changing <> to "" does not affect the include ordering of clang-format. Automate with: git grep -l '#include <cmConfigure.h>' | grep -v '.cxx$' \ | xargs sed -i '/#include <cmConfigure.h>/ { N; N; s/\n\{1,2\}/\n\n/ }'
2016-10-26Include necessary headers in commandsDaniel Pfeifer-0/+6
2016-10-23Make cmCommand not inherit from cmObjectDaniel Pfeifer-2/+0
2016-09-27Simplify CMake per-source license noticesBrad King-11/+2
Per-source copyright/license notice headers that spell out copyright holder names and years are hard to maintain and often out-of-date or plain wrong. Precise contributor information is already maintained automatically by the version control tool. Ultimately it is the receiver of a file who is responsible for determining its licensing status, and per-source notices are merely a convenience. Therefore it is simpler and more accurate for each source to have a generic notice of the license name and references to more detailed information on copyright holders and full license terms. Our `Copyright.txt` file now contains a list of Contributors whose names appeared source-level copyright notices. It also references version control history for more precise information. Therefore we no longer need to spell out the list of Contributors in each source file notice. Replace CMake per-source copyright/license notice headers with a short description of the license and links to `Copyright.txt` and online information available from "https://cmake.org/licensing". The online URL also handles cases of modules being copied out of our source into other projects, so we can drop our notices about replacing links with full license text. Run the `Utilities/Scripts/filter-notices.bash` script to perform the majority of the replacements mechanically. Manually fix up shebang lines and trailing newlines in a few files. Manually update the notices in a few files that the script does not handle.
2016-06-27mark functions with CM_OVERRIDEDaniel Pfeifer-4/+4
2016-05-16Revise C++ coding style using clang-formatKitware Robot-7/+3
Run the `Utilities/Scripts/clang-format.bash` script to update all our C++ code to a new style defined by `.clang-format`. Use `clang-format` version 3.8. * If you reached this commit for a line in `git blame`, re-run the blame operation starting at the parent of this commit to see older history for the content. * See the parent commit for instructions to rebase a change across this style transition commit.
2014-03-08stringapi: Command namesBen Boeckel-1/+1
2013-10-16Drop builtin command documentationBrad King-80/+0
Drop all GetTerseDocumentation and GetFullDocumentation methods from commands. The command documentation is now in Help/command/*.rst files.
2013-08-02Add the ALIAS target concept for libraries and executables.Stephen Kelly-0/+13
* The ALIAS name must match a validity regex. * Executables and libraries may be aliased. * An ALIAS acts immutable. It can not be used as the lhs of target_link_libraries or other commands. * An ALIAS can be used with add_custom_command, add_custom_target, and add_test in the same way regular targets can. * The target of an ALIAS can be retrieved with the ALIASED_TARGET target property. * An ALIAS does not appear in the generated buildsystem. It is kept separate from cmMakefile::Targets for that reason. * A target may have multiple aliases. * An ALIAS target may not itself have an alias. * An IMPORTED target may not have an alias. * An ALIAS may not be exported or imported.
2012-02-29Add 'const' qualifier to some cmCommand membersYury G. Kudryashov-3/+3
Use const_cast for the special case in cmFindBase where GetFullDocumentation calls GenerateDocumentation.
2012-01-25Optionally allow IMPORTED targets to be globally visibleBrad King-2/+2
Consider the case motivating commit e01cce28 (Allow add_dependencies() on imported targets, 2010-11-19). An imported target references a file generated at build time by a custom target on which it depends. Had the file been built directly using add_library or add_executable its target name would have been visible globally. Therefore the imported target representing the file should be globally visible also. Teach the IMPORTED signature of add_(executable|library) to accept a new "GLOBAL" option to make the imported target visible globally.
2009-09-28Convert CMake to OSI-approved BSD LicenseBrad King-14/+9
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-03some white space fixes for the bookKen Martin-1/+2
2008-02-11ENH: Enforce global target name uniqueness.Brad King-26/+29
- Error if imported target is involved in conflict - Error for non-imported target conflict unless CMAKE_BACKWARDS_COMPATIBILITY <= 2.4 - Include OUTPUT_NAME property in error message - Update add_executable and add_library command documentation
2008-01-28ENH: Updated exporting and importing of targets to support libraries and ↵Brad King-0/+18
configurations. - Created cmExportFileGenerator hierarchy to implement export file generation - Installed exports use per-config import files loaded by a central one. - Include soname of shared libraries in import information - Renamed PREFIX to NAMESPACE in INSTALL(EXPORT) and EXPORT() commands - Move addition of CMAKE_INSTALL_PREFIX to destinations to install generators - Import files compute the installation prefix relative to their location when loaded - Add mapping of importer configurations to importee configurations - Rename IMPORT targets to IMPORTED targets to distinguish from windows import libraries - Scope IMPORTED targets within directories to isolate them - Place all properties created by import files in the IMPORTED namespace - Document INSTALL(EXPORT) and EXPORT() commands. - Document IMPORTED signature of add_executable and add_library - Enable finding of imported targets in cmComputeLinkDepends
2008-01-23ENH: add return and break support to cmake, also change basic command ↵Ken Martin-1/+2
invocation signature to be able to return extra informaiton via the cmExecutionStatus class
2008-01-09STYLE: Spelling fixes on documentationAmitha Perera-2/+2
2007-10-10ENH: make commands lower case by defaultKen Martin-2/+2
2006-10-02ENH: Renamed NOT_IN_ALL to EXCLUDE_FROM_ALL.Brad King-2/+2
2006-10-02ENH: Added NOT_IN_ALL option for ADD_LIBRARY and ADD_EXECUTABLE to avoid ↵Brad King-2/+5
building the targets by default.
2006-03-10STYLE: Fix some style issuesAndy Cedilnik-12/+13
2004-04-28BUG: fix for bug 121 add some docs for MFC flagBill Hoffman-0/+5
2004-04-23ENH: Unify with other variablesAndy Cedilnik-4/+5
2004-04-08ENH: Improve Mac OSX bundle supportAndy Cedilnik-4/+16
2003-08-10removed redundent includesKen Martin-1/+0
2003-02-14ENH: Cleaned up documentation and formatted it for use by cmDocumentation.Brad King-4/+5
2002-12-30ENH: clean up docs someBill Hoffman-5/+4
2002-10-23ENH: Added reference to Copyright.txt. Removed old reference to ITK ↵Brad King-3/+3
copyright. Changed program name to CMake instead of Insight in source file header. Also removed tabs.
2002-01-21ENH:Updated copyrightWill Schroeder-29/+5
2001-09-20ENH: change InitialPass to take a const reference to the argument string, to ↵Bill Hoffman-1/+1
avoid changes to the file cache
2001-06-06ENH: rename Invoke to InitialPassBill Hoffman-1/+1
2001-05-11added registry entry support and windows app supportKen Martin-1/+7
2001-04-27ENH:New copyrightWill Schroeder-3/+28
2001-04-11major changes to support multiple libraries and source listsKen Martin-0/+71