Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Sw4STM32 Class Reference
Inherits tools::export::gnuarmeclipse::GNUARMEclipse.
Public Member Functions | |
def | get_fpu_hardware |
def | process_sw_options |
def | generate |
def | flags |
def | toolchain_flags |
def | build |
def | compute_exclusions |
def | filter_dot |
def | process_options |
def | get_toolchain |
def | add_config |
def | get_source_paths |
def | gen_file |
def | make_key |
def | group_project_files |
Detailed Description
Sw4STM32 class
Definition at line 29 of file export/sw4stm32/__init__.py.
Member Function Documentation
def add_config | ( | self ) | [inherited] |
Add the containgin directory of mbed_config.h to include dirs
Definition at line 87 of file exporters.py.
def build | ( | project_name, | |
log_name = "build_log.txt" , |
|||
cleanup = True |
|||
) | [inherited] |
Headless build an Eclipse project. The following steps are performed: - a temporary workspace is created, - the project is imported, - a clean build of all configurations is performed and - the temporary workspace is removed. The build results are in the Debug & Release folders. All executables (eclipse & toolchain) must be in the PATH. The general method to start a headless Eclipse build is: $ eclipse \ --launcher.suppressErrors \ -nosplash \ -application org.eclipse.cdt.managedbuilder.core.headlessbuild \ -data /path/to/workspace \ -import /path/to/project \ -cleanBuild "project[/configuration] | all"
Definition at line 301 of file export/gnuarmeclipse/__init__.py.
def compute_exclusions | ( | self ) | [inherited] |
With the project root as the only source folder known to CDT, based on the list of source files, compute the folders to not be included in the build. The steps are: - get the list of source folders, as dirname(source_file) - compute the top folders (subfolders of the project folder) - iterate all subfolders and add them to a tree, with all nodes markes as 'not used' - iterate the source folders and mark them as 'used' in the tree, including all intermediate nodes - recurse the tree and collect all unused folders; descend the hierarchy only for used nodes
Definition at line 412 of file export/gnuarmeclipse/__init__.py.
def filter_dot | ( | str ) | [inherited] |
Remove the './' prefix, if present. This function assumes that resources.win_to_unix() replaced all windows backslashes with slashes.
Definition at line 438 of file export/gnuarmeclipse/__init__.py.
def flags | ( | self ) | [inherited] |
Returns a dictionary of toolchain flags. Keys of the dictionary are: cxx_flags - c++ flags c_flags - c flags ld_flags - linker flags asm_flags - assembler flags common_flags - common options The difference from the parent function is that it does not add macro definitions, since they are passed separately.
Definition at line 80 of file export/gnuarmeclipse/__init__.py.
def gen_file | ( | self, | |
template_file, | |||
data, | |||
target_file, | |||
kwargs | |||
) | [inherited] |
Generates a project file from a template using jinja
Definition at line 133 of file exporters.py.
def generate | ( | self ) |
Generate the .project and .cproject files.
Reimplemented from Exporter.
Definition at line 390 of file export/sw4stm32/__init__.py.
def get_fpu_hardware | ( | self, | |
fpu_unit | |||
) |
Convert fpu unit name into hardware name.
Definition at line 278 of file export/sw4stm32/__init__.py.
def get_source_paths | ( | self ) | [inherited] |
Returns a list of the directories where source files are contained
Definition at line 124 of file exporters.py.
def get_toolchain | ( | self ) | [inherited] |
A helper getter function that we should probably eliminate
Definition at line 83 of file exporters.py.
def group_project_files | ( | self, | |
sources | |||
) | [inherited] |
Group the source files by their encompassing directory Positional Arguments: sources - array of source locations Returns a dictionary of {group name: list of source locations}
Definition at line 162 of file exporters.py.
def make_key | ( | self, | |
src | |||
) | [inherited] |
From a source file, extract group name Positional Arguments: src - the src's location
Definition at line 148 of file exporters.py.
def process_options | ( | self, | |
opts, | |||
flags_in | |||
) | [inherited] |
CDT managed projects store lots of build options in separate variables, with separate IDs in the .cproject file. When the CDT build is started, all these options are brought together to compose the compiler and linker command lines. Here the process is reversed, from the compiler and linker command lines, the options are identified and various flags are set to control the template generation process. Once identified, the options are removed from the command lines. The options that were not identified are options that do not have CDT equivalents and will be passed in the 'Other options' categories. Although this process does not have a very complicated logic, given the large number of explicit configuration options used by the GNU ARM Eclipse managed build plug-in, it is tedious...
Definition at line 476 of file export/gnuarmeclipse/__init__.py.
def process_sw_options | ( | self, | |
opts, | |||
flags_in | |||
) |
Process System Workbench specific options. System Workbench for STM32 has some compile options, which are not recognized by the GNUARMEclipse exporter. Those are handled in this method.
Definition at line 292 of file export/sw4stm32/__init__.py.
def toolchain_flags | ( | self, | |
toolchain | |||
) | [inherited] |
Returns a dictionary of toolchain flags. Keys of the dictionary are: cxx_flags - c++ flags c_flags - c flags ld_flags - linker flags asm_flags - assembler flags common_flags - common options The difference from the above is that it takes a parameter.
Definition at line 104 of file export/gnuarmeclipse/__init__.py.
Generated on Thu Jul 14 2022 14:36:33 by
