diff options
Diffstat (limited to 'python/servo')
-rw-r--r-- | python/servo/build_commands.py | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/python/servo/build_commands.py b/python/servo/build_commands.py index 0d0dbc0ebcd..ec20f18af5a 100644 --- a/python/servo/build_commands.py +++ b/python/servo/build_commands.py @@ -24,7 +24,7 @@ from mach.decorators import ( Command, ) -from servo.command_base import CommandBase, cd, call, check_call, BIN_SUFFIX +from servo.command_base import CommandBase, cd, call, check_call, BIN_SUFFIX, is_macosx from servo.util import host_triple @@ -401,8 +401,14 @@ class MachCommands(CommandBase): if with_debug_assertions: env["RUSTFLAGS"] = "-C debug_assertions" + if is_macosx(): + # Unlike RUSTFLAGS, these are only passed in the final rustc invocation + # so that `./mach build` followed by `./mach build-cef` both build + # common dependencies with the same flags. + opts += ["--", "-C", "link-args=-Xlinker -undefined -Xlinker dynamic_lookup"] + with cd(path.join("ports", "cef")): - ret = call(["cargo", "build"] + opts, + ret = call(["cargo", "rustc"] + opts, env=env, verbose=verbose) elapsed = time() - build_start |