Merge #276408: gst_all_1.gst-plugins-good: dlopen libsoup_3 with an absolute path

...into staging
This commit is contained in:
Vladimír Čunát 2024-02-29 19:37:34 +01:00
commit bf641bb943
No known key found for this signature in database
GPG Key ID: E747DF1F9575A3AA
3 changed files with 27 additions and 5 deletions

View File

@ -1,9 +1,8 @@
addGstreamer1LibPath () {
if test -d "$1/lib/gstreamer-1.0"
then
export GST_PLUGIN_SYSTEM_PATH_1_0="${GST_PLUGIN_SYSTEM_PATH_1_0-}${GST_PLUGIN_SYSTEM_PATH_1_0:+:}$1/lib/gstreamer-1.0"
addToSearchPath GST_PLUGIN_SYSTEM_PATH_1_0 "$1/lib/gstreamer-1.0"
fi
}
addEnvHooks "$hostOffset" addGstreamer1LibPath

View File

@ -1,6 +1,6 @@
{ lib, stdenv
, fetchurl
, fetchpatch
, substituteAll
, meson
, nasm
, ninja
@ -24,9 +24,10 @@
, gdk-pixbuf
, aalib
, libcaca
, libsoup
, libsoup_3
, libpulseaudio
, libintl
, libxml2
, Cocoa
, lame
, mpg123
@ -63,6 +64,14 @@ stdenv.mkDerivation rec {
hash = "sha256-JpWfz+v/9jfU6gjvQDFrrzG2G7dymCCwaE6ADDoUeLY=";
};
patches = [
# dlopen libsoup_3 with an absolute path
(substituteAll {
src = ./souploader.diff;
nixLibSoup3Path = "${lib.getLib libsoup_3}/lib";
})
];
strictDeps = true;
depsBuildBuild = [ pkg-config ];
@ -102,8 +111,9 @@ stdenv.mkDerivation rec {
gdk-pixbuf
aalib
libcaca
libsoup
libsoup_3
libshout
libxml2
lame
mpg123
twolame

View File

@ -0,0 +1,13 @@
diff --git a/ext/soup/gstsouploader.c b/ext/soup/gstsouploader.c
index 85048ce303..d7d818cf95 100644
--- a/ext/soup/gstsouploader.c
+++ b/ext/soup/gstsouploader.c
@@ -181,7 +181,7 @@ gst_soup_load_library (void)
GST_DEBUG ("LibSoup 2 found");
} else {
GST_DEBUG ("Trying all libsoups");
- libsoup_sonames[0] = LIBSOUP_3_SONAME;
+ libsoup_sonames[0] = "@nixLibSoup3Path@/" LIBSOUP_3_SONAME;
libsoup_sonames[1] = LIBSOUP_2_SONAME;
}