summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalXCodeGenerator.h
Commit message (Collapse)AuthorAgeFilesLines
* clang-tidy: Resolve performance-unnecessary-value-param diagnosticsBrad King2019-09-091-7/+5
| | | | | | Fix diagnostics that appear on macOS with clang-tidy-8. Suppress cases where we intentionally take an argument by value to let the caller choose whether to copy or move.
* Fix invalid ///! doxygen comment line startsSebastian Holtermann2019-03-311-4/+4
| | | | | In various places `///!` was used to start a comment line. This is not valid Doygen syntax. This patch replaces `///!` comment starts with `//!`.
* Xcode: Create Xcode schemes per targetHarry Mallon2019-03-211-3/+4
|
* cmGlobalXCodeGenerator: Prefer std::string over char*Gregor Jasny2019-03-171-2/+2
|
* cmake: Teach --build mode to support multiple targetsBartosz Kosiorek2019-03-051-9/+6
| | | | Fixes: #16136
* Xcode: Place object library artifacts outside Objects-normal directoryBrad King2019-01-301-3/+4
| | | | | | | | | | | The `CONFIGURATION_BUILD_DIR` value in the Xcode project file specifies where to place the library artifact. For object libraries we've used the `Objects-normal` directory to hide away the `.a` that we otherwise cannot stop Xcode from producing. The parent of this directory is also specific to the target and does not vary with Xcode's sanitizer features, so move the artifact there. Issue: #16289
* cmGlobalGenerator: Add a class that represent the build commandRobert Maynard2019-01-251-1/+1
| | | | | | This refactors a std::vector<std::string> into a class so that we can extend the features to represent things such as multiple chained commands in the future.
* POSITION_INDEPENDENT_CODE: Manage link flags for executablesMarc Chevrier2018-11-111-0/+3
| | | | Fixes: #14983, #16561
* cmGlobalGenerator: Add IsXcode queryBrad King2018-08-011-0/+2
| | | | Make it easy to detect use of the Xcode generator.
* Xcode: Factor target generation loop body into helper methodBrad King2018-07-191-0/+2
|
* Xcode: Compute global order index for targetsBrad King2018-07-191-0/+3
| | | | | Compute an index for each target in a global ordering such that no target comes before its dependencies.
* Xcode: Use legacy build systemGregor Jasny2018-06-191-1/+3
| | | | Closes: #18099
* Revise C++ coding style using clang-format-6.0Kitware Robot2018-06-011-5/+8
| | | | | | | | | | | | Run the `clang-format.bash` script to update all our C and C++ code to a new style defined by `.clang-format`. Use `clang-format` version 6.0. * 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.
* cmake: Add options for parallel builds to --build modeFlorian Maushart2018-05-251-7/+5
| | | | | | | While we already support `cmake --build . -- -j`, the options after `--` are specific to the native build tool. Add new options `--parallel [<N>]` and `-j [<N>]` to abstract this and map to the proper option for the native build tool.
* Restore support for explicitly referenced CMakeLists.txt sourcesBrad King2018-04-131-0/+2
| | | | | | | | | | | | | | Since commit v3.11.0-rc1~467^2 (VS,Xcode: Add CMakeLists.txt sources without mutating targets, 2017-10-18) we do not add `CMakeLists.txt` to target sources but instead generate references to them directly. This broke projects that explicitly specify their `CMakeLists.txt` file as a source file because the explicit entry is no longer consolidated with the generated one. Teach the relevant generators to avoid duplicating `CMakeLists.txt` source references and add test cases. Fixes: #17828
* Reduce raw string pointers usage.Pavel Solodovnikov2018-01-311-1/+1
| | | | | | | | | | * 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.
* LocalGenerator: refactoringMarc Chevrier2018-01-231-1/+1
| | | | | Introduce method AppendCompileOptions to support future source file property COMPILE_OPTIONS.
* Darwin: Emit deployment target that matches the SDKGregor Jasny2017-12-221-0/+2
| | | | Closes: #17431
* cmake: Add --open option for IDE generatorsGregor Jasny2017-10-131-0/+7
|
* Fix some occurrences using string by value rather than by const&Matthias Maennich2017-09-281-1/+2
| | | | | | | | Fix issues diagnosed by clang-tidy - performance-unnecessary-value-param - performance-unnecessary-copy-initialization Signed-off-by: Matthias Maennich <matthias@maennich.net>
* Use C++11 override instead of CM_OVERRIDEBrad King2017-09-151-21/+21
| | | | | | | | 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.
* Xcode: Use correct Object Library paths for cross-SDK buildsGregor Jasny2017-06-291-1/+1
| | | | | | | | When calculating Object Library paths take a look at the `XCODE_EMIT_EFFECTIVE_PLATFORM_NAME` property to enable builds with different SDKs. Otherwise a hard-coded architecture could be chosen. Fixes: #16040
* Merge topic 'remove-top-level-xcode-groups'Brad King2017-05-041-2/+0
|\ | | | | | | | | | | | | 01cd88c0 Xcode: Remove the top-level Sources and Resources groups Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !779
| * Xcode: Remove the top-level Sources and Resources groupsMatt Stevens2017-05-031-2/+0
| | | | | | | | | | | | | | | | | | | | | | This addresses duplicate file reference warnings from xcodebuild caused by the same file reference being a member of both the target's group and the top-level Resources group. Since resources are already a member of their associated target's group the top-level Resources group isn't strictly necessary, and removing it results in a project structure closer to that of a current Xcode project template. Fixes: #15272
* | Xcode: Support IPO (LTO)Ruslan Baratov2017-05-021-0/+2
|/
* Xcode: Compute version number earlierBrad King2017-04-211-1/+2
|
* cmGlobalGenerator: Add method to check if object file location is knownBrad King2017-04-181-0/+2
| | | | | | | Add a `HasKnownObjectFileLocation` method returning whether we know the exact location of object files produced by the native build system. This is true everywhere except on Xcode when an architecture placeholder is used.
* Merge topic 'include-style'Brad King2017-04-131-1/+2
|\ | | | | | | | | | | | | | | | | 1d829c86 Use quotes for non-system includes 26ee9e42 CPack: drop CPack prefix for includes 5afac50f cmConfigure: Ensure separate include block in headers Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !691
| * 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'
| * cmConfigure: Ensure separate include block in headersDaniel Pfeifer2017-04-111-0/+1
| | | | | | | | | | | | | | | | | | | | | | Make sure that `#include <cmConfigure.h>` is followed by an empty line in header files. This is necessary to make sure that changing <> to "" does not affect the include ordering of clang-format. Automate with: git grep -l '#include <cmConfigure.h>' | grep -v '.cxx$' \ | xargs sed -i '/#include <cmConfigure.h>/ { N; N; s/\n\{1,2\}/\n\n/ }'
* | Xcode: Compute a concrete object file arch dir if possibleBrad King2017-04-111-0/+1
| |
* | Xcode: Refactor object directory name computationBrad King2017-04-111-0/+2
| | | | | | | | | | Factor out a helper function to compute the object directory name architecture component.
* | Xcode: Refactor internal architecture list constructionBrad King2017-04-111-0/+2
|/ | | | | Factor population of the `Architectures` member out into a helper to avoid duplication.
* Apple: Fix Resources location for all generatorsGregor Jasny2017-03-231-0/+2
| | | | Issue: #16680
* Xcode: Fix schema container location calculationGregor Jasny2017-02-281-2/+1
|
* Xcode: Do not autocreate schemesGregor Jasny2017-02-281-0/+1
|
* Xcode: Write shared schemes based on the default files generated by XcodeGusts Kaksis2017-02-281-0/+3
| | | | Issue: #15441
* Xcode: Control emission of EFFECTIVE_PLATFORM_NAMEGregor Jasny2017-01-201-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When building with multiple SDKs within one project Xcode requires the usage of ${EFFECTIVE_PLATFORM_NAME} to put temporary and build outout into separate directories. For example an iOS device and simulator build use two different SDKs (iphoneos and iphonesimulator). In the past cmake tries to detect embedded toolchains that could possibly use simulators and emitted EFFECTIVE_PLATFORM_NAME (EPN) at the proper locations. In #16253 Mark noticed that if he uses macosx and iphoneos in combination the necessary EPN is not emitted. This is because CMake by default assumes macosx SDK which does not trigger EPN emission. The fist naive approach - enabling EPN unconditionally revealed that then the EPN leaks into generator expressions like $<TARGET_FILE:xxx> which might be a regression and thus is unacceptable. The next approach was to add an CMake property to enable EPN emission unconditionally. This solved the reported problem. But the EPN leakage also happened for the embedded toolchains already without anyone noticing. So the control property was turned into a tri-state one: * No definition: EPN is activated for embedded toolchains like before * ON: EPN is always emitted * OFF: EPN is never emitted That approach gives the user the chance to disable EPN for embedded toolchains and restores generator expression functionality for those. Closes: #16253
* iwyu: Fix OSX specific issuesDaniel Pfeifer2016-11-221-2/+14
|
* Xcode: Add override keyword to suppress warningsGregor Jasny2016-11-171-26/+28
|
* cmGlobalGenerator: Allow FindMakeProgram to failBrad King2016-10-201-1/+1
| | | | | Revise its signature to return `bool` so that it can fail and abort configuration early.
* 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.
* Xcode: Remove unused memberStephen Kelly2016-09-191-1/+0
| | | | | It is unused since commit v3.4.0-rc1~492^2~3 (Remove CMAKE_USE_RELATIVE_PATHS variable., 2015-06-01).
* Xcode: Add targets marked as EXCLUDE_FROM_ALL to project (#16101)Gregor Jasny2016-08-311-2/+1
|
* cmGlobalGenerator: Make IsMultiConfig() constTobias Hunger2016-06-011-1/+1
|
* Revise C++ coding style using clang-formatKitware Robot2016-05-161-59/+55
| | | | | | | | | | | | | 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.
* Format include directive blocks and ordering with clang-formatBrad King2016-04-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* Source: Stabilize include orderBrad King2016-04-291-0/+1
| | | | | 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.
* make cmGlobalXCodeGenerator::XCodeEscapePath() take a std::string&Rolf Eike Beer2016-04-201-1/+1
| | | | | All callers already have one, and it was immediately converted to one internally. Just keep the old one around, and only modify it when needed.