summaryrefslogtreecommitdiffstats
path: root/Source/cmLocalGenerator.cxx
Commit message (Collapse)AuthorAgeFilesLines
* 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.
* cmLinkLineComputer: Extract from cmLocalGeneratorStephen Kelly2016-10-101-48/+16
| | | | | | | | | | | CMake has several classes which have too many responsibilities. cmLocalGenerator is one of them. Start to extract the link line computation. Create generator-specific implementations of the interface to account for generator-specific behavior. Unfortunately MSVC60 has different behavior to everything else and CMake still generates makefiles for it. Isolate it with MSVC60-specific names.
* cmLocalGenerator: Inline conversion into link computationStephen Kelly2016-10-101-1/+8
| | | | | Make it possible to invoke this functionality independent of cmLocalGenerator.
* cmLocalGenerator: Extract definition retrieval out of loopStephen Kelly2016-10-101-2/+3
|
* Merge topic 'cleanup-Convert'Brad King2016-10-071-8/+5
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 20e62f74 cmLocalGenerator: Simplify ConvertToLinkReference fd93b360 cmOutputConverter: Add a flag for IsUnix 1365e18b Convert: Inline platform-specific methods 1ed5f6b3 Makefiles: Introduce local RelativePath method 8377d9e0 Fortran: Inline conversion to relative path 00173b71 Fortran: Wrap path convert in a call with a more-suitable name d5911ef0 Makefiles: Hardcode the relative location of the CMakeCache file c3264f48 Convert: Extract method to determine if paths are in directory 52168f32 Convert: Remove asserts which are duplicated in delegate method 5213f893 Convert: Remove early return check b61c268b Convert: Extract local variables for readability e278f5a8 Convert: Extract local variables 51bc6bdd cmOutputConverter: remove unused code 8e0c1599 Xcode: Inline ConvertToRelativePath calls
| * cmLocalGenerator: Simplify ConvertToLinkReferenceStephen Kelly2016-10-061-8/+5
| | | | | | | | | | Make conversion to output format the caller responsibility, so that the method only 'converts to a link reference'.
* | CMP0065: Put computed flags into LINK_FLAGS not LINK_LIBRARIESStephen Kelly2016-10-071-1/+9
| | | | | | | | | | | | | | These flags are redundant anyway in the NEW case of the policy, and could be merged with CMAKE_EXE_EXPORTS_${lang}_FLAG content for that case. That is deferred to the future, but now at least the similar code is located close to each other.
* | cmLocalGenerator: Rename local variable to be more appropriateStephen Kelly2016-10-061-4/+3
| |
* | cmLocalGenerator: Extract policy handling into a methodStephen Kelly2016-10-061-46/+52
|/
* 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.
* Convert: Inline uses of START_OUTPUTStephen Kelly2016-09-191-1/+3
|
* Convert: Move access to CurrentBinaryDirectory out of loopsStephen Kelly2016-09-191-4/+4
|
* Convert: Avoid START_OUTPUT enum when converting to relative pathsStephen Kelly2016-09-191-3/+4
|
* Convert: Remove last use of START enum valueStephen Kelly2016-09-191-1/+2
| | | | | | | | | | The enums just introduce unfamiliar names and don't provide value. The order of arguments is reversed, as that is the result of the cmOutputConverter::ConvertToRelativePath overload which accepts the RelativeRoot enum.
* Fix CTest test file generation for spaces in subdirectory namesStefano Soffia2016-09-131-0/+1
| | | | | | Encode the subdirectory names properly for CMake syntax. Closes: #16299
* cmLocalGenerator: Refactor test subdirectory generation loopStefano Soffia2016-09-131-8/+6
|
* Re-order link line to place RPATH entries before librariesDan Kegel2016-09-121-3/+3
| | | | | | | | | | | | Since we support adding arbitrary flags to the link line via `target_link_libraries` the project/user may add their own RPATH flags (typically for system library locations). Re-order the link line to place our generated RPATH entries before the libraries so that they also come before flag-specified entries. Otherwise our in-build-tree RPATH entries may not be preferred by the dynamic loader and we could collide with libraries in the system directories. Closes: #16293
* tidy: Fix readability-redundant-string-cstr issuesGregor Jasny2016-09-041-1/+1
|
* fix a load of include-what-you-use violationsDaniel Pfeifer2016-09-031-4/+10
|