summaryrefslogtreecommitdiffstats
path: root/Source/cmTarget.h
Commit message (Collapse)AuthorAgeFilesLines
* Merge topic 'imported-interface-libname'Brad King2016-11-091-0/+3
|\ | | | | | | | | | | | | | | 09cda9d5 Allow imported INTERFACE libraries to specify a link library name 1d1f1eeb cmTarget: Refactor GetMappedConfig to choose location property up front 479932fa cmTarget: Add comment clarifying interface library special case 925e4270 cmTarget: Clarify comments in GetMappedConfig
| * Allow imported INTERFACE libraries to specify a link library nameBrad King2016-11-091-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add an `IMPORTED_LIBNAME[_<CONFIG>]` target property to specify a library name to be placed on the link line in place of an interface library since it has no library file of its own. Restrict use of the property to imported `INTERFACE` libraries. This will be particularly useful for find modules that need to provide imported libraries from system SDKs where the full path to the library file is not known. Now such find modules will be able to provide an imported interface library and set `IMPORTED_LIBNAME` to refer to the SDK library by name. Issue: #15267
* | Fix several include-what-you-use findingsDaniel Pfeifer2016-11-081-8/+9
|/
* Introduce CM_UNORDERED_MAPDaniel Pfeifer2016-10-241-17/+2
| | | | | Avoid duplicating switch among std::unordered_map, cmsys::hash_map, and std::map.
* cmState: Port dependents to new cmStateTypes headerStephen Kelly2016-10-191-1/+1
|
* cmState: Move TargetType enum to separate namespaceStephen Kelly2016-10-191-4/+4
|
* cmTarget: Move sanity checks and computed property access to callersStephen Kelly2016-10-161-1/+3
| | | | | | | | | | | | | | | The GetProperty method is now just accessing contained data, meaning it can be implemented in cmState. Remove the cmMakefile context from the signature as a result and remove the overload with the same signature. Add a GetComputedProperty to cmTarget so that templates can be properly instantiated. Otherwise the Commands would need to be able to reach the specializations which are currently in cmTarget.cxx. As a side-effect, the CMP0026 warning now gives a backtrace to the target when issued from a generator expression.
* cm{,Generator}Target: Add global generator accessorsStephen Kelly2016-10-151-0/+3
| | | | | Provide 'static polymorphism' between the types in this aspect so that they can be used indiscriminately in a C++ template.
* cmTarget: Split property computation into separate classStephen Kelly2016-10-151-5/+3
| | | | | Everything related to property computation will be moved here and eventually shared with cmGeneratorTarget.
* cmTarget: Remove mutable marker from propertiesStephen Kelly2016-10-151-2/+2
|
* cmTarget: Remove target name from parameter listStephen Kelly2016-10-071-2/+2
| | | | Use the member state instead.
* cmTarget: Inline MergeLinkLibraries into only callerStephen Kelly2016-10-071-3/+0
|
* cmTarget: Remove useless link library stateStephen Kelly2016-10-071-1/+0
|
* Simplify CMake per-source license noticesBrad King2016-09-271-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.
* cmTarget: Remove unused support for partial constructionBrad King2016-09-151-5/+0
| | | | | We no longer need to support partial construction for cmTarget instances of type GLOBAL_TARGET. Require all constructor arguments up front.
* cmTarget: Inline SetType method at only remaining call siteBrad King2016-09-141-1/+0
|
* cmTarget: Construct with basic information up frontBrad King2016-09-141-10/+14
| | | | | Avoid having partially constructed cmTarget instances around, except for the special case of GLOBAL_TARGET construction.
* cmTarget: Add method to get a copy adapted for a directoryBrad King2016-09-141-0/+3
| | | | | The "global" targets are built once for the top directory and then copied into all directories. Add a helper method to make the copy.
* fix a batch of include-what-you-use violationsDaniel Pfeifer2016-08-161-9/+12
|
* Avoid using KWSys auto_ptr by adopting it ourselvesBrad King2016-06-291-1/+1
| | | | | | | | | | | | Replace use of cmsys::auto_ptr with a CM_AUTO_PTR macro that maps to our own implementation adopted from the KWSys auto_ptr implementation. Later we may be able to map CM_AUTO_PTR to std::auto_ptr on compilers that do not warn about it. Automate the client site conversions: git grep -l auto_ptr -- Source/ | grep -v Source/kwsys/ | xargs sed -i \ 's|cmsys::auto_ptr|CM_AUTO_PTR|;s|cmsys/auto_ptr.hxx|cm_auto_ptr.hxx|'
* use CM_NULLPTRDaniel Pfeifer2016-06-281-1/+1
|
* Make C++ feature checks extensibleDaniel Pfeifer2016-06-271-2/+2
| | | | | | Turn the feature check for cxx11_unordered_map into a function such that we can use it for other features as well. Drop the 11 suffix, as we may want to check features from other standards.
* Prefer std::ostream& over derivatives as parametersDaniel Pfeifer2016-06-081-1/+1
|
* Revise C++ coding style using clang-formatKitware Robot2016-05-161-70/+98
| | | | | | | | | | | | | 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.
* Format include directive blocks and ordering with clang-formatBrad King2016-04-291-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Sort include directives within each block (separated by a blank line) in lexicographic order (except to prioritize `sys/types.h` first). First run `clang-format` with the config file: --- SortIncludes: false ... Commit the result temporarily. Then run `clang-format` again with: --- SortIncludes: true IncludeCategories: - Regex: 'sys/types.h' Priority: -1 ... Commit the result temporarily. Start a new branch and cherry-pick the second commit. Manually resolve conflicts to preserve indentation of re-ordered includes. This cleans up the include ordering without changing any other style. Use the following command to run `clang-format`: $ git ls-files -z -- \ '*.c' '*.cc' '*.cpp' '*.cxx' '*.h' '*.hh' '*.hpp' '*.hxx' | egrep -z -v '(Lexer|Parser|ParserHelper)\.' | egrep -z -v '^Source/cm_sha2' | egrep -z -v '^Source/(kwsys|CursesDialog/form)/' | egrep -z -v '^Utilities/(KW|cm).*/' | egrep -z -v '^Tests/Module/GenerateExportHeader' | egrep -z -v '^Tests/RunCMake/CommandLine/cmake_depends/test_UTF-16LE.h' | xargs -0 clang-format -i This selects source files that do not come from a third-party. Inspired-by: Daniel Pfeifer <daniel@pfeifer-mail.de>
* Source: Stabilize include orderBrad King2016-04-291-0/+2
| | | | | Each source file has a logical first include file. Include it in an isolated block so that tools that sort includes do not move them.
* Drop Visual Studio 6 generatorBrad King2016-03-091-64/+0
| | | | | | This generator has been deprecated since CMake 3.3. Remove it. Update documentation, modules, and tests to drop content specific to this generator.
* Merge topic 'minor-cleanups'Brad King2015-10-281-2/+0
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 13a37f5f cmMakefile: Fix typo in comment 958508bb cmMakefile: Fix style 91a829c1 Makefiles: Remove unused variable e0213882 cmTarget: Remove obsolete member 0554c2c9 cmTarget: Fix style b22e5d0a Remove some obsolete declarations ce43ed2c Use LocalGenerator when possible d90c9738 Makefiles: Remove some unneeded casts 331023ae Export: Remove unused variable a03f3d0e cmFunctionBlocker: Constify method d50c4220 Xcode: Fix typo in comment 803f1901 Xcode: Remove trailing semicolon
| * cmTarget: Remove obsolete memberStephen Kelly2015-10-271-1/+0
| |
| * Remove some obsolete declarationsStephen Kelly2015-10-271-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | Ensure that cmStandardIncludes.h is included before any platform header in cmGeneratorExpressionEvaluator.h. That file needs to change as a result of removal of the cmMakefile.h header from cmGeneratorExpressionNode.h, affecting the compilation of cmGeneratorExpressionNode.cxx. On AIX we need to include our own headers first to get large file support macros defined consistently within system headers. The old order in this header worked only because it was always included after other headers.
* | cmGlobalGenerator: Remove direct storage of targetsStephen Kelly2015-10-271-1/+4
| | | | | | | | Find the target by looping when needed.
* | cmGeneratorTarget: Move LinkLanguagePropagatesToDependents from cmTargetStephen Kelly2015-10-271-3/+0
| |
* | cmTarget: Make compatbility API explicit.Stephen Kelly2015-10-271-6/+2
| |
* | cmGeneratorTarget: Move GetFrameworkVersion from cmTargetStephen Kelly2015-10-261-4/+0
|/
* cmGlobalGenerator: Move GeneratorTargetsType to usage site.Stephen Kelly2015-10-241-0/+4
|
* cmGeneratorTarget: Copy the policy map from the cmTarget.Stephen Kelly2015-10-201-17/+0
|
* cmTarget: Remove unused NameResolvesToFramework.Stephen Kelly2015-10-201-2/+0
|
* Move ComputeLinkType out of cmTarget.Stephen Kelly2015-10-201-3/+0
| | | | | Keep it out of the way, so that it does not become part of cmGeneratorTarget, but where it can be used to implement CMP0003.
* cmGeneratorTarget: Move IsDLLPlatform from cmTarget.Stephen Kelly2015-10-201-3/+0
|
* cmGeneratorTarget: Move HaveWellDefinedOutputFiles from cmTarget.Stephen Kelly2015-10-201-3/+0
|
* cmGeneratorTarget: Move GetExportMacro from cmTarget.Stephen Kelly2015-10-201-5/+0
|
* cmGeneratorTarget: Move IsCFBundleOnApple from cmTarget.Stephen Kelly2015-10-191-3/+0
|
* cmGeneratorTarget: Move IsXCTestOnApple from cmTarget.Stephen Kelly2015-10-191-3/+0
|
* cmGeneratorTarget: Move IsLinkable from cmTarget.Stephen Kelly2015-10-191-3/+0
|
* cmGeneratorTarget: Move GetExportName from cmTarget.Stephen Kelly2015-10-181-1/+0
|
* cmGeneratorTarget: Move ComputeVersionedName from cmTarget.Stephen Kelly2015-10-161-7/+0
|
* cmGeneratorTarget: Move GetTargetVersion from cmTarget.Stephen Kelly2015-10-161-11/+0
|
* cmGeneratorTarget: Move CheckCMP0004 from cmTarget.Stephen Kelly2015-10-161-4/+0
|
* cmGeneratorTarget: Move ImportInfo from cmTarget.Stephen Kelly2015-10-161-24/+0
|
* cmGeneratorTarget: Move ImportedGetLocation from cmTarget.Stephen Kelly2015-10-161-2/+0
|