aboutsummaryrefslogtreecommitdiffstats
path: root/python
diff options
context:
space:
mode:
Diffstat (limited to 'python')
-rw-r--r--python/servo/command_base.py6
-rw-r--r--python/servo/platform/base.py3
-rw-r--r--python/servo/platform/linux.py3
-rw-r--r--python/servo/platform/macos.py3
-rw-r--r--python/servo/platform/windows.py3
5 files changed, 6 insertions, 12 deletions
diff --git a/python/servo/command_base.py b/python/servo/command_base.py
index 833f0bac417..b839f4d1dc4 100644
--- a/python/servo/command_base.py
+++ b/python/servo/command_base.py
@@ -488,6 +488,12 @@ class CommandBase(object):
if gstreamer_root:
util.prepend_paths_to_env(env, "PATH", os.path.join(gstreamer_root, "bin"))
+ # FIXME: This is necessary to run unit tests, because they depend on dylibs from the
+ # GStreamer distribution (such as harfbuzz), but we only modify the rpath of the
+ # target binary (servoshell / libsimpleservo).
+ if platform.is_macos:
+ util.prepend_paths_to_env(env, "DYLD_LIBRARY_PATH", os.path.join(gstreamer_root, "lib"))
+
effective_target = self.cross_compile_target or servo.platform.host_triple()
if "msvc" in effective_target:
# Always build harfbuzz from source
diff --git a/python/servo/platform/base.py b/python/servo/platform/base.py
index 7cb1a9b0996..b654a43cd5c 100644
--- a/python/servo/platform/base.py
+++ b/python/servo/platform/base.py
@@ -26,9 +26,6 @@ class Base:
def gstreamer_root(self, _cross_compilation_target: Optional[str]) -> Optional[str]:
raise NotImplementedError("Do not know how to get GStreamer path for platform.")
- def library_path_variable_name(self):
- raise NotImplementedError("Do not know how to set library path for platform.")
-
def executable_suffix(self) -> str:
return ""
diff --git a/python/servo/platform/linux.py b/python/servo/platform/linux.py
index b49e9018358..d6000badcd9 100644
--- a/python/servo/platform/linux.py
+++ b/python/servo/platform/linux.py
@@ -82,9 +82,6 @@ class Linux(Base):
self.is_linux = True
(self.distro, self.version) = Linux.get_distro_and_version()
- def library_path_variable_name(self):
- return "LD_LIBRARY_PATH"
-
@staticmethod
def get_distro_and_version() -> Tuple[str, str]:
distrib = distro.name()
diff --git a/python/servo/platform/macos.py b/python/servo/platform/macos.py
index 73708af6446..eeb2ee26c1c 100644
--- a/python/servo/platform/macos.py
+++ b/python/servo/platform/macos.py
@@ -26,9 +26,6 @@ class MacOS(Base):
super().__init__(*args, **kwargs)
self.is_macos = True
- def library_path_variable_name(self):
- return "DYLD_LIBRARY_PATH"
-
def gstreamer_root(self, cross_compilation_target: Optional[str]) -> Optional[str]:
# We do not support building with gstreamer while cross-compiling on MacOS.
if cross_compilation_target or not os.path.exists(GSTREAMER_ROOT):
diff --git a/python/servo/platform/windows.py b/python/servo/platform/windows.py
index 028f4a167cc..394dc649493 100644
--- a/python/servo/platform/windows.py
+++ b/python/servo/platform/windows.py
@@ -41,9 +41,6 @@ class Windows(Base):
def executable_suffix(self):
return ".exe"
- def library_path_variable_name(self):
- return "LIB"
-
@classmethod
def download_and_extract_dependency(cls, zip_path: str, full_spec: str):
if not os.path.isfile(zip_path):