From 2b9e883591c3753fa73dac02938fccfdbf78edfe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Tue, 11 Nov 2008 17:05:07 +0000 Subject: [PATCH] GStreamer: Add a setup hook to define `GST_PLUGIN_PATH'. svn path=/nixpkgs/trunk/; revision=13253 --- .../development/libraries/gstreamer/gstreamer/0.10.17.nix | 2 ++ .../libraries/gstreamer/gstreamer/setup-hook.sh | 8 ++++++++ 2 files changed, 10 insertions(+) create mode 100644 pkgs/development/libraries/gstreamer/gstreamer/setup-hook.sh diff --git a/pkgs/development/libraries/gstreamer/gstreamer/0.10.17.nix b/pkgs/development/libraries/gstreamer/gstreamer/0.10.17.nix index 3508145c22c..02244e77371 100644 --- a/pkgs/development/libraries/gstreamer/gstreamer/0.10.17.nix +++ b/pkgs/development/libraries/gstreamer/gstreamer/0.10.17.nix @@ -14,6 +14,8 @@ stdenv.mkDerivation rec { configureFlags = "--enable-shared --disable-static --enable-failing-tests --localstatedir=/var"; + setupHook = ./setup-hook.sh; + meta = { homepage = http://gstreamer.freedesktop.org; }; diff --git a/pkgs/development/libraries/gstreamer/gstreamer/setup-hook.sh b/pkgs/development/libraries/gstreamer/gstreamer/setup-hook.sh new file mode 100644 index 00000000000..ad184dc21e9 --- /dev/null +++ b/pkgs/development/libraries/gstreamer/gstreamer/setup-hook.sh @@ -0,0 +1,8 @@ +addGstreamerLibPath () { + if test -d "$1/lib/gstreamer-0.10" + then + export GST_PLUGIN_PATH="${GST_PLUGIN_PATH}${GST_PLUGIN_PATH:+:}$1/lib/gstreamer-0.10" + fi +} + +envHooks=(${envHooks[@]} addGstreamerLibPath)