[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Autoscons-devel] fail to set target in get_target()
From: |
Zhang Le |
Subject: |
[Autoscons-devel] fail to set target in get_target() |
Date: |
Fri, 3 Oct 2003 20:45:22 +0800 |
User-agent: |
Mutt/1.4i |
I found AutoBuild.get_target(env) fail to set env['TARGET'] (after
adding a print statement):
KeyError: 'TARGET':
File "SConstruct", line 111:
baseEnv= BuildBaseEnvironment()
File "SConstruct", line 78:
Autoscons.AutoBuild.get_target(env)
File "/home/zl/prj/pymaxent/Autoscons/AutoBuild.py", line 249:
print env['TARGET']
File "/usr/local/lib/scons/SCons/Environment.py", line 405:
return self._dict[key]
I have a look at Environment.py and find TARGET is a reserved variable:
def __setitem__(self, key, value):
if key in ['TARGET', 'TARGETS', 'SOURCE', 'SOURCES']:
SCons.Warnings.warn(SCons.Warnings.ReservedVariableWarning,
"Ignoring attempt to set reserved variable
`%s'" % key)
I think this is a little bug.
Now I use env['HOST'] = get_target(env) as a workaround.
--
Sincerely yours,
Zhang Le
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Autoscons-devel] fail to set target in get_target(),
Zhang Le <=