diff options
author | Josh Matthews <josh@joshmatthews.net> | 2019-12-20 11:25:19 -0500 |
---|---|---|
committer | Josh Matthews <josh@joshmatthews.net> | 2019-12-20 11:25:19 -0500 |
commit | e922d5e11deca58be4daf844c1067083dcdcb232 (patch) | |
tree | cfa69fbad475cce2a4bb8d2ca842a6d2f17ef20e /python/servo/command_base.py | |
parent | aa36d5f657eb32b59d994d08b177a02372b4b01c (diff) | |
download | servo-e922d5e11deca58be4daf844c1067083dcdcb232.tar.gz servo-e922d5e11deca58be4daf844c1067083dcdcb232.zip |
Print OSMesa environment variables when starting debugger under WPT.
Diffstat (limited to 'python/servo/command_base.py')
-rw-r--r-- | python/servo/command_base.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/python/servo/command_base.py b/python/servo/command_base.py index 7c82acaa534..371eb9844a2 100644 --- a/python/servo/command_base.py +++ b/python/servo/command_base.py @@ -222,7 +222,7 @@ def append_to_path_env(string, env, name): env[name] = variable -def set_osmesa_env(bin_path, env): +def set_osmesa_env(bin_path, env, show_vars): """Set proper LD_LIBRARY_PATH and DRIVE for software rendering on Linux and OSX""" if is_linux(): dep_path = find_dep_path_newest('osmesa-src', bin_path) @@ -231,6 +231,9 @@ def set_osmesa_env(bin_path, env): osmesa_path = path.join(dep_path, "out", "lib", "gallium") append_to_path_env(osmesa_path, env, "LD_LIBRARY_PATH") env["GALLIUM_DRIVER"] = "softpipe" + if show_vars: + print("GALLIUM_DRIVER=" + env["GALLIUM_DRIVER"]) + print("LD_LIBRARY_PATH=" + env["LD_LIBRARY_PATH"]) elif is_macosx(): osmesa_dep_path = find_dep_path_newest('osmesa-src', bin_path) if not osmesa_dep_path: @@ -241,6 +244,9 @@ def set_osmesa_env(bin_path, env): "out", "src", "mapi", "shared-glapi", ".libs") append_to_path_env(osmesa_path + ":" + glapi_path, env, "DYLD_LIBRARY_PATH") env["GALLIUM_DRIVER"] = "softpipe" + if show_vars: + print("GALLIUM_DRIVER=" + env["GALLIUM_DRIVER"]) + print("DYLD_LIBRARY_PATH=" + env["DYLD_LIBRARY_PATH"]) return env |