summaryrefslogtreecommitdiffstats
path: root/Source/cmLocalGenerator.cxx
Commit message (Collapse)AuthorAgeFilesLines
* Features: Refactor <LANG>_STANDARD updateBrad King2017-05-011-8/+25
| | | | | | | | | In order to support generator expressions in target COMPILE_FEATURES we apply them at generate time. Move this step to the beginning of generation instead of doing it on demand while collecting flags. This avoids repeating the process unnecessarily, and will then allow `cmLocalGenerator::AddCompilerRequirementFlag` to be used any time during generation.
* Clang IPO (LTO) supportRuslan Baratov2017-04-281-3/+37
|
* Add IPO compiler flags more consistently in generatorsBrad King2017-04-271-6/+7
| | | | | | Move addition of IPO flags into `cmLocalGenerator::AddLanguageFlags` because all call sites of that need the IPO flags, but not all were following the call with `AppendFeatureOptions`.
* CUDA: Allow sources to be compiled to .ptx filesRobert Maynard2017-04-201-3/+7
| | | | | When the target property `CUDA_PTX_COMPILATION` is enabled CUDA OBJECT libraries will generate ptx files instead of object files.
* Use quotes for non-system includesDaniel Pfeifer2017-04-111-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'
* Refactoring: s,GetFeatureAsBool,IsIPOEnabled,Ruslan Baratov2017-03-301-1/+1
| | | | | Method 'GetFeatureAsBool' is used only with 'INTERPROCEDURAL_OPTIMIZATION' feature. Substituting 'GetFeatureAsBool' with 'IsIPOEnabled'.
* Merge topic 'revert-CTestTestfile-removal'Brad King2017-03-071-7/+4
|\ | | | | | | | | | | | | 485685fd Revert "Remove CTestTestfile.cmake when BUILD_TESTING is OFF" Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !553
| * Revert "Remove CTestTestfile.cmake when BUILD_TESTING is OFF"Brad King2017-03-061-7/+4
| | | | | | | | | | | | This reverts commit v3.8.0-rc1~305^2 (Remove CTestTestfile.cmake when BUILD_TESTING is OFF, 2016-11-14). It breaks projects that never enable testing but create their own `CTestTestfile.cmake` manually instead.
* | fix some include-what-you-use diagnosticsDaniel Pfeifer2017-02-171-1/+0
|/
* CUDA: Now pass correct FLAGS when device link cuda executables.Robert Maynard2017-01-121-1/+4
| | | | | | | | Previously we had a two issues when building cuda executables that required separable compilation. The first was that we didn't propagate FLAGS causing any -arch / -gencode flags to be dropped, and secondly generators such as ninja would use the CXX language flags instead of CUDA when the executable was mixed language.
* Features: Add infrastructure for C++ 17 language standardBrad King2016-12-021-0/+1
| | | | Issue: #16468
* Merge topic 'initial_cuda_language_support'Brad King2016-11-291-0/+5
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 4cc601f2 Help: Add release note for CUDA support 7b9131da CUDA: Add tests to verify CUDA compiler works properly. 9cf5b98d CUDA: Prefer environment variables CUDACXX and CUDAHOSTCXX. a5e806b3 CUDA: Add support for CMAKE_CUDA_COMPILE_OPTIONS_VISIBILITY d038559e CUDA: Add separable compilation support to the makefile generator. 43ce4414 CUDA: Add separable compilation support to the ninja generator. 4b316097 CUDA: Add support for the CUDA_SEPARABLE_COMPILATION target property ae05fcc6 CUDA: Add LinkLineComputer that computes cuda dlink lines. 115269a8 CUDA: Refactor cmLinkLineComputer to allow for better derived children. 5dec4031 CUDA: Refactor CMakeCUDAInformation to prepare for separable compilation. 5b20d0ab CUDA: C++ compile features now enable cuda c++11 support. 489c52ce CUDA: Use the host compiler for linking CUDA executables and shared libs. bbaf2434 CUDA: add support for specifying an explicit host compiler. a92f8d96 CUDA: Enable header dependency scanning. ec6ce623 CUDA: State that cuda has preprocessor output and can generate assembly. 4f5155f6 CUDA: We now properly perform CUDA compiler identification. ...
| * CUDA: Use the host compiler for linking CUDA executables and shared libs.Robert Maynard2016-11-141-0/+2
| |
| * CUDA: Add support language levels (98/11)Robert Maynard2016-11-141-0/+3
| |
* | Remove CTestTestfile.cmake when BUILD_TESTING is OFFSylvain Joubert2016-11-151-4/+7
|/ | | | | | | | When disabling BUILD_TESTING after a previous configure, the `CTestTestfile.cmake` was left unchanged. As a result, ctest would see the tests while the user disabled testing. Now when BUILD_TESTING is OFF any existing `CTestTestfile.cmake` is removed ensuring an empty test list.
* Merge topic 'import-librhash'Brad King2016-11-101-13/+3
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | cd8a57ae Add option to build CMake against a system librhash 71180fc8 FindLibRHash: Add module to find the librhash package 3216e94c Remove unused cm_sha2 infrastructure 5420278d Port hash computation to cmCryptoHash 9a596b33 cmCryptoHash: Re-implement in terms of librhash 47f91a61 cmCryptoHash: Avoid using subclasses at client sites d0ff3e70 librhash: Port to KWIML for ABI and integer type information 465a85fb librhash: Avoid signed left-shift overflow fc2cb74f librhash: Implement bswap_32 as a function even in strict C90 mode 0bd333bc librhash: Implement bswap_64 even in strict C90 mode 7189d62c librhash: Use __builtin_bswap{32,64} on Clang af7ebf8a librhash: Install COPYING file with CMake documentation bb01f20e librhash: Disable warnings to avoid changing 3rd party code 31bb727f librhash: Build the library within CMake 53048afa librhash: Remove source fragments not needed for CMake 5cb1b345 Merge branch 'upstream-librhash' into import-librhash ...
| * Port hash computation to cmCryptoHashBrad King2016-11-101-13/+3
| | | | | | | | | | Avoid using KWSys MD5 or `cm_sha2` and use the `cmCryptoHash` abstraction instead.
* | Fix several include-what-you-use findingsDaniel Pfeifer2016-11-081-1/+2
|/
* cmState: Split auxiliary classes into separate filesStephen Kelly2016-10-191-0/+2
| | | | | | | Port dependents to the new locations as needed. Leave behind a cmState.h include in cmListFileCache to reduce noise. It is removed in a following commit.
* cmState: Port dependent code to new cmStateSnapshot nameStephen Kelly2016-10-191-5/+5
|
* cmState: Move TargetType enum to separate namespaceStephen Kelly2016-10-191-29/+29
|
* cmRulePlaceholderExpander: Port clients to direct-useStephen Kelly2016-10-151-11/+7
| | | | | | Add a factory function to cmLocalGenerator so that variableMappings can be provided from it, and so that Ninja can always have a hard-coded TargetImpLib.
* cmRulePlaceholderExpander: Extract from cmLocalGeneratorStephen Kelly2016-10-151-282/+6
| | | | | Implement cmLocalGenerator::ExpandRuleVariables in terms of the new class for source compatibility and to reduce diff noise in this commit.
* cmLocalGenerator: Move memset to cxx fileStephen Kelly2016-10-151-0/+5
|
* cmLocalGenerator: Use strings instead of a Target in rule replacementStephen Kelly2016-10-151-4/+6
| | | | Don't rely on the cmGeneratorTarget type needlessly.
* cmLocalGenerator: Use a converter in rule replacement APIStephen Kelly2016-10-151-7/+10
| | | | | | | The rule replacement API should not really be in cmLocalGenerator, but it was historically, and this coupled many other things together here too, such as output conversion. Make the output converter a parameter so that rule replacement can be removed from cmLocalGenerator.
* cmLocalGenerator: Store variable replacements as stateStephen Kelly2016-10-151-94/+91
| | | | These do not change over the lifetime of the cmLocalGenerator.
* cmLocalGenerator: Merge loops which populate mappingStephen Kelly2016-10-151-14/+12
|
* cmLocalGenerator: Populate variable mapping for all replacementsStephen Kelly2016-10-151-10/+11
| | | | | This reduces the final replacement to a simple query in the map, which is much more readable than what was here before.
* cmLocalGenerator: Extract compiler option replacement from loopStephen Kelly2016-10-151-50/+48
| | | | | There is no need to be in the loop. Being there just adds to complexity.
* cmLocalGenerator: Populate a container of mappings for replacementsStephen Kelly2016-10-151-31/+58
| | | | | | The same variables are replaced/retrieved from cmMakefile again and again. Use a container so that they don't have to be retrieved repeatedly, and to simplify the nested loop.
* cmLocalGenerator: Move compiler option handling to be more directStephen Kelly2016-10-151-23/+25
|
* cmLocalGenerator: Move variable to where it can be used easilyStephen Kelly2016-10-151-1/+2
|
* cmLocalGenerator: Use the language from the compiler containerStephen Kelly2016-10-151-7/+8
| | | | This is just to make follow-up diffs smaller.
* cmLocalGenerator: Introduce a container of compiler namesStephen Kelly2016-10-151-3/+17
| | | | Use it to determine when a rule replacement should gain extra options.
* cmLocalGenerator: Simplify loop with range algorithmStephen Kelly2016-10-151-6/+4
|
* cmLocalGenerator: Remove the launcher from RuleVariablesStephen Kelly2016-10-151-15/+0
| | | | | | | | | This one is not like the others as it doesn't participate in substitutions. Keep ExpandRuleVariables doing only one thing and make callers responsible for inserting a launcher prefix, simplifying the code all-around. Remove now-obsolete InsertRuleLauncher method.
* cmLinkLineComputer: Extract link libraries computation from cmLocalGeneratorStephen Kelly2016-10-101-26/+4
| | | | Hide some methods which no longer need to be public.
* cmLinkLineComputer: Move FrameworkPath computation from cmLocalGeneratorStephen Kelly2016-10-101-18/+5
| | | | Add UseWatcomQuote state, and remove corresponding method parameters.
* cmLocalGenerator: Inline last use of local variableStephen Kelly2016-10-101-3/+1
|
* cmLinkLineComputer: Move RPath computation from cmLocalGeneratorStephen Kelly2016-10-101-29/+4
| | | | | | Add state for Relink and populate it at the point of cmLinkLineComputer initialization. This allows removal of the parameter in go-between methods.
* cmLinkLineComputer: Move LinkPath computation from cmLocalGeneratorStephen Kelly2016-10-101-11/+2
| | | | | | | | Add a ConvertToOutputForExisting method which can be made virtual later to satisfy different generator needs. Pass additional strings as parameters for now. They can be turned into class state later.
* cmLinkLineComputer: Move ComputeLinkLibs from cmLocalGeneratorStephen Kelly2016-10-101-18/+1
| | | | | | | | | | | | | | | Add a cmOutputConverter to the cmLinkLineComputer and factory methods to facilitate shell escapes. Add state to the cmLinkLineComputer to record whether outputting for response files or for watcom, to satisfy the cmOutputConverter API. These are constant for the lifetime of the cmLinkLineComputer, even when its functionality is extended in the future. This also keeps the signatures of cmLinkLineComputer relatively simple. Pass the cmComputeLinkInformation as a method parameter so that cmLinkLineComputer is free from target-specific state. An instance should be usable for all targets in a directory.
* cmLocalGenerator: Move variable to where it is usedStephen Kelly2016-10-101-2/+2
|
* cmLocalGenerator: Use a std::string instead of char*Stephen Kelly2016-10-101-2/+3
|
* cmLocalGenerator: Move stringstream to where it is usedStephen Kelly2016-10-101-1/+1
|
* cmLocalGenerator: Move flag determination up in the functionStephen Kelly2016-10-101-8/+9
| | | | This content is independent of any targets.
* cmLocalGenerator: Separate stdlib content from library streamStephen Kelly2016-10-101-1/+5
|
* cmLocalGenerator: Separate rpath content from library streamStephen Kelly2016-10-101-7/+9
|
* cmLocalGenerator: Pass link library info to OutputLinkLibrariesStephen Kelly2016-10-101-14/+16
| | | | | | | Remove the cmGeneratorTarget from the interface. This is simplification of the OutputLinkLibraries responsibilities so that it can be broken apart into multiple methods.