summaryrefslogtreecommitdiff
path: root/Source/cmLocalUnixMakefileGenerator3.h
Commit message (Collapse)AuthorAgeFilesLines
* Link step: use linker dependency linker fileMarc Chevrier2023-05-031-0/+3
| | | | | | Based on work done by @ben.boeckel (!8051) Fixes: #22217
* Source: Fix clang -Wextra-semi warningsSean McBride2021-09-281-1/+1
|
* Refactoring: Makefiles Generators: Add support for various depends scannersMarc Chevrier2020-11-281-15/+14
|
* Constify some code as suggested by clang-tidyCengizhan Pasaoglu2020-10-201-2/+2
|
* Makefile: Add policy CMP0113 to avoid duplication of custom commandsBrad King2020-09-081-0/+10
| | | | | | | | | | | | | | | | | Do not attach a custom command to a target if it is already attached to one of the target's dependencies. The command's output will be available by the time the target needs it because the dependency containing the command will have already been built. This may break existing projects that do not properly mark non-created outputs with the `SYMBOLIC` property. Previously a chain of two custom commands whose intermediate dependency is not created would put both commands in a dependent project's Makefile even if the first command is also in its dependency's Makefile. The first command would run twice but the build would work. Now the second command needs an explicit `SYMBOLIC` mark on its input to tell CMake that it is not expected to exist. To maintain compatibility with projects that left out the mark, add a policy activating the behavior.
* Modernize: Use #pragma once in all header filesKitware Robot2020-09-031-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.
* Makefiles: Factor out makefile target path escaping and quotingBrad King2020-04-151-0/+6
| | | | | | | | Code paths that write makefile target paths use a combination of `cmSystemTools::ConvertToOutputPath` and `cmMakeSafe`. Some were missing the latter. Wrap these two steps up into a dedicated `ConvertToMakefilePath` method provided on both the local and global generators.
* Source: use std::string in place of const char*Vitaly Stakhovsky2020-01-291-1/+1
|
* Refactor: Prepare Ninja generator for multi-configKyle Edwards2019-12-131-0/+2
|
* Revise include order using clang-format-6.0Kitware Robot2019-10-011-3/+3
| | | | | Run the `clang-format.bash` script to update our C and C++ code to a new include order `.clang-format`. Use `clang-format` version 6.0.
* cmLocalUnixMakefileGenerator3: Mark GetRelativeTargetDirectory constBrad King2019-09-301-1/+2
|
* cmLocalGenerator: Add AppendFlags overload with backtracesJustin Goshi2019-09-091-0/+1
|
* cmLocalGenerator: Remove AppendFlags 'const char*' overloadBrad King2019-09-051-1/+0
| | | | | Update call sites to ensure the `std::string` argument can be constructed safely.
* Makefiles: Process ADDTIONAL_CLEAN_FILES dir prop at directory levelSebastian Holtermann2019-05-181-0/+1
| | | | | | | | | | | | | | In the "Unix Makefiles" generator, the `ADDTIONAL_CLEAN_FILES` directory property was evaluated on a per target basis. This had two drawbacks: - per directory clean files were repeated in every target clean script - per directory clean files weren't removed in directories without targets (issue #8164) This patch moves the `ADDTIONAL_CLEAN_FILES` directory property processing from the target to the directory level clean target. Fixes: #8164 "ADDITIONAL_CLEAN_FILES directory property not respected if no target present in directory"
* Makefiles: Sort clean files by using a std::set<std::string> containerSebastian Holtermann2019-05-141-1/+1
| | | | | | | By using a `std::set<std::string>` container instead of a `std::vector<std::string>` container, the clean files list becomes sorted and unique. The clean target in Makefiles beomes nicer and better readable this way. Also double clean entries won't appear anymore.
* cmDepends: Define DependencyMap instead of DependencyVectorSebastian Holtermann2019-03-271-6/+5
| | | | | | | | | | | | | In `cmDepends` use `typedef std::map<std::string, std::vector<std::string>> DependencyMap` instead of defining a `class DependencyVector : public std::vector<std::string>` and using it in `std::map<std::string, DependencyVector>`. Since `std::map<std::string, std::vector<std::string>>` is used in various other places, we now reuse all of it's auto generated methods. This doesn't happen when we use `DependencyVector` in a `std::map`, because it is a different class than `std::vector<std::string>`.
* cmLocalUnixMakefileGenerator3: Pass strings instead of recomputing themSebastian Holtermann2019-03-121-1/+2
|
* Merge topic 'tidy-use-equals-default'Brad King2019-01-291-2/+1
|\ | | | | | | | | | | | | | | | | 094f01d0f0 cleanup: Prefer compiler provided special member functions 55671b41d2 clang-tidy: Use `= default` Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Brad King <brad.king@kitware.com> Merge-request: !2841
| * cleanup: Prefer compiler provided special member functionsRegina Pfeifer2019-01-251-1/+0
| |
| * clang-tidy: Use `= default`Regina Pfeifer2019-01-251-2/+2
| | | | | | | | | | | | Suppress some cases in `Source/cmGeneratorExpressionNode.cxx` and `Source/cmUVHandlePtr.h` where a few older compilers require a user-defined default constructor (with `{}`).
* | Merge topic 'cmoutputconverter-simplify'Brad King2019-01-291-3/+0
|\ \ | | | | | | | | | | | | | | | | | | b6a957c969 cmOutputConverter: move ConvertToRelativePath to cmStateDirectory. Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2831
| * | cmOutputConverter: move ConvertToRelativePath to cmStateDirectory.Bruno Manganelli2019-01-271-3/+0
| | |
* | | Merge topic 'unixmfg3-string'Brad King2019-01-251-18/+7
|\ \ \ | |_|/ |/| | | | | | | | | | | | | | 614876c638 cmLocalUnixMakefileGenerator3: more methods accept std::string Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2840
| * | cmLocalUnixMakefileGenerator3: more methods accept std::stringVitaly Stakhovsky2019-01-221-18/+7
| | |
* | | clang-tidy: Pass by valueRegina Pfeifer2019-01-221-2/+3
|/ /
* | cmDepends: all members accept std::string argumentsVitaly Stakhovsky2019-01-181-1/+1
|/ | | | | | Most `const char*` arguments converted to `const std::string&` in `cmDepends` and derived classes. In addition performed minor code cleanup.
* clang-tidy: Use default member initializationRegina Pfeifer2018-12-151-14/+6
|
* clang-tidy: Remove redundant member initializationsRegina Pfeifer2018-12-151-1/+0
|
* Fix misc. typosluz.paz2018-06-041-1/+1
| | | | Found via `codespell` and `grep`
* Reduce raw string pointers usage.Pavel Solodovnikov2018-01-311-1/+2
| | | | | | | | | | * Change some functions to take `std::string` instead of `const char*` in the following classes: `cmMakeFile`, `cmake`, `cmCoreTryCompile`, `cmSystemTools`, `cmState`, `cmLocalGenerator` and a few others. * Greatly reduce using of `const char*` overloads for `cmSystemTools::MakeDirectory` and `cmSystemTools::RelativePath`. * Remove many redundant `c_str()` conversions throughout the code.
* Makefile,Ninja: De-duplicate ComputeObjectFilenames methodBrad King2018-01-291-5/+0
| | | | | Move the method implementation up to `cmLocalCommonGenerator` to avoid duplicating it in each generator.
* LocalGenerator: refactoringMarc Chevrier2018-01-231-2/+3
| | | | | Introduce method AppendCompileOptions to support future source file property COMPILE_OPTIONS.
* Use C++11 override instead of CM_OVERRIDEBrad King2017-09-151-11/+10
| | | | | | | | 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'
* IWYU: Mark cmConfigure.h with pragma: keepDaniel Pfeifer2017-08-261-1/+1
| | | | Also remove `#include "cmConfigure.h"` from most source files.
* Use C++11 nullptrDaniel Pfeifer2017-08-241-6/+5
|
* 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'
* Makefiles: Introduce local RelativePath methodStephen Kelly2016-10-061-0/+3
| | | | | | | This makes it easier to remove directory-specific state from cmOutputConverter where it doesn't belong. Of course, this just relocates the problem to the makefiles generator for now, but that's better than affecting the core.
* 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.
* fix a load of include-what-you-use violationsDaniel Pfeifer2016-09-031-4/+11
|
* Makefiles: Inline MakeLauncher into only callerStephen Kelly2016-08-271-3/+0
|
* Makefiles: Replace method with Wacom specific APIStephen Kelly2016-08-271-2/+1
| | | | | | | | The existing method uses RelativeRoot NONE and FULL values. In principle, those should be segregated interfaces. Mixing NONE and FULL into the RelativeRoot enum is a case of http://thedailywtf.com/articles/What_Is_Truth_0x3f_
* Makefiles: Change AppendCustomCommand API to stringsStephen Kelly2016-08-271-9/+10
| | | | | Avoid the RelativeRoot enum. Supply the HOME_OUTPUT string at each callsite to make the parameter non-defaulted.
* Makefiles: Change signature of AppendCustomCommandStephen Kelly2016-08-271-2/+2
| | | | The RelativeRoot parameter will become non-default.
* Makefiles: Port CreateCDCommand to string-based APIStephen Kelly2016-08-271-2/+1
|
* use CM_NULLPTRDaniel Pfeifer2016-06-281-5/+7
|
* mark functions with CM_OVERRIDEDaniel Pfeifer2016-06-271-12/+13
|
* Use enums defined in cmOutputConverter using their fully qualified name.Daniel Pfeifer2016-05-251-5/+7
| | | | | | | | | Mostly automated: values=("RelativeRoot" "NONE" "FULL" "HOME" "START" "HOME_OUTPUT" "START_OUTPUT" "OutputFormat" "UNCHANGED" "MAKERULE" "SHELL" "WATCOMQUOTE" "RESPONSE" "FortranFormat" "FortranFormatNone" "FortranFormatFixed" "FortranFormatFree") for i in "${values[@]}"; do git grep -l cmLocalGenerator::$i | xargs sed -i "s|cmLocalGenerator::$i|cmOutputConverter::$i|g"; done
* Revise C++ coding style using clang-formatKitware Robot2016-05-161-61/+83
| | | | | | | | | | | | | 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.
* Makefiles: Port to cmGeneratorTarget.Stephen Kelly2015-10-241-6/+7
|
* Remove vestigial declarations.Stephen Kelly2015-10-211-1/+0
|