-
Notifications
You must be signed in to change notification settings - Fork 95
Records
Records are written using YAML syntax. There are 3 types of records
- Projects list file
- Project definition file
- Module file
Important note, all paths in records require to be defined with a full path (from the root directory).
### Projects list file It defines all projects available for repository. It can consist of one or more projects. Each project includes other records - one project definition file and many modules.k20_blinky: - tools/records/common.yaml - tools/records/k20_cmsis.yaml - tools/records/k20_target.yaml - tools/records/projects/k20_blinky.yaml lpc1768_blinky: - tools/records/common.yaml - tools/records/lpc1768_cmsis.yaml - tools/records/lpc1768_target.yaml - tools/records/projects/lpc1768_blinky.yaml### Project definition file
This is a unique record file. It defines specific attributs for specified project.
name: - lpc1768_blinky core: - cortex-m3 common: include_paths: - examples/blinky source_paths: - examples/blinky source_files: - examples/blinky/main.cpp macros: - TARGET_LPC1768### Module file
This is a file which defines a module. A module is bunch of files with common attributes. For instance, if there are target specific files, we can create a new module named target_specific.yaml file and define all attributes specific for that module.
common: group_name: lpc1768_cmsis include_paths: - targets/cmsis/TARGET_NXP/TARGET_LPC176X source_paths: - targets/cmsis/TARGET_NXP/TARGET_LPC176X source_files: - targets/cmsis/TARGET_NXP/TARGET_LPC176X/cmsis_nvic.c tool_specific: gcc_arm: source_paths: - targets/cmsis/TARGET_NXP/TARGET_LPC176X/TOOLCHAIN_GCC_ARM source_files: - targets/cmsis/TARGET_NXP/TARGET_LPC176X/TOOLCHAIN_GCC_ARM/startup_LPC17xx.s linker_file: - targets/cmsis/TARGET_NXP/TARGET_LPC176X/TOOLCHAIN_GCC_ARM/LPC1768.ld### Common attributes
Common attributes are generic, so any file, macro or path defined as common, will be be available for any tool selected.
common: group_name: - my_new_group source_files: - source.c - assembly_file.s macros: - MY_NEW_MACRO
Available common attributes:
- group name - name of the group (virtual dir), used by IDE to group files
- include_paths - include paths
- source_paths - source paths
- source_files - source files
- source_files_obj - object files
- source_files_lib - libraries
- macros - macros
They are used to set tool specific options. As an example, each tool has own the linker command file. If there's a project supported at least 2 tool they need to specify a linker command file for each tool.
tool_specific: source_files: - source.c - assembly_file.s linker_file: - linker.ld macros: - MY_NEW_MACRO misc: optimization: - O3
Available tool_specific attributes:
- linker_file - linker command file
- source_paths - source paths
- include_paths - include paths
- source_files - source files (any of .c, .cpp, .s)
- source_files_obj - object files
- source_files_lib - libraries
- mcu - MCU name as defined in the tool (each tool has different naming)
- macros - tool specific macros
- misc - this is a dictionary of all available options. The content depends on selected toolchain. Look at the specific tool wiki page for available options.
** Project generator wiki, 0xc0170 **