| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
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'
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We parse `CMAKE_GENERATOR_TOOLSET` values of the forms:
* `toolset`
* `toolset,host=x64`
* `host=x64`
Generalize the parsing to support the forms:
* `toolset`
* `toolset[,key=value]*`
* `key=value[,key=value]*`
Disallow duplicate keys. Require all but the first field to
be of `key=value` form.
|
|
|
|
|
|
|
| |
Add these (currently unused) tables in preparation for `.csproj`
generation support. Populate the tables for every version with a set of
initial values that work well for me with VS 12 and VS 14. Later we may
need to generate them more thoroughly from MSBuild `.xml` files.
|
| |
|
|
|
|
|
| |
Move `Get*FlagTable` methods to the global generator and have each VS
generator version pre-populate its default flag table.
|
|
|
|
|
|
|
|
|
|
| |
Visual Studio provides toolchains that are themselves built for 32-bit
or 64-bit host architectures. By default it uses the 32-bit tools, but
it can be told to prefer the 64-bit tools on 64-bit hosts. Extend the
`CMAKE_GENERATOR_TOOLSET` specification to provide a way to request
use of the 64-bit host tools.
Closes: #15622
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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>
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
|
|
|
| |
The -T parameter to CMake may now be specified through cmake-gui via a
new text field in the first-time configure wizard (below the generator
chooser).
The generator factories specify whether or not they support toolsets.
This information is propagated to the Qt code and used to determine if
the selected generator should also display the optional Toolset widgets.
|
|
|
|
| |
It is required anyway, so this makes it explicit.
|
|
|
|
| |
Base class implementations for these are identical.
|
| |
|
|
|
|
| |
Port generator factory methods to pass it.
|
|
|
|
|
|
|
| |
Pass the parent though cmGlobalGenerator::CreateLocalGenerator.
This will make it easy to initialize state scopes independent of
cmMakefile.
|
|
|
|
|
|
|
|
|
| |
* Re-order VS generators from newest to oldest.
* Show how to specify a VS generator with a target platform
* Increase the option output indentation to avoid extra wrapping
with longer generator names.
|
| |
|
|
|
|
| |
All compilers hosting CMake support the std class.
|
|
|
|
|
|
|
|
| |
CMake requires both the Desktop SDK and the correct platform SDK
(Windows Phone or Windows Store) to be installed when targeting the
Windows mobile platforms. Verify that the right platform components are
installed and give a more detailed error message when something is
wrong.
|
|
|
|
|
|
|
|
| |
Teach the VS >= 10 generators to recognize these system names and select
the appropriate default toolset for the system version. Report an error
when the version is not known to be supported by VS.
Inspired-by: Gilles Khouzam <gillesk@microsoft.com>
|
|
|
|
|
|
| |
Ask the global generator during generation instead of trying
to store it up front. Later the global generator may not know
the platform name when it is creating the local generator.
|
|
|
|
|
|
|
| |
Remove the general infrastructure for these additional platform
definitions and hard-code the only two special cases that used
it. They are only for historical reasons so no new such cases
should be added.
|
|
|
|
|
| |
Consume the space before the platform name as soon as possible
instead of including it in the comparison.
|
|
|
|
|
|
|
| |
Divide the cmGlobalVisualStudio10Generator "PlatformToolset" member into
two members representing the generator-selected default toolset and the
user-specified CMAKE_GENERATOR_TOOLSET value. Prefer the user-specified
value, if any, and then fall back to the generator-selected default.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
Drop the "Modules/CMakeVS*FindMake.cmake" files. Override the
cmGlobalGenerator::FindMakeProgram method for VS generators to use their
internal APIs to locate the build tool. Set the CMAKE_MAKE_PROGRAM as a
normal variable for use by project code, but do not cache it. This will
allow CMake and CTest to select the proper tool at build time.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Rename the Visual Studio >= 10 generators to indicate the version year:
Visual Studio 10 => Visual Studio 10 2010
Visual Studio 11 => Visual Studio 11 2012
Visual Studio 12 => Visual Stduio 12 2013
Report the names with the year to the list of available generators so
that the cmake-gui drop-down shows the years. When selecting a
generator from the "-G" option or from an existing CMAKE_GENERATOR cache
entry, recognize names without the years for compatibility and map them
to the names with years.
Update the generator names in the cmake-generators.7 manual.
|
|
|
|
|
| |
We need only 'Brief' for usage documentation. We no longer have builtin
'Full' documentation, which is now in Help/*/*.rst files.
|
|
|
|
|
| |
Use the value of the provided argument instead of using a fixed
character buffer. This aligns VS10+VS11+VS12 with VS8+VS9.
|
|
|
|
|
| |
cmGlobalVisualStudio11Generator generator already defines the same
function body, which makes the additional overload useless.
|
|
|
|
|
|
|
|
| |
Since we do not need the information about the target architecture
we can use the PlatformName only to specify the this information.
This also removes setting of the MSVC_*_ARCHITECTURE_ID variable
which is not required, because this variable gets set by the
compiler detection code in CMAKE_DETERMINE_COMPILER_ID_CHECK().
|
|
|
|
|
|
| |
Add to the brief documentation of the Visual Studio 10, 11, and 12
generators the corresponding VS product year. Clarify that VS11 is for
Visual Studio 2012, and VS12 is for Visual Studio 2013.
|
|
Copy cmGlobalVisualStudio11Generator to cmGlobalVisualStudio12Generator
and update version numbers accordingly. Add the VS12 enumeration value.
Add module CMakeVS12FindMake to find MSBuild. Look for MSBuild in its
now-dedicated Windows Registry entry. Teach the platform module
Windows-MSVC to set MSVC12 and document the variable. Teach module
InstallRequiredSystemLibraries to look for the VS 12 runtime libraries.
Teach tests CheckCompilerRelatedVariables, Preprocess, VSExternalInclude,
and RunCMake.GeneratorToolset to treat VS 12 as they do VS 10 and 11.
Inspired-by: Minmin Gong <minmin.gong@gmail.com>
|