Commit f7d15075 authored by Viktor Wallner's avatar Viktor Wallner
Browse files

Add uVision Generator

parent ac4f83d9
Pipeline #220297 waiting for manual action with stages
in 9 minutes and 25 seconds
uVision
------------
.. versionadded:: 3.20
Generates uVision project files.
Instance Selection
^^^^^^^^^^^^^^^^^^
uVision supports multiple installations on the same machine.
The :variable:`CMAKE_GENERATOR_INSTANCE` variable may be set as a
cache entry containing the absolute path to a uVision instance.
Toolset Selection
^^^^^^^^^^^^^^^^^
The ``ARMClang`` toolset is selected by default.
The :variable:`CMAKE_GENERATOR_TOOLSET` option may be set, perhaps
via the :manual:`cmake(1)` ``-T`` option, to specify another toolset.
The toolset must be located in the ARM Folder of the
uVision installation folder (e.g. 'C:\\Keil\\ARM\\ARMCC' for the 'ARMCC' toolset).
Device Selection
^^^^^^^^^^^^^^^^
The device to use must be selected by setting the variable :variable:`CMAKE_UV_DEVICE`.
This must be done either with the :manual:`cmake(1)` ``-D`` option or prior to the very first
:command:`project` command.
The generator always tries to create a .uvprojx project file first, which uses device packs.
If no Pack for the selected device is installed, the generator tries to generate a .uvproj project,
which uses the legacy device database.
Packs
^^^^^
Packs are only available in the .uvprojx project format and must be added as imported module
libraries and linked against.
.. code-block:: cmake
add_library(ARM::CMSIS:CORE MODULE IMPORTED)
set_target_properties(ARM::CMSIS:CORE PROPERTIES
IMPORTED_LOCATION "Pack"
UV_PACK "ARM.CMSIS"
UV_COMPONENT "ARM::CMSIS:CORE")
target_link_libraries(MyProject PRIVATE ARM::CMSIS:CORE)
.. note::
This generator is deemed experimental as of CMake |release|
and is still a work in progress. Future versions of CMake
may make breaking changes as the generator matures.
......@@ -99,6 +99,7 @@ Other Generators
:maxdepth: 1
/generator/Green Hills MULTI
/generator/uVision
/generator/Xcode
Extra Generators
......
......@@ -356,6 +356,19 @@ Properties on Targets
/prop_tgt/UNITY_BUILD_CODE_BEFORE_INCLUDE
/prop_tgt/UNITY_BUILD_MODE
/prop_tgt/UNITY_BUILD_UNIQUE_ID
/prop_tgt/UV_BROWSE_INFORMATION
/prop_tgt/UV_COMPONENT
/prop_tgt/UV_COMPONENT_VERSION
/prop_tgt/UV_CREATE_HEX_FILE
/prop_tgt/UV_DEBUG_SIMULATOR
/prop_tgt/UV_DEBUG_SIMULATOR_INI
/prop_tgt/UV_DEBUG_TARGET
/prop_tgt/UV_DEBUG_TARGET_DLL
/prop_tgt/UV_DEBUG_TARGET_INI
/prop_tgt/UV_PACK
/prop_tgt/UV_PACK_VERSION
/prop_tgt/UV_PREPROCESSOR_LISTING
/prop_tgt/UV_USE_MICROLIB
/prop_tgt/VERSION
/prop_tgt/VISIBILITY_INLINES_HIDDEN
/prop_tgt/VS_CONFIGURATION_TYPE
......
......@@ -296,6 +296,7 @@ Variables that Describe the System
/variable/CMAKE_SYSTEM_NAME
/variable/CMAKE_SYSTEM_PROCESSOR
/variable/CMAKE_SYSTEM_VERSION
/variable/CMAKE_UV_DEVICE
/variable/CYGWIN
/variable/GHS-MULTI
/variable/IOS
......
UV_BROWSE_INFORMATION
---------------------
.. versionadded:: 3.20
:generator:`uVision` target property to enable the generation of browse information.
UV_COMPONENT
------------
.. versionadded:: 3.20
:generator:`uVision` target property to select the component of an imported pack target.
UV_COMPONENT_VERSION
--------------------
.. versionadded:: 3.20
:generator:`uVision` target property to select the component version of an imported pack target.
UV_CREATE_HEX_FILE
------------------
.. versionadded:: 3.20
:generator:`uVision` target property to enable the generation of a hex file information.
UV_DEBUG_SIMULATOR
------------------
.. versionadded:: 3.20
:generator:`uVision` target property to set the simulator as debugging device.
UV_DEBUG_SIMULATOR_INI
----------------------
.. versionadded:: 3.20
:generator:`uVision` target property to set the initialization file for simulator debugging.
If an initialization file is set, the 'Load Application at Startup' option is disabled.
UV_DEBUG_TARGET
---------------
.. versionadded:: 3.20
:generator:`uVision` target property to set the target as debugging device.
UV_DEBUG_TARGET_DLL
-------------------
.. versionadded:: 3.20
:generator:`uVision` target property to set the target DLL to use.
The string must match a value of the TDRV\* entries in the Tools.ini of the uVision instance.
UV_DEBUG_TARGET_INI
-------------------
.. versionadded:: 3.20
:generator:`uVision` target property to set the initialization file for target debugging.
If an initialization file is set, the 'Load Application at Startup' option is disabled.
UV_PACK
-------
.. versionadded:: 3.20
:generator:`uVision` target property to select the pack of an imported pack target.
UV_PACK_VERSION
---------------
.. versionadded:: 3.20
:generator:`uVision` target property to select the pack version of an imported pack target.
UV_PREPROCESSOR_LISTING
-----------------------
.. versionadded:: 3.20
:generator:`uVision` target property to enable the generation of preprocessor listings.
UV_USE_MICROLIB
---------------
.. versionadded:: 3.20
:generator:`uVision` target property to enable the usage of the MicroLIB.
......@@ -20,6 +20,7 @@ Toolset specification is supported only on specific generators:
* :ref:`Visual Studio Generators` for VS 2010 and above
* The :generator:`Xcode` generator for Xcode 3.0 and above
* The :generator:`Green Hills MULTI` generator
* The :generator:`uVision` generator
See native build system documentation for allowed toolset names.
......
CMAKE_UV_DEVICE
----------------------
.. versionadded:: 3.20
:generator:`uVision` global variable to select the device to use.
This variable must be set either with the :manual:`cmake(1)` ``-D`` option or prior to the very first
:command:`project` command.
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
find_package(UVision)
set(CMAKE_MAKE_PROGRAM ${UVISION_EXECUTABLE} CACHE FILEPATH "" FORCE)
mark_as_advanced(CMAKE_MAKE_PROGRAM)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment