mirror of
https://git.rtems.org/rtems-libbsd/
synced 2025-07-23 05:15:32 +08:00
Fix the sed generator for processing INI configuration files.
This commit is contained in:
parent
3f2b54d971
commit
8a7d33cd30
@ -227,6 +227,7 @@ class Builder(builder.ModuleManager):
|
||||
except:
|
||||
bld.fatal('network configuraiton \'%s\' read failed' % (bld.env.NET_CONFIG))
|
||||
lc = 0
|
||||
sed = 'sed '
|
||||
for l in net_cfg_lines:
|
||||
lc += 1
|
||||
if l.strip().startswith('NET_CFG_'):
|
||||
@ -236,10 +237,9 @@ class Builder(builder.ModuleManager):
|
||||
'parse error: %d: %s' % (bld.env.NET_CONFIG, lc, l))
|
||||
lhs = ls[0].strip()
|
||||
rhs = ls[1].strip()
|
||||
sed = 'sed '
|
||||
for t in tags:
|
||||
if lhs == t:
|
||||
sed += "-e 's/@%s@/%s/'" % (t, rhs)
|
||||
sed += "-e 's/@%s@/%s/' " % (t, rhs)
|
||||
bld(target = "testsuite/include/rtems/bsd/test/network-config.h",
|
||||
source = "testsuite/include/rtems/bsd/test/network-config.h.in",
|
||||
rule = sed + " < ${SRC} > ${TGT}",
|
||||
|
Loading…
x
Reference in New Issue
Block a user