Commit 73aa9fb9 authored by thakis@chromium.org's avatar thakis@chromium.org

package_from_installed: Put env in json file behind "env" key.

Every time I write a json file, I end up wishing I put my toplevel items
into non-toplevel items down the line when I want to add more stuff to the
json file.  Address this now, while no toolchain with this json file has
been built yet.

Follow-up to https://codereview.chromium.org/1706423002/

BUG=495204

Review URL: https://codereview.chromium.org/1718083003

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@298908 0039d316-1c4b-4281-b951-d872f2087c98
parent cd0a1cf3
......@@ -271,10 +271,12 @@ def GenerateSetEnvCmd(target_dir):
var, BatDirs(dirs), ';%PATH%' if var == 'PATH' else ''))
with open(set_env_prefix + '.x86.json', 'wb') as f:
assert not set(env.keys()) & set(env_x86.keys()), 'dupe keys'
json.dump(collections.OrderedDict(env.items() + env_x86.items()), f)
json.dump({'env': collections.OrderedDict(env.items() + env_x86.items())},
f)
with open(set_env_prefix + '.x64.json', 'wb') as f:
assert not set(env.keys()) & set(env_x64.keys()), 'dupe keys'
json.dump(collections.OrderedDict(env.items() + env_x64.items()), f)
json.dump({'env': collections.OrderedDict(env.items() + env_x64.items())},
f)
def AddEnvSetup(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