summaryrefslogtreecommitdiffstats
path: root/Help/manual/cmake-generator-expressions.7.rst
Commit message (Collapse)AuthorAgeFilesLines
* Genex: Enable COMPILE_LANGUAGE for COMPILE_OPTIONS with Visual StudioBrad King2017-11-201-5/+7
| | | | | | | | | | | | | | | | | | | Since commit v3.9.0-rc4~3^2~1 (VS: Fix target_compile_options for CUDA, 2017-06-21), the evaluation of `COMPILE_LANGUAGE` receives the proper language. The set of compile flags used for a target's C and C++ sources is based on the linker language. By default this is always the C++ flags if any C++ sources appear in the target, and otherwise the C flags. Therefore we can define the `COMPILE_LANGUAGE` generator expression in `COMPILE_OPTIONS` to match the selected language. This is not exactly the same as for other generators, but is the best VS can do. It is also sufficient for many use cases since the set of allowed flags for C and C++ is almost the same in Visual Studio. Furthermore, since the VS generator moves many of the flags to declarative `.vcxproj` elements, it will automatically avoid passing C++ flags for C sources. Issue: #17435
* Genex: Allow TARGET_OBJECTS to be used everywhereRobert Maynard2017-04-181-3/+1
| | | | | | | | | Previously the `TARGET_OBJECTS` generator expression was limited only to use in a buildsystem context so that Xcode's placeholders in object file paths can be evaluated. Lift this restriction so that the expression can at least be used in most settings. Co-Author: Brad King <brad.king@kitware.com>
* Help: Fix error in $<COMPILE_LANGUAGE:lang> exampleNils Gladitz2017-04-041-1/+1
|
* Genex: Add `TARGET_BUNDLE_[CONTENT_]_DIR` generator expressionsGregor Jasny2017-03-301-0/+9
| | | | Closes #16733
* Genex: Add `IF` generator expressionColby Pike2017-01-261-0/+2
| | | | | | | | This allows a single condition to be used to choose between two alternatives. Without this the condition must be duplicated with one surrounded by `NOT`. Closes: #15585
* Add additional <= and >= comparison operatorsChuck Atkins2016-08-091-2/+6
| | | | | This adds the LESS_EQUAL, GREATER_EQUAL, and associated STR and VERSION equivalents to use the combined <= and >= functionality.
* Fix spelling typos in comments and documentation (#16037)Felix Geyer2016-03-291-1/+1
| | | | | The Debian package checker tool (lintian) detected several typos in CMake.
* Genex: Add a SHELL_PATH expressionStefan Kislinskiy2015-09-281-0/+4
| | | | | | | | | Some commands on Windows do not understand forward slash paths and require backslashes. In order to help projects generate shell invocations of such commands, provide a generator expression to convert paths to the shell-preferred path format for the current generator. This will allow custom commands to generate paths the same way CMake does for compiler command invocations.
* Help: Document supported compilers in cmake-compile-features.7Robert Maynard2015-04-071-1/+1
| | | | | | | Extend sentences in other documentation linking to this manual to say that it has a list of supported compilers. Co-Author: Brad King <brad.king@kitware.com>
* Help: Move docs of $<0:...> and $<1:...> to output section.Stephen Kelly2015-03-101-4/+4
| | | | | These are not 'logical' expressions. They create output and are often used together with the logical expressions.
* Genex: Allow COMPILE_LANGUAGE when processing include directories.Stephen Kelly2015-03-091-1/+5
| | | | Issue an error if this is encountered by an IDE generator.
* Genex: Allow COMPILE_LANGUAGE when processing compile definitions.Stephen Kelly2015-03-091-0/+10
| | | | Issue an error if this is encountered by an IDE generator.
* Genex: Enable use of COMPILE_LANGUAGE for compile options.Stephen Kelly2015-03-091-0/+30
| | | | | | Follow-ups will allow the use of the generator expression for compile definitions and include directories for non-IDE generators.
* Help: Drop TOC from latex manualsBrad King2014-11-061-1/+1
| | | | A latex document can have its own TOC.
* Help/manual: Avoid long lines in code blocksBrad King2014-10-221-1/+11
| | | | | | Update the wording of some examples to avoid long lines in code blocks. Otherwise the formatted documentation can exceed certain column width limitations.
* Genex: Implement generator expressions for target PDB files.Nils Gladitz2014-07-311-0/+11
|
* Make $<LINK_ONLY> available to projects (#14751)Brad King2014-07-161-0/+7
| | | | | | | | Previously this generator expression was used internally by the target_link_libraries command to honor private linking requirements of static libraries in their INTERFACE_LINK_LIBRARIES. Remove the check that limits $<LINK_ONLY> to this use case to make it available for project code to use too.
* Help: Link to variables corresponding to id and version expressions (#15012)Brad King2014-07-141-1/+6
| | | | | | In the cmake-generator-expressions(7) manual, link to the variables that correspond to the PLATFORM_ID, C_COMPILER_ID, CXX_COMPILER_ID, C_COMPILER_VERSION, and CXX_COMPILER_VERSION generator expressions.
* Help: Add a manual for compiler feature control.Stephen Kelly2014-05-271-1/+3
| | | | | | | | Link to it from the documentation of related properties, variables and commands. Extend the cmake-developer(7) documentation with notes on extending feature support for compilers.
* Features: Add COMPILE_FEATURES generator expression.Stephen Kelly2014-05-211-0/+6
| | | | | | | | | | | | Allow setting build properties based on the features available for a target. The availability of features is determined at generate-time by evaluating the link implementation. Ensure that the <LANG>_STANDARD determined while evaluating COMPILE_FEATURES in the link implementation is not lower than that provided by the INTERFACE of the link implementation. This is similar to handling of transitive properties such as POSITION_INDEPENDENT_CODE.
* Genex: Only evaluate TARGET_OBJECTS to determine target sources.Stephen Kelly2014-04-021-1/+3
| | | | | | | | | | The output of this expression may contain macros for IDEs to replace such as $(Configuration), $(CURRENT_ARCH) etc. To avoid generating content which is not usable in other contexts, report an error if there is an attempt to use it in other contexts. This commit may be reverted in the future if a solution to the above difference is implemented.
* Genex: Evaluate TARGET_OBJECTS as a normal expression.Stephen Kelly2014-03-311-0/+3
|
* Genex: Add a nullary form for CONFIGStephen Kelly2014-01-071-0/+2
| | | | | | | | | | | | | This is consistent with other similar expressions such as PLATFORM_ID, and makes the CONFIGURATION expression obsolete. Fix an off-by-one error in GeneratorExpressionContent::EvaluateParameters exposed by a unit test. Remove the test for 'bad' nullary use of $<CONFIG>. Add a unit test to verify that $<CONFIG> and $<CONFIGURATION> have the same value.
* Genex: Add EQUAL expression.Stephen Kelly2014-01-061-0/+2
| | | | Support decimal, hex, octal and binary literals.
* Genex: Add {UPPER,LOWER}_CASE and MAKE_C_IDENTIFIER.Stephen Kelly2013-11-271-0/+6
|
* Help: Fix typo in genex docs.Stephen Kelly2013-11-261-1/+1
| | | | would be require -> would require
* Help: Reformat cmake-generator-expressions.7 manualStephen Kelly2013-11-211-77/+171
| | | | | | | | | | | | | | | | | | | | | Use definition lists instead of a preformatted block to enumerate the genex documentation. Consistently capitalize the description. Use ``...`` to format genex parameters in the description. Turn references to commands into links. Add high level documentation about the motivation for generator expressions. Regroup expressions into subsections for different genex types. Add a high-level description and example of the expressions in each section. Explode the documentation for filesystem artifacts, instead of only referring to the variations.
* Help: Glob manual/*.rst in Sphinx configurationBrad King2013-10-301-0/+2
| | | | | | | Add the man page description line as explicit markup at the top of each Help/manual/*.rst file and scan it from conf.py to automatically generate the man_pages Sphinx configuration value. This reduces the number of places that need to be changed when a new manual is added.
* Help: Factor out cmake-generator-expressions manual pageBrad King2013-10-161-0/+84
Generator expressions are supported in many places and are a distinct concept worthy of their own manual page. The old builtin documentation was previously represented by preprocessor macros to generate it into each place that supports them. Factor out the duplicate content into a dedicated cmake-generator-expressions manual page and reference it from each original location.