mirror of
https://github.com/servo/servo.git
synced 2025-08-06 06:00:15 +01:00
Auto merge of #23126 - servo:jdm-patch-35, r=Manishearth
Fix various Windows dependency issues - [x] `./mach build -d` does not report any errors - [x] `./mach test-tidy` does not report any errors - [x] These changes fix #23125 and fix #23104 - [x] There are tests for these changes <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/23126) <!-- Reviewable:end -->
This commit is contained in:
commit
e27653ceae
1 changed files with 36 additions and 23 deletions
|
@ -611,7 +611,8 @@ class MachCommands(CommandBase):
|
||||||
gst_root = ""
|
gst_root = ""
|
||||||
gst_default_path = path.join("C:\\gstreamer\\1.0", gst_x64)
|
gst_default_path = path.join("C:\\gstreamer\\1.0", gst_x64)
|
||||||
gst_env = "GSTREAMER_1_0_ROOT_" + gst_x64
|
gst_env = "GSTREAMER_1_0_ROOT_" + gst_x64
|
||||||
if os.path.exists(path.join(gst_default_path, "bin", "libz.dll")):
|
if os.path.exists(path.join(gst_default_path, "bin", "libffi-7.dll")) or \
|
||||||
|
os.path.exists(path.join(gst_default_path, "bin", "ffi-7.dll")):
|
||||||
gst_root = gst_default_path
|
gst_root = gst_default_path
|
||||||
elif os.environ.get(gst_env) is not None:
|
elif os.environ.get(gst_env) is not None:
|
||||||
gst_root = os.environ.get(gst_env)
|
gst_root = os.environ.get(gst_env)
|
||||||
|
@ -619,31 +620,43 @@ class MachCommands(CommandBase):
|
||||||
print("Could not found GStreamer installation directory.")
|
print("Could not found GStreamer installation directory.")
|
||||||
status = 1
|
status = 1
|
||||||
gst_dlls = [
|
gst_dlls = [
|
||||||
"libffi-7.dll",
|
["libffi-7.dll", "ffi-7.dll"],
|
||||||
"libgio-2.0-0.dll",
|
["libgio-2.0-0.dll", "gio-2.0-0.dll"],
|
||||||
"libglib-2.0-0.dll",
|
["libglib-2.0-0.dll", "glib-2.0-0.dll"],
|
||||||
"libgmodule-2.0-0.dll",
|
["libgmodule-2.0-0.dll", "gmodule-2.0-0.dll"],
|
||||||
"libgobject-2.0-0.dll",
|
["libgobject-2.0-0.dll", "gobject-2.0-0.dll"],
|
||||||
"libgstapp-1.0-0.dll",
|
["libgstapp-1.0-0.dll", "gstapp-1.0-0.dll"],
|
||||||
"libgstaudio-1.0-0.dll",
|
["libgstaudio-1.0-0.dll", "gstaudio-1.0-0.dll"],
|
||||||
"libgstbase-1.0-0.dll",
|
["libgstbase-1.0-0.dll", "gstbase-1.0-0.dll"],
|
||||||
"libgstpbutils-1.0-0.dll",
|
["libgstgl-1.0-0.dll", "gstgl-1.0-0.dll"],
|
||||||
"libgstplayer-1.0-0.dll",
|
["libgstpbutils-1.0-0.dll", "gstpbutils-1.0-0.dll"],
|
||||||
"libgstreamer-1.0-0.dll",
|
["libgstplayer-1.0-0.dll", "gstplayer-1.0-0.dll"],
|
||||||
"libgstrtp-1.0-0.dll",
|
["libgstreamer-1.0-0.dll", "gstreamer-1.0-0.dll"],
|
||||||
"libgstsdp-1.0-0.dll",
|
["libgstrtp-1.0-0.dll", "gstrtp-1.0-0.dll"],
|
||||||
"libgsttag-1.0-0.dll",
|
["libgstsdp-1.0-0.dll", "gstsdp-1.0-0.dll"],
|
||||||
"libgstvideo-1.0-0.dll",
|
["libgsttag-1.0-0.dll", "gsttag-1.0-0.dll"],
|
||||||
"libgstwebrtc-1.0-0.dll",
|
["libgstvideo-1.0-0.dll", "gstvideo-1.0-0.dll"],
|
||||||
"libintl-8.dll",
|
["libgstwebrtc-1.0-0.dll", "gstwebrtc-1.0-0.dll"],
|
||||||
"liborc-0.4-0.dll",
|
["libintl-8.dll", "intl-8.dll"],
|
||||||
"libwinpthread-1.dll",
|
["liborc-0.4-0.dll", "orc-0.4-0.dll"],
|
||||||
"libz.dll"
|
["libwinpthread-1.dll", "winpthread-1.dll"],
|
||||||
|
["libz.dll", "libz-1.dll", "z-1.dll"]
|
||||||
]
|
]
|
||||||
if gst_root:
|
if gst_root:
|
||||||
for gst_lib in gst_dlls:
|
for gst_lib in gst_dlls:
|
||||||
shutil.copy(path.join(gst_root, "bin", gst_lib),
|
if isinstance(gst_lib, str):
|
||||||
servo_exe_dir)
|
gst_lib = [gst_lib]
|
||||||
|
for lib in gst_lib:
|
||||||
|
try:
|
||||||
|
shutil.copy(path.join(gst_root, "bin", lib),
|
||||||
|
servo_exe_dir)
|
||||||
|
break
|
||||||
|
except:
|
||||||
|
pass
|
||||||
|
else:
|
||||||
|
print("ERROR: could not find required GStreamer DLL: " + str(gst_lib))
|
||||||
|
sys.exit(1)
|
||||||
|
|
||||||
# copy some MSVC DLLs to servo.exe dir
|
# copy some MSVC DLLs to servo.exe dir
|
||||||
msvc_redist_dir = None
|
msvc_redist_dir = None
|
||||||
vs_platform = os.environ.get("PLATFORM", "").lower()
|
vs_platform = os.environ.get("PLATFORM", "").lower()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue