Improve the support for unknown options definition from outside the Top

parent 64bc3983
......@@ -784,6 +784,8 @@ when ``hdlmake`` is executed:
.. note:: New custom variables are not allowed outside the TOP In this way, despite the fact that all of the Pyhton code in the used files is executed when ``hdlmake`` is launched, not all of the Python constructions can be implemented.
.. note:: In order to allow the insertion of new custom variables in the child Manifests, you can try the ``--allow-unknown`` experimental feature. By specifiying this optional argument to the ``hdlmake`` command line, a warning message is raised when an unknown option or variable is defined in a child, but the variable itself is inserted and processed.
Remote synthesis with Xilinx ISE
......@@ -957,6 +959,8 @@ Automatic execution (``auto``)
This is the default action for hdlmake, the one that is run when a command is not given.
.. note:: The ``auto`` command is just inferred if the issued command is a plain ``hdlmake``. If an optional argument is provided, you need to specify the specific command that is going to be executed.
The basic behaviour will be defined by the value of the ``action`` manifest parameter in the hierachy top ````. This can be set to ``simulation`` or ``synthesis``, and the associated command sequence will be:
......@@ -1173,4 +1177,10 @@
Force hdlmake to generate the makefile, even if the specified tool is missing.
.. warning:: this is an experimental feature!!
Allow the insertion of new options or variables inside the child Manifest. Is this is option is not specified, the only place in which new options or variables can be defined is the top Manifest.
......@@ -277,6 +277,9 @@ def _get_parser():
parser.add_argument("--generate-project-vhd", help="generate project.vhd file with a meta package describing the project",
dest="generate_project_vhd", default=False, action="store_true")
parser.add_argument("--force", help="force hdlmake to generate the makefile, even if the specified tool is missing", default=False, action="store_true")
parser.add_argument("--allow-unknown", dest="allow_unknown",
default=False, help="allow unknown option insertions in the child Manifests", action="store_true")
return parser
......@@ -207,7 +207,10 @@ class Module(object):
allow_unknown = True
extra_context = {}
allow_unknown = False
if global_mod.options.allow_unknown is True:
allow_unknown = True
allow_unknown = False
extra_context = dict(global_mod.top_module.manifest_dict) # copy the dictionary
del extra_context["modules"]
del extra_context["files"]
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