| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
Adding backtrace support for INCLUDE_DIRECTORIES, COMPILE_OPTIONS, and
COMPILE_DEFINITIONS.
|
|
|
|
|
|
| |
Manipulating the property map of cmSourceFile directly may invalidate the class
invariant of the cached value IsGenerated. Provide the setter SetProperties
which also updates IsGenerated.
|
| |
|
|
|
|
| |
Rename mutating GetFullPath() overload to ResolveFullPath().
|
|
|
|
|
|
|
|
| |
- Remove the special case from cmGetSourceFilePropertyCommand
Tests: check LANGUAGE for source file
- use target_sources to add file
- use get_property to read property value
|
|
|
|
|
|
|
|
| |
GetOrDetermineLanguage:
- Read the property if available
- Determine the Language using the file extension
Fix all usage of the non-const member in the repository.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch is generated by a python script that uses regular expressions to
search for string concatenation patterns of the kind
```
std::string str = <ARG0>;
str += <ARG1>;
str += <ARG2>;
...
```
and replaces them with a single `cmStrCat` call
```
std::string str = cmStrCat(<ARG0>, <ARG1>, <ARG2>, ...);
```
If any `<ARGX>` is itself a concatenated string of the kind
```
a + b + c + ...;
```
then `<ARGX>` is split into multiple arguments for the `cmStrCat` call.
If there's a sequence of literals in the `<ARGX>`, then all literals in the
sequence are concatenated and merged into a single literal argument for
the `cmStrCat` call.
Single character strings are converted to single char arguments for
the `cmStrCat` call.
`std::to_string(...)` wrappings are removed from `cmStrCat` arguments,
because it supports numeric types as well as string types.
`arg.substr(x)` arguments to `cmStrCat` are replaced with
`cm::string_view(arg).substr(x)`
|
|
|
|
|
|
|
|
|
| |
This replaces invocations of
- `cmSystemTools::IsInternallyOn` with `cmIsInternallyOn`
- `cmSystemTools::IsNOTFOUND` with `cmIsNOTFOUND`
- `cmSystemTools::IsOn` with `cmIsOn`
- `cmSystemTools::IsOff` with `cmIsOff`
|
|
|
|
|
|
|
| |
In `cmSourceFile::FindFullPath` check first if the file is GENERATED before
aborting on `FindFullPathFailed`. This allows recomputation of the full path
when the GENERATED property was set after the file path was computed with an
error.
|
|
|
|
|
| |
Refactors the cmSourceFile::FindFullPath method to
use lambdas.
|
| |
|
|
|
|
|
|
|
| |
All cmSourceFiles are checked at least once whether they're `GENERATED` or not.
This adds a convenience method `GetIsGenerated` that returns a private
boolean cache variable `IsGenerated`. `IsGenerated` is updated every time the
`GENERATED` property is written.
|
| |
|
|
|
|
| |
Reduce the number of files relying on `cmake.h`.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
* 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.
|
|
|
|
|
|
|
|
|
|
|
| |
The ambiguous extension logic is an old behavior that ends up taking
lots of extra compute cycles to execute. This is triggered by various
CMake codepaths which pass extension-less paths down when CMake actually
knows that they are not ambiguous. These codepaths will be indicated in
upcoming changes.
Various APIs have gained a cmSourceFileLocationKind parameter, but they
are all optional and default to the existing behavior.
|
|
|
|
| |
Some are user-facing. Others are source comments.
|
|
|
|
|
|
| |
Changes done via `clang-tidy` with some manual fine-tuning
for the variable naming and `auto` type deduction
where appropriate.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
Include it in dependents which have previously relied on it
transitively.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Modern editors provide plenty of ways to visually separate functions.
Drop the explicit comments that previously served this purpose.
Use the following command to automate the change:
$ git ls-files -z -- \
"*.c" "*.cc" "*.cpp" "*.cxx" "*.h" "*.hh" "*.hpp" "*.hxx" |
egrep -z -v "^Source/cmCommandArgumentLexer\." |
egrep -z -v "^Source/cmCommandArgumentParser(\.y|\.cxx|Tokens\.h)" |
egrep -z -v "^Source/cmDependsJavaLexer\." |
egrep -z -v "^Source/cmDependsJavaParser(\.y|\.cxx|Tokens\.h)" |
egrep -z -v "^Source/cmExprLexer\." |
egrep -z -v "^Source/cmExprParser(\.y|\.cxx|Tokens\.h)" |
egrep -z -v "^Source/cmFortranLexer\." |
egrep -z -v "^Source/cmFortranParser(\.y|\.cxx|Tokens\.h)" |
egrep -z -v "^Source/cmListFileLexer\." |
egrep -z -v "^Source/cm_sha2" |
egrep -z -v "^Source/(kwsys|CursesDialog/form)/" |
egrep -z -v "^Utilities/(KW|cm).*/" |
xargs -0 sed -i '/^\(\/\/---*\|\/\*---*\*\/\)$/ {d;}'
This avoids modifying third-party sources and generated sources.
|
|
|
|
| |
Don't duplicate this in each cmMakefile.
|
| |
|
|
|
|
|
|
|
| |
The chaining logic doesn't belong to the container, and the
CMakeInstance pointer doesn't need to be in cmPropertyMap.
Size goes from 56 to 48 bytes with GNU libstdc++-5.1.
|
| |
|
| |
|
|
|
|
| |
Match names used in CMake code.
|
|
|
|
| |
Match the names used in cmake code.
|
|\
| |
| |
| |
| |
| | |
9a673737 QtAutoUic: Add a test for the regression in the parent commit.
7c585699 QtAutoUic: Restore source file AUTOUIC_OPTIONS settings
|
| |
| |
| |
| |
| |
| | |
The "." in the extension was dropped by commit v3.1.0-rc1~556^2~2
(cmSourceFile: Cache the isUiFile check, 2014-02-08) by mistake. This
caused the options to not be set.
|
| |
| |
| |
| | |
All compilers hosting CMake support the std class.
|
|/
|
|
|
| |
Replacements were detected and performed by the clang tool
remove-cstr-calls on a linux build.
|
| |
|
|
|
|
| |
The filename extension call is expensive, so cache the .ui check.
|
| |
|
|
|
|
|
|
| |
Use the clang RemoveCStrCalls tool to automatically migrate the
code. This was only run on linux, so does not have any positive or
negative effect on other platforms.
|
| |
|
| |
|
| |
|