Skip to content

Commit

Permalink
Remove dead entries
Browse files Browse the repository at this point in the history
  • Loading branch information
allsey87 committed Aug 11, 2024
1 parent 019c057 commit de2e134
Showing 1 changed file with 8 additions and 10 deletions.
18 changes: 8 additions & 10 deletions foreign_cc/private/make_env_vars.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -111,17 +111,15 @@ def _get_make_variables(workspace_name, tools, flags, user_env_vars, make_comman

vars = {}
for flag in _MAKE_FLAGS:
toolchain_value = getattr(flags, _MAKE_FLAGS[flag], [])
user_value = user_env_vars.get(flag, "").split()
vars[flag] = toolchain_value + user_value
toolchain_flags = getattr(flags, _MAKE_FLAGS[flag], [])
user_flags = [
user_flag
for user_flag in user_env_vars.get(flag, "").split(" ")
if user_flag
]
if toolchain_flags or user_flags:
vars[flag] = toolchain_flags + user_flags
print('split vars = {}'.format(vars))

vars = {}
for flag in _MAKE_FLAGS:
toolchain_value = getattr(flags, _MAKE_FLAGS[flag], [])
user_value = user_env_vars.get(flag, None)
vars[flag] = toolchain_value + ([user_value] if user_value else [])
print('other vars = {}'.format(vars))

tools_dict = {}
for tool in _MAKE_TOOLS:
Expand Down

0 comments on commit de2e134

Please sign in to comment.