gstreamer: Switch to meson build system

This commit is contained in:
Bastian Köcher
2018-04-04 17:25:39 +02:00
parent 1884beb21e
commit 365640a6f3
2 changed files with 33 additions and 11 deletions
@@ -1,6 +1,7 @@
{ stdenv, fetchurl, pkgconfig, perl, bison, flex, python, gobjectIntrospection
, glib, makeWrapper
, darwin
{ stdenv, fetchurl, fetchpatch, meson, ninja
, pkgconfig, gettext, gobjectIntrospection
, bison, flex, python3, glib, makeWrapper
, libcap,libunwind, darwin
}:
stdenv.mkDerivation rec {
@@ -19,28 +20,34 @@ stdenv.mkDerivation rec {
sha256 = "0vj6k01lp2yva6rfd95fkyng9jdr62gkz0x8d2l81dyly1ki6dpw";
};
patches = [
(fetchpatch {
url = "https://bug794856.bugzilla-attachments.gnome.org/attachment.cgi?id=370411";
sha256 = "16plzzmkk906k4892zq68j3c9z8vdma5nxzlviq20jfv04ykhmk2";
})
./fix_pkgconfig_includedir.patch
];
outputs = [ "out" "dev" ];
outputBin = "dev";
nativeBuildInputs = [
pkgconfig perl bison flex python gobjectIntrospection makeWrapper
meson ninja pkgconfig gettext bison flex python3 makeWrapper gobjectIntrospection
];
buildInputs = stdenv.lib.optional stdenv.isDarwin darwin.apple_sdk.frameworks.CoreServices;
buildInputs = [ libcap libunwind ] ++ stdenv.lib.optional stdenv.isDarwin darwin.apple_sdk.frameworks.CoreServices;
propagatedBuildInputs = [ glib ];
enableParallelBuilding = true;
preConfigure = ''
configureFlagsArray+=("--exec-prefix=$dev")
'';
postInstall = ''
for prog in "$dev/bin/"*; do
wrapProgram "$prog" --suffix GST_PLUGIN_SYSTEM_PATH : "\$(unset _tmp; for profile in \$NIX_PROFILES; do _tmp="\$profile/lib/gstreamer-1.0''$\{_tmp:+:\}\$_tmp"; done; printf "\$_tmp")"
done
'';
preConfigure= ''
patchShebangs .
'';
preFixup = ''
moveToOutput "share/bash-completion" "$dev"
'';