mirror of https://github.com/ARMmbed/mbed-os.git
Target + Exporters - progen data expansion by template for tools
Each target can specify own template. This is however not recommended for general use. Each target should be supported by progendef, and well definied. However, as tools are quickly changing, some targets add extra information which might not be supported, this template expansion allows a target to temporary override default mbed tool template. In this commit, we add RZ_A1H iar template. I experienced with never tools some breakage in the templates, this might come handy, but repeat, please consider using the default template, and contribute to progen or progendef which should contain fixes or support for newer targets/tools.pull/1563/head
parent
6076b3a49b
commit
5f2541c8aa
|
@ -47,10 +47,15 @@ class IAREmbeddedWorkbench(Exporter):
|
||||||
def generate(self):
|
def generate(self):
|
||||||
""" Generates the project files """
|
""" Generates the project files """
|
||||||
project_data = self.progen_get_project_data()
|
project_data = self.progen_get_project_data()
|
||||||
|
tool_specific = {}
|
||||||
# Expand tool specific settings by IAR specific settings which are required
|
# Expand tool specific settings by IAR specific settings which are required
|
||||||
|
try:
|
||||||
|
if TARGET_MAP[self.target].progen['iar']['template']:
|
||||||
|
tool_specific['iar'] = TARGET_MAP[self.target].progen['iar']
|
||||||
|
except KeyError:
|
||||||
|
# use default template
|
||||||
# by the mbed projects
|
# by the mbed projects
|
||||||
tool_specific = {
|
tool_specific['iar'] = {
|
||||||
'iar': {
|
|
||||||
# We currently don't use misc, template sets those for us
|
# We currently don't use misc, template sets those for us
|
||||||
# 'misc': {
|
# 'misc': {
|
||||||
# 'cxx_flags': ['--no_rtti', '--no_exceptions'],
|
# 'cxx_flags': ['--no_rtti', '--no_exceptions'],
|
||||||
|
@ -59,7 +64,7 @@ class IAREmbeddedWorkbench(Exporter):
|
||||||
# },
|
# },
|
||||||
'template': [os.path.join(os.path.dirname(__file__), 'iar_template.ewp.tmpl')],
|
'template': [os.path.join(os.path.dirname(__file__), 'iar_template.ewp.tmpl')],
|
||||||
}
|
}
|
||||||
}
|
|
||||||
project_data['tool_specific'] = {}
|
project_data['tool_specific'] = {}
|
||||||
project_data['tool_specific'].update(tool_specific)
|
project_data['tool_specific'].update(tool_specific)
|
||||||
self.progen_gen_file('iar_arm', project_data)
|
self.progen_gen_file('iar_arm', project_data)
|
||||||
|
|
|
@ -1762,6 +1762,10 @@ class RZ_A1H(Target):
|
||||||
self.default_toolchain = "ARM"
|
self.default_toolchain = "ARM"
|
||||||
self.progen = {
|
self.progen = {
|
||||||
"target": "gr-peach",
|
"target": "gr-peach",
|
||||||
|
"iar": {
|
||||||
|
# rewrite generic template, this device needs futher support for FPU in progendef
|
||||||
|
"template": [os.path.join(os.path.dirname(__file__), 'export', 'iar_rz_a1h.ewp.tmpl')],
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
def program_cycle_s(self):
|
def program_cycle_s(self):
|
||||||
|
|
Loading…
Reference in New Issue