Set default sct=before, add ${name} to mkDriver call

This commit is contained in:
Douglas Clowes
2014-11-06 18:16:02 +11:00
parent 6bed30d5d4
commit c488733bcd

View File

@ -1876,7 +1876,7 @@ def put_read_config(MyDriver):
make_args = ' {*}$arg_list'
else:
make_args = ''
txt += [' ${ns}::mkDriver sct_${name} ${device_class} ${simulation_flag} ${ip_address} ${tcp_port}' + make_args]
txt += [' ${ns}::mkDriver sct_${name} ${name} ${device_class} ${simulation_flag} ${ip_address} ${tcp_port}' + make_args]
txt += [' }']
txt += [' }']
txt += [' }']
@ -2074,6 +2074,8 @@ def main():
global args
import argparse
# RELEASE-3_1="before", RELEASE-3_2="after"
default_sct = "before"
parser = argparse.ArgumentParser()
parser.add_argument("-c", "--code", help="dump code",
action="store_true")
@ -2083,8 +2085,9 @@ def main():
action="store_true")
parser.add_argument("-m", "--move", help="generate move commands",
action="store_true")
parser.add_argument("--sct", help="where to put the sct in the filename",
choices=["before", "after"], default="before")
parser.add_argument("--sct",
help="where to put the sct in the filename [%s]" % default_sct,
choices=["before", "after"], default=default_sct)
parser.add_argument("-v", "--verbose", help="verbose output",
action="store_true")
parser.add_argument("driver_source", help="driver source file", nargs="*")