Improve action checking before writing the Makefile

parent caa17392
......@@ -59,11 +59,14 @@ def _load_sim_tool(modules_pool):
def write_makefile(modules_pool):
"""Function that detects the appropriated tool and write the Makefile"""
manifest_project_dict = modules_pool.get_config_dict()
action = manifest_project_dict['action']
action = manifest_project_dict.get('action')
if action == "simulation":
sim_writer = _load_sim_tool(modules_pool)
sim_writer.simulation_makefile(modules_pool)
elif action == "synthesis":
syn_writer = _load_syn_tool(modules_pool)
syn_writer.synthesis_makefile(modules_pool)
else:
logging.error("Unknown requested action: %s", action)
quit()
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