summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalGhsMultiGenerator.h
Commit message (Collapse)AuthorAgeFilesLines
* GlobalGenerator family: modernize memory managementMarc Chevrier2020-01-071-2/+3
|
* cmLocalGenerator: modernize memory managementMarc Chevrier2019-12-091-1/+3
|
* cmake: Teach --build mode to load CMAKE_GENERATOR_TOOLSETAlexander Boczar2019-10-151-1/+2
| | | | | Extend the `cmGlobalGenerator::SetGeneratorToolset` signature to indicate when it is called from `cmake::build`.
* Revise include order using clang-format-6.0Kitware Robot2019-10-011-5/+4
| | | | | 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.
* clang-tidy: Replace typedef with usingRegina Pfeifer2019-09-041-3/+2
| | | | | | | | Automate the conversion with perl -i -0pe 's/typedef ([^;]*) ([^ ]+);/using $2 = $1;/g' then manually fix a few places.
* clang-tidy: Replace typedef with usingRegina Pfeifer2019-09-031-1/+1
|
* GHS: Update project layout to accommodate gbuild inconsistenciesFred Baksik2019-04-111-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | -- Do not use reference projects, use build hierarchy instead. gbuild has three parallel levels: * low -- Parallelizes compiling source files within a single project (.gpj) file when safe to do so. * medium -- Parallelizes processing files within a single linked output when safe to do so. * high [default] -- Parallelizes processing files whenever safe to do so, including linking task. Testing showed that for some combinations of gbuild / MULTI there are issues with building a project that uses references to target project files along with using {nobuild} option. Sometimes the archiving of a library and linking of an executable were happening in parallel and the build would fail when linking because the archive wasn't complete. This behavior was also inconsistent when running the build from MULTI and from the command line with gbuild. In some cases MULTI did not parallelize archiving and linking, but gbuild performed these actions in parallel. The parallel build issue was not seen when using a build hierarchy where the project listed the project files normally instead of using a reference link. The other option was to add the -parallel_level=medium to the command line when using "cmake --build" but this wouldn't fix the issue if gbuild itself was used to and the user might not be aware of the extra option used by cmake.
* GHS: Update project layout to build targets correctlyFred Baksik2019-04-111-31/+40
| | | | | | | | | | -- Restructure projects and files to support proper building of targets Build order is determined by hierarchy of project files and folders Custom targets may have been run multiple times in the original file / folder structure -- Default to build targets that are part of ALL target -- List all known targets for this project Includes global targets for ALL_BUILD and INSTALL -- Compute build order for building targets
* GHS: Support add_dependencies() commandFred Baksik2019-04-111-8/+11
| | | | -- use references to list target dependencies
* GHS: Support add_custom_target() commandFred Baksik2019-04-111-2/+10
| | | | -- add new project type that runs shell scripts in proper order
* GHS: Support add_custom_command( OUTPUT ) signatureFred Baksik2019-04-111-1/+2
| | | | | | | -- add new file type to run a shell script -- gbuild does not compute interfile dependencies like other build tools. Therefore calculate the required build order of custom commands and list all of them in the CMake Rules subproject.
* Merge topic 'ghs_os_dir'Brad King2019-04-081-0/+1
|\ | | | | | | | | | | | | | | a1e6b414b9 GHS: Update GHS_BSP_NAME processing 266dadf868 GHS: Print status message regarding GHS_OS_DIR Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !3123
| * GHS: Print status message regarding GHS_OS_DIRFred Baksik2019-03-291-0/+1
| | | | | | | | | | | | | | | | | | -- Rename platform script so it runs before initial try_compile() in project() command. -- Fix incorrect variable name GHS_OS_DIR_OPTION -- Remove unnecessary ".*" from REGEX expression for GHS_CANDIDATE_OS_DIRS -- Forward GHS_OS_DIR_OPTION to try_compile() and preserve trailing whitespace of the variable.
* | Fix invalid ///! doxygen comment line startsSebastian Holtermann2019-03-311-2/+2
|/ | | | | In various places `///!` was used to start a comment line. This is not valid Doygen syntax. This patch replaces `///!` comment starts with `//!`.
* GHS: Fix include-what-you-use and clang-tidy diagnosticsBrad King2019-03-201-6/+16
| | | | We will soon build GHS sources on Linux where we run these lints.
* cmake: Teach --build mode to support multiple targetsBartosz Kosiorek2019-03-051-9/+6
| | | | Fixes: #16136
* 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.
* GHS: Fix toolset selectionFred Baksik2019-01-161-1/+1
| | | | | | -- Allow -T to accept full or partial paths -- Use "C:/ghs" if GHS_TOOLSET_ROOT is empty string -- Put more information in error messages
* GHS: EXCLUDE_FROM_ALL updatesFred Baksik2019-01-161-2/+0
| | | | | -- Excluded targets should be generated but not included in build ALL -- Use the correct source list for this configuration when writing sources
* GHS: Cleanup unused file handling functions and file output updatesFred Baksik2019-01-161-39/+3
| | | | | | -- File handling cleanup -- Rename some functions to clarify what they do -- Update to source file path conversion; only perform conversion when using windows
* GHS: Place build system outputs per target output directivesFred Baksik2019-01-161-0/+2
| | | | | | | | | | | | | | -- Set output and object file locations -- Suffixes are no longer being forced but will now follow the target properties By default GHS tools have no suffix for executable files so CMAKE_EXECUTABLE_SUFFIX was changed to meet this behavior -- Remove #if 0 blocked out code; it has been replaced. Forcing the -relprog option has been removed from non-kernel executable targets. The default value of this option (if it is even available) is determined by the tool-chain for the specified target and platform (Some tool-chains default to -locatedprogram). The use of -relprog can have unexpected results as it cannot always produce a fully relocated executable. -- Clarify use of CMAKE_BUILD_TYPE to control build configuration
* GHS: Update the top-level project generationFred Baksik2019-01-161-4/+42
| | | | | | | | | | | | -- Sort targets by name -- Generate a top-level project for each project command named as project.top.gpj Use the target set for the current project instead of assuming all targets -- Add support for building projects not in binary root -- Directly create files and pass ostream -- Do no generate project files for UTILITY targets; this was never supported -- Do no generate project files for OBJECT, SHARED, or MODULE libraries; this was never supported -- Update GHS tags to support project types NOTE: The default tag is changed to "" because "[ ]" is an invalid token in project file
* GHS: Have the top-level project name follow the specified project nameFred Baksik2019-01-161-1/+1
|
* GHS: Only print bsp and os directives if specified by userFred Baksik2019-01-161-3/+0
| | | | | | | | | -- standalone platforms will not build if bsp/os is specified in project file -- integrity platforms will always print these directives because they are required -- cleanup -os_dir setting allow customization of the actual setting because it is determined by tool-set customization files remove variable that was set but never used -- add message when using default values
* Add missing overrideVitaly Stakhovsky2018-12-301-13/+16
|
* GHS: Add toolset selection supportFred Baksik2018-07-111-8/+4
| | | | | | | | | | | | | | | | -- Use the specified toolset located within GHS_TOOLSET_ROOT -- Update how the latest toolset is determined; scan the location GHS_TOOLSET_ROOT and sort it No longer use registry settings looking for installations The registry values are assigned in installation order for Green Hills tools not version order -- Update to use gbuild.exe from the proper toolset -- Clarify that CMAKE_MAKE_PROGRAM should not be set by user. -- Detect some toolset changes when regenerating project files This could occur if GHS_TOOLSET_ROOT was changed by user after the initial project generation This could occur if CMAKE_MAKE_PROGRAM was changed at the command line -- Use placeholder values for CMAKE_<LANG>_COMPILER The MULTI build system only uses gbuild to build a project gbuild uses the project file to determine which set of compilers to use based on target platform and architecture because compiler detection is skipped, placeholder values are used so that CMake does not complain
* GHS: Support ARM, PPC, 86 architecturesFred Baksik2018-07-071-2/+5
| | | | | | -- Update -A option to choose target architecture. -- Update commentary about which variables are used to control toolset and target settings -- Remove setting CMAKE_SYSTEM_PROCESSOR because the value is overwritten to be "" by subsequent CMAKE processing
* Update use of KWSys SystemTools::SplitString for new signatureBrad King2018-06-221-3/+2
|
* Revise C++ coding style using clang-format-6.0Kitware Robot2018-06-011-5/+5
| | | | | | | | | | | | 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-1/+1
| | | | | | | 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.
* Use C++11 override instead of CM_OVERRIDEBrad King2017-09-151-1/+1
| | | | | | | | 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'
* Performance: Fix a few more unnecessary vector copies missed in af3fd6fAaron Orenstein2017-08-181-1/+1
|
* 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.
* CMake: Report whether generators support platformsTobias Hunger2016-07-141-0/+6
|
* Revise C++ coding style using clang-formatKitware Robot2016-05-161-44/+45
| | | | | | | | | | | | | 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-1/+2
| | | | | 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.
* cmake-gui: Add option to specify generator toolsetRobert Dailey2015-11-171-0/+7
| | | | | | | | | | 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.
* GHS: Port to cmGeneratorTarget.Stephen Kelly2015-10-241-1/+1
|
* cmLocalGenerator: Store a vector of generator targets.Stephen Kelly2015-10-211-1/+1
| | | | Not a map from cmTarget to cmGeneratorTarget.
* cmLocalGenerator: Create from already-constructed cmMakefile.Stephen Kelly2015-08-281-1/+1
| | | | Don't manage the lifetime of the cmMakefile with cmLocalGenerator.
* cmLocalGenerator: Remove Parent pointer.Stephen Kelly2015-08-281-2/+1
|
* cmLocalGenerator: Require a valid cmState::Snapshot in the ctor.Stephen Kelly2015-05-271-1/+2
| | | | | | | | | | | Refactor the local generator creation API to accept a cmState::Snapshot. Adjust MakeLocalGenerator to use the 'current' snapshot in cases where there is no parent. Create the snapshot for subdirectories in cmMakefile::AddSubdirectory. This means that snapshots are now created at the point of extending the tree, as appropriate, and independently of the cmLocalGenerator and cmMakefile they represent the state for.
* cmGlobalGenerator: Require a cmake instance in ctor.Stephen Kelly2015-05-271-1/+1
| | | | It is required anyway, so this makes it explicit.
* cmLocalGenerator: Require a parent in the constructor.Stephen Kelly2015-04-281-1/+1
| | | | | | | Pass the parent though cmGlobalGenerator::CreateLocalGenerator. This will make it easy to initialize state scopes independent of cmMakefile.
* Add a 'Green Hills MULTI' generator on WindowsGeoff Viola2015-04-201-0/+127
Green Hills MULTI is an IDE for embedded real-time systems. The IDE's product page can be found here: http://www.ghs.com/products/MULTI_IDE.html It supports cross compiling on ARM, Intel x86, and other architectures with various operating systems. The IDE exists on Linux and Windows host systems, but CMake will currently only generate the project files on Windows host systems.