diff --git a/pkgs/by-name/or/orc/package.nix b/pkgs/by-name/or/orc/package.nix index 7cc98b93f7ee8..d88ff17b03125 100644 --- a/pkgs/by-name/or/orc/package.nix +++ b/pkgs/by-name/or/orc/package.nix @@ -5,7 +5,7 @@ meson, ninja, file, - docbook_xsl, + docbook-xsl-nons, gtk-doc ? null, buildDevDoc ? gtk-doc != null, @@ -14,18 +14,21 @@ gst_all_1, qt6, vips, - }: -let - inherit (lib) optional optionals; -in -stdenv.mkDerivation rec { + +stdenv.mkDerivation (finalAttrs: { pname = "orc"; - version = "0.4.40"; + version = "0.4.41"; + + outputs = [ + "out" + "dev" + ] ++ lib.optional buildDevDoc "devdoc"; + outputBin = "dev"; # compilation tools src = fetchurl { - url = "https://gstreamer.freedesktop.org/src/orc/${pname}-${version}.tar.xz"; - hash = "sha256-P8K+5437fEH9lgUGH8aRONt98Afq4vZpofVui6zvdKs="; + url = "https://gstreamer.freedesktop.org/src/orc/orc-${finalAttrs.version}.tar.xz"; + hash = "sha256-yxv9T2VSic05vARkLVl76d5UJ2I/CGHB/BnAjZhGf6I="; }; postPatch = lib.optionalString (stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isx86_64) '' @@ -33,23 +36,19 @@ stdenv.mkDerivation rec { sed -i '/memcpy_speed/d' testsuite/meson.build ''; - outputs = [ - "out" - "dev" - ] ++ optional buildDevDoc "devdoc"; - outputBin = "dev"; # compilation tools - - mesonFlags = optionals (!buildDevDoc) [ "-Dgtk_doc=disabled" ]; + mesonFlags = [ + (lib.mesonEnable "gtk_doc" buildDevDoc) + ]; nativeBuildInputs = [ meson ninja ] - ++ optionals buildDevDoc [ + ++ lib.optionals buildDevDoc [ gtk-doc file - docbook_xsl + docbook-xsl-nons ]; # https://gitlab.freedesktop.org/gstreamer/orc/-/issues/41 @@ -70,7 +69,7 @@ stdenv.mkDerivation rec { meta = with lib; { description = "Oil Runtime Compiler"; homepage = "https://gstreamer.freedesktop.org/projects/orc.html"; - changelog = "https://cgit.freedesktop.org/gstreamer/orc/plain/RELEASE?h=${version}"; + changelog = "https://gitlab.freedesktop.org/gstreamer/orc/-/blob/${finalAttrs.version}/RELEASE"; # The source code implementing the Marsenne Twister algorithm is licensed # under the 3-clause BSD license. The rest is 2-clause BSD license. license = with licenses; [ @@ -80,4 +79,4 @@ stdenv.mkDerivation rec { platforms = platforms.unix; maintainers = [ ]; }; -} +}) diff --git a/pkgs/development/libraries/gstreamer/bad/default.nix b/pkgs/development/libraries/gstreamer/bad/default.nix index d573d2325fbae..ec47450ab860a 100644 --- a/pkgs/development/libraries/gstreamer/bad/default.nix +++ b/pkgs/development/libraries/gstreamer/bad/default.nix @@ -19,6 +19,7 @@ , opencvSupport ? false , opencv4 , faad2 +, lcevcdec , ldacbt , liblc3 , libass @@ -105,6 +106,7 @@ , CoreVideo , Foundation , MediaToolbox +, directoryListingUpdater , enableGplPlugins ? true , bluezSupport ? stdenv.hostPlatform.isLinux # Causes every application using GstDeviceMonitor to send mDNS queries every 2 seconds @@ -114,15 +116,18 @@ , guiSupport ? true }: -stdenv.mkDerivation rec { +stdenv.mkDerivation (finalAttrs: { pname = "gst-plugins-bad"; - version = "1.24.10"; + version = "1.26.0"; - outputs = [ "out" "dev" ]; + outputs = [ + "out" + "dev" + ]; src = fetchurl { - url = "https://gstreamer.freedesktop.org/src/${pname}/${pname}-${version}.tar.xz"; - hash = "sha256-FwfjEDlQybrtNkqK8roEldaxE/zTbhBi3aX1grj4kE0="; + url = "https://gstreamer.freedesktop.org/src/gst-plugins-bad/gst-plugins-bad-${finalAttrs.version}.tar.xz"; + hash = "sha256-+Ch6hMX2Y2ilpQ2l+WmZSgLEfyAiD/4coxVBk+Za8hY="; }; patches = [ @@ -130,11 +135,13 @@ stdenv.mkDerivation rec { (replaceVars ./fix-paths.patch { inherit (addDriverRunpath) driverLink; }) - # Add support for newer AJA SDK from next GStreamer release + + # Fix Requires in gstreamer-analytics-1.0.pc + # https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8661 (fetchpatch { - url = "https://github.com/GStreamer/gstreamer/commit/d68ac0db571f44cae42b57c876436b3b09df616b.patch"; - hash = "sha256-ZXwlHzuPT8kUKt5+HkqFH5tzL9l5NusDXImabj4fBbI="; - relative = "subprojects/${pname}"; + url = "https://gitlab.freedesktop.org/gstreamer/gstreamer/-/commit/bc93bbf5c87ec994ea136bb40accc09dfa35ae98.patch"; + stripLen = 2; + hash = "sha256-QQDpHe363iPxTuthITRbLUKaAXS2F9s5zfCn/ps14WE="; }) ]; @@ -172,6 +179,7 @@ stdenv.mkDerivation rec { curl.dev fdk_aac gsm + lcevcdec libaom libdc1394 libde265 @@ -269,16 +277,19 @@ stdenv.mkDerivation rec { mesonFlags = [ "-Dexamples=disabled" # requires many dependencies and probably not useful for our users - "-Dglib-asserts=disabled" # asserts should be disabled on stable releases + "-Dglib_debug=disabled" # cast checks should be disabled on stable releases "-Damfcodec=disabled" # Windows-only + "-Dandroidmedia=disabled" # Requires Android system. "-Davtp=disabled" + "-Dcuda-nvmm=disabled" "-Ddirectshow=disabled" # Windows-only "-Dqt6d3d11=disabled" # Windows-only "-Ddts=disabled" # required `libdca` library not packaged in nixpkgs as of writing, and marked as "BIG FAT WARNING: libdca is still in early development" "-Dzbar=${if enableZbar then "enabled" else "disabled"}" "-Dfaac=${if faacSupport then "enabled" else "disabled"}" "-Diqa=disabled" # required `dssim` library not packaging in nixpkgs as of writing, also this is AGPL so update license when adding support + "-Dlcevcencoder=disabled" # not packaged in nixpkgs as of writing "-Dmagicleap=disabled" # required `ml_audio` library not packaged in nixpkgs as of writing "-Dmsdk=disabled" # not packaged in nixpkgs as of writing / no Windows support # As of writing, with `libmpcdec` in `buildInputs` we get @@ -292,9 +303,12 @@ stdenv.mkDerivation rec { # is needed, and then patching upstream to find it (though it probably # already works on Arch?). "-Dmusepack=disabled" + "-Dnvcomp=disabled" + "-Dnvdswrapper=disabled" "-Dopenni2=disabled" # not packaged in nixpkgs as of writing "-Dopensles=disabled" # not packaged in nixpkgs as of writing "-Dsvthevcenc=disabled" # required `SvtHevcEnc` library not packaged in nixpkgs as of writing + "-Dsvtjpegxs=disabled" # not packaged in nixpkgs as of writing "-Dteletext=disabled" # required `zvbi` library not packaged in nixpkgs as of writing "-Dtinyalsa=disabled" # not packaged in nixpkgs as of writing "-Dvoamrwbenc=disabled" # required `vo-amrwbenc` library not packaged in nixpkgs as of writing @@ -369,6 +383,10 @@ stdenv.mkDerivation rec { doCheck = false; # fails 20 out of 58 tests, expensive + passthru = { + updateScript = directoryListingUpdater { }; + }; + meta = with lib; { description = "GStreamer Bad Plugins"; mainProgram = "gst-transcoder-1.0"; @@ -383,4 +401,4 @@ stdenv.mkDerivation rec { platforms = platforms.linux ++ platforms.darwin; maintainers = with maintainers; [ matthewbauer ]; }; -} +}) diff --git a/pkgs/development/libraries/gstreamer/base/default.nix b/pkgs/development/libraries/gstreamer/base/default.nix index 8bd7a4be51dec..7deee2e29ee8f 100644 --- a/pkgs/development/libraries/gstreamer/base/default.nix +++ b/pkgs/development/libraries/gstreamer/base/default.nix @@ -44,21 +44,23 @@ # Checks meson.is_cross_build(), so even canExecute isn't enough. , enableDocumentation ? stdenv.hostPlatform == stdenv.buildPlatform , hotdoc +, directoryListingUpdater }: stdenv.mkDerivation (finalAttrs: { pname = "gst-plugins-base"; - version = "1.24.10"; + version = "1.26.0"; - outputs = [ "out" "dev" ]; + outputs = [ + "out" + "dev" + ]; separateDebugInfo = true; - src = let - inherit (finalAttrs) pname version; - in fetchurl { - url = "https://gstreamer.freedesktop.org/src/${pname}/${pname}-${version}.tar.xz"; - hash = "sha256-69V7G+kkxuJPMn3VW6udj7quvl4dyPynhBgqsrEtI+s="; + src = fetchurl { + url = "https://gstreamer.freedesktop.org/src/gst-plugins-base/gst-plugins-base-${finalAttrs.version}.tar.xz"; + hash = "sha256-4jGJ++0uxIZpA4LRBVwZ7q9arj6V4ldvxMiE2WqQ5p4="; }; strictDeps = true; @@ -117,6 +119,7 @@ stdenv.mkDerivation (finalAttrs: { ]; mesonFlags = [ + "-Dglib_debug=disabled" # cast checks should be disabled on stable releases "-Dexamples=disabled" # requires many dependencies and probably not useful for our users # See https://github.com/GStreamer/gst-plugins-base/blob/d64a4b7a69c3462851ff4dcfa97cc6f94cd64aef/meson_options.txt#L15 for a list of choices "-Dgl_winsys=${lib.concatStringsSep "," (lib.optional enableX11 "x11" ++ lib.optional enableWayland "wayland" ++ lib.optional enableCocoa "cocoa")}" @@ -160,6 +163,8 @@ stdenv.mkDerivation (finalAttrs: { # vs what was built) and to make them easier to search for. glEnabled = enableGl; waylandEnabled = enableWayland; + + updateScript = directoryListingUpdater { }; }; passthru.tests.pkg-config = testers.testMetaPkgConfig finalAttrs.finalPackage; diff --git a/pkgs/development/libraries/gstreamer/core/default.nix b/pkgs/development/libraries/gstreamer/core/default.nix index 7cedd95ad451d..d5a84e2ccbb87 100644 --- a/pkgs/development/libraries/gstreamer/core/default.nix +++ b/pkgs/development/libraries/gstreamer/core/default.nix @@ -1,35 +1,40 @@ -{ stdenv -, fetchurl -, meson -, ninja -, pkg-config -, gettext -, bison -, flex -, python3 -, glib -, makeWrapper -, libcap -, elfutils # for libdw -, bash-completion -, lib -, Cocoa -, CoreServices -, xpc -, testers -, rustc -, withRust ? - lib.any (lib.meta.platformMatch stdenv.hostPlatform) rustc.targetPlatforms && - lib.all (p: !lib.meta.platformMatch stdenv.hostPlatform p) rustc.badTargetPlatforms -, gobject-introspection -, buildPackages -, withIntrospection ? lib.meta.availableOn stdenv.hostPlatform gobject-introspection && stdenv.hostPlatform.emulatorAvailable buildPackages -, libunwind -, withLibunwind ? - lib.meta.availableOn stdenv.hostPlatform libunwind && - lib.elem "libunwind" libunwind.meta.pkgConfigModules or [] -# Checks meson.is_cross_build(), so even canExecute isn't enough. -, enableDocumentation ? stdenv.hostPlatform == stdenv.buildPlatform, hotdoc +{ + stdenv, + fetchurl, + meson, + ninja, + pkg-config, + gettext, + bison, + flex, + python3, + glib, + makeWrapper, + libcap, + elfutils, # for libdw + bash-completion, + lib, + Cocoa, + CoreServices, + xpc, + testers, + rustc, + withRust ? + lib.any (lib.meta.platformMatch stdenv.hostPlatform) rustc.targetPlatforms + && lib.all (p: !lib.meta.platformMatch stdenv.hostPlatform p) rustc.badTargetPlatforms, + gobject-introspection, + buildPackages, + withIntrospection ? + lib.meta.availableOn stdenv.hostPlatform gobject-introspection + && stdenv.hostPlatform.emulatorAvailable buildPackages, + libunwind, + withLibunwind ? + lib.meta.availableOn stdenv.hostPlatform libunwind + && lib.elem "libunwind" libunwind.meta.pkgConfigModules or [ ], + # Checks meson.is_cross_build(), so even canExecute isn't enough. + enableDocumentation ? stdenv.hostPlatform == stdenv.buildPlatform, + hotdoc, + directoryListingUpdater, }: let @@ -37,7 +42,7 @@ let in stdenv.mkDerivation (finalAttrs: { pname = "gstreamer"; - version = "1.24.10"; + version = "1.26.0"; outputs = [ "bin" @@ -47,11 +52,9 @@ stdenv.mkDerivation (finalAttrs: { separateDebugInfo = true; - src = let - inherit (finalAttrs) pname version; - in fetchurl { - url = "https://gstreamer.freedesktop.org/src/${pname}/${pname}-${version}.tar.xz"; - hash = "sha256-n8RbGjMuj4EvCelcKBzXWWn20WgtBiqBXbDnvAR1GP0="; + src = fetchurl { + url = "https://gstreamer.freedesktop.org/src/gstreamer/gstreamer-${finalAttrs.version}.tar.xz"; + hash = "sha256-Gy7kAoAQwlt3bv+nw5bH4+GGG2C5QX5Bb0kUq83/J58="; }; depsBuildBuild = [ @@ -99,6 +102,7 @@ stdenv.mkDerivation (finalAttrs: { ]; mesonFlags = [ + "-Dglib_debug=disabled" # cast checks should be disabled on stable releases "-Ddbghelp=disabled" # not needed as we already provide libunwind and libdw, and dbghelp is a fallback to those "-Dexamples=disabled" # requires many dependencies and probably not useful for our users (lib.mesonEnable "ptp-helper" withRust) @@ -131,7 +135,12 @@ stdenv.mkDerivation (finalAttrs: { setupHook = ./setup-hook.sh; - passthru.tests.pkg-config = testers.testMetaPkgConfig finalAttrs.finalPackage; + passthru = { + tests = { + pkg-config = testers.testMetaPkgConfig finalAttrs.finalPackage; + }; + updateScript = directoryListingUpdater { }; + }; meta = with lib; { description = "Open source multimedia framework"; diff --git a/pkgs/development/libraries/gstreamer/devtools/default.nix b/pkgs/development/libraries/gstreamer/devtools/default.nix index a48ae45e77f47..73a08e9a60c71 100644 --- a/pkgs/development/libraries/gstreamer/devtools/default.nix +++ b/pkgs/development/libraries/gstreamer/devtools/default.nix @@ -1,34 +1,60 @@ -{ lib, stdenv -, fetchurl -, cairo -, meson -, ninja -, pkg-config -, gstreamer -, gst-plugins-base -, gst-plugins-bad -, gst-rtsp-server -, python3 -, gobject-introspection -, json-glib -# Checks meson.is_cross_build(), so even canExecute isn't enough. -, enableDocumentation ? stdenv.hostPlatform == stdenv.buildPlatform, hotdoc +{ + lib, + stdenv, + fetchurl, + fetchpatch, + cairo, + meson, + ninja, + pkg-config, + gstreamer, + gst-plugins-base, + gst-plugins-bad, + gst-rtsp-server, + python3, + gobject-introspection, + rustPlatform, + rustc, + cargo, + json-glib, + # Checks meson.is_cross_build(), so even canExecute isn't enough. + enableDocumentation ? stdenv.hostPlatform == stdenv.buildPlatform, + hotdoc, + directoryListingUpdater, + _experimental-update-script-combinators, + common-updater-scripts, }: -stdenv.mkDerivation rec { +stdenv.mkDerivation (finalAttrs: { pname = "gst-devtools"; - version = "1.24.10"; - - src = fetchurl { - url = "https://gstreamer.freedesktop.org/src/${pname}/${pname}-${version}.tar.xz"; - hash = "sha256-KYNTcUiwqNUrrSo/TJ3MqAj9WqEvzO4lrMSkJ38HgOw="; - }; + version = "1.26.0"; outputs = [ "out" "dev" ]; + src = fetchurl { + url = "https://gstreamer.freedesktop.org/src/gst-devtools/gst-devtools-${finalAttrs.version}.tar.xz"; + hash = "sha256-7/M9fcKSuwdKJ4jqiHtigzmP/e+vpJ+30I7+ZlimVkg="; + }; + + cargoDeps = rustPlatform.fetchCargoVendor { + inherit (finalAttrs) src cargoRoot; + name = "gst-devtools-${finalAttrs.version}"; + hash = "sha256-p26jeKRDSPTgQzf4ckhLPSFa8RKsgkjUEXJG8IlPPZo="; + }; + + patches = [ + # Fix Requires in gstreamer-validate-1.0.pc + # https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8661 + (fetchpatch { + url = "https://gitlab.freedesktop.org/gstreamer/gstreamer/-/commit/13c0f44dd546cd058c39f32101a361b3a7746f73.patch"; + stripLen = 2; + hash = "sha256-CpBFTmdn+VO6ZeNe6NZR6ELvakZqQdaF3o3G5TSDuUU="; + }) + ]; + depsBuildBuild = [ pkg-config ]; @@ -38,6 +64,9 @@ stdenv.mkDerivation rec { ninja pkg-config gobject-introspection + rustPlatform.cargoSetupHook + rustc + cargo ] ++ lib.optionals enableDocumentation [ hotdoc ]; @@ -59,6 +88,36 @@ stdenv.mkDerivation rec { (lib.mesonEnable "doc" enableDocumentation) ]; + cargoRoot = "dots-viewer"; + + passthru = { + updateScript = + let + updateSource = directoryListingUpdater { }; + + updateLockfile = { + command = [ + "sh" + "-c" + '' + PATH=${ + lib.makeBinPath [ + common-updater-scripts + ] + } + update-source-version gst_all_1.gst-devtools --ignore-same-version --source-key=cargoDeps.vendorStaging > /dev/null + '' + ]; + # Experimental feature: do not copy! + supportedFeatures = [ "silent" ]; + }; + in + _experimental-update-script-combinators.sequence [ + updateSource + updateLockfile + ]; + }; + meta = with lib; { description = "Integration testing infrastructure for the GStreamer framework"; homepage = "https://gstreamer.freedesktop.org"; @@ -66,4 +125,4 @@ stdenv.mkDerivation rec { platforms = platforms.unix; maintainers = [ ]; }; -} +}) diff --git a/pkgs/development/libraries/gstreamer/ges/default.nix b/pkgs/development/libraries/gstreamer/ges/default.nix index d0591ba26dd48..b163f017b7240 100644 --- a/pkgs/development/libraries/gstreamer/ges/default.nix +++ b/pkgs/development/libraries/gstreamer/ges/default.nix @@ -1,24 +1,28 @@ -{ lib, stdenv -, fetchurl -, meson -, ninja -, pkg-config -, python3 -, bash-completion -, gst-plugins-base -, gst-plugins-bad -, gst-devtools -, libxml2 -, flex -, gettext -, gobject-introspection -# Checks meson.is_cross_build(), so even canExecute isn't enough. -, enableDocumentation ? stdenv.hostPlatform == stdenv.buildPlatform, hotdoc +{ + lib, + stdenv, + fetchurl, + meson, + ninja, + pkg-config, + python3, + bash-completion, + gst-plugins-base, + gst-plugins-bad, + gst-devtools, + libxml2, + flex, + gettext, + gobject-introspection, + # Checks meson.is_cross_build(), so even canExecute isn't enough. + enableDocumentation ? stdenv.hostPlatform == stdenv.buildPlatform, + hotdoc, + directoryListingUpdater, }: -stdenv.mkDerivation rec { +stdenv.mkDerivation (finalAttrs: { pname = "gst-editing-services"; - version = "1.24.10"; + version = "1.26.0"; outputs = [ "out" @@ -26,8 +30,8 @@ stdenv.mkDerivation rec { ]; src = fetchurl { - url = "https://gstreamer.freedesktop.org/src/${pname}/${pname}-${version}.tar.xz"; - hash = "sha256-bwCxG05eNMKjLWTfUh3Kd1GdYm/MXjhjwCGL0SNn4XQ="; + url = "https://gstreamer.freedesktop.org/src/gst-editing-services/gst-editing-services-${finalAttrs.version}.tar.xz"; + hash = "sha256-r1sn9ck2MCc3IQDKwLrxkFUoBynfHMWN1ORU72mOsf8="; }; nativeBuildInputs = [ @@ -63,6 +67,10 @@ stdenv.mkDerivation rec { scripts/extract-release-date-from-doap-file.py ''; + passthru = { + updateScript = directoryListingUpdater { }; + }; + meta = with lib; { description = "Library for creation of audio/video non-linear editors"; mainProgram = "ges-launch-1.0"; @@ -71,4 +79,4 @@ stdenv.mkDerivation rec { platforms = platforms.unix; maintainers = [ ]; }; -} +}) diff --git a/pkgs/development/libraries/gstreamer/good/default.nix b/pkgs/development/libraries/gstreamer/good/default.nix index dd8abf8a8b996..d81f85aa9cbad 100644 --- a/pkgs/development/libraries/gstreamer/good/default.nix +++ b/pkgs/development/libraries/gstreamer/good/default.nix @@ -50,26 +50,28 @@ , openssl # Checks meson.is_cross_build(), so even canExecute isn't enough. , enableDocumentation ? stdenv.hostPlatform == stdenv.buildPlatform, hotdoc +, directoryListingUpdater }: # MMAL is not supported on aarch64, see: # https://github.com/raspberrypi/userland/issues/688 assert raspiCameraSupport -> (stdenv.hostPlatform.isLinux && stdenv.hostPlatform.isAarch32); -stdenv.mkDerivation rec { +stdenv.mkDerivation (finalAttrs: { pname = "gst-plugins-good"; - version = "1.24.10"; + version = "1.26.0"; - outputs = [ "out" "dev" ]; + outputs = [ + "out" + "dev" + ]; src = fetchurl { - url = "https://gstreamer.freedesktop.org/src/${pname}/${pname}-${version}.tar.xz"; - hash = "sha256-/OdI+mbXqO4fsmFInlnQHj+nh2I9bVw1BoQW/nzQrLM="; + url = "https://gstreamer.freedesktop.org/src/gst-plugins-good/gst-plugins-good-${finalAttrs.version}.tar.xz"; + hash = "sha256-nhjxOe9prQhnwt+7j+HRc2123xGqyD9g6NOtseLq8Ds="; }; patches = [ - # Reenable dynamic loading of libsoup on Darwin and use a different approach to do it. - ./souploader-darwin.diff # dlopen libsoup_3 with an absolute path (replaceVars ./souploader.diff { nixLibSoup3Path = "${lib.getLib libsoup_3}/lib"; @@ -164,7 +166,7 @@ stdenv.mkDerivation rec { mesonFlags = [ "-Dexamples=disabled" # requires many dependencies and probably not useful for our users - "-Dglib-asserts=disabled" # asserts should be disabled on stable releases + "-Dglib_debug=disabled" # cast checks should be disabled on stable releases (lib.mesonEnable "doc" enableDocumentation) ] ++ lib.optionals (!qt5Support) [ "-Dqt5=disabled" @@ -194,11 +196,12 @@ stdenv.mkDerivation rec { scripts/extract-release-date-from-doap-file.py ''; - NIX_LDFLAGS = [ - # linking error on Darwin - # https://github.com/NixOS/nixpkgs/pull/70690#issuecomment-553694896 - "-lncurses" - ]; + env = { + NIX_LDFLAGS = + # linking error on Darwin + # https://github.com/NixOS/nixpkgs/pull/70690#issuecomment-553694896 + "-lncurses"; + }; # fails 1 tests with "Unexpected critical/warning: g_object_set_is_valid_property: object class 'GstRtpStorage' has no property named ''" doCheck = false; @@ -206,6 +209,10 @@ stdenv.mkDerivation rec { # must be explicitly set since 5590e365 dontWrapQtApps = true; + passthru = { + updateScript = directoryListingUpdater { }; + }; + meta = with lib; { description = "GStreamer Good Plugins"; homepage = "https://gstreamer.freedesktop.org"; @@ -218,4 +225,4 @@ stdenv.mkDerivation rec { platforms = platforms.linux ++ platforms.darwin; maintainers = with maintainers; [ matthewbauer ]; }; -} +}) diff --git a/pkgs/development/libraries/gstreamer/good/souploader-darwin.diff b/pkgs/development/libraries/gstreamer/good/souploader-darwin.diff deleted file mode 100644 index 40dea3a764ac7..0000000000000 --- a/pkgs/development/libraries/gstreamer/good/souploader-darwin.diff +++ /dev/null @@ -1,128 +0,0 @@ -diff --git a/ext/adaptivedemux2/meson.build b/ext/adaptivedemux2/meson.build -index 711b38a2a9..67a789f664 100644 ---- a/ext/adaptivedemux2/meson.build -+++ b/ext/adaptivedemux2/meson.build -@@ -82,7 +82,7 @@ soup_link_args = [] - soup_link_deps = [] - - default_library = get_option('default_library') --if host_system != 'linux' or default_library in ['static', 'both'] -+if default_library in ['static', 'both'] - if soup_ver_opt in ['auto', '3'] - libsoup3_dep = dependency('libsoup-3.0', allow_fallback: true, - required: soup_ver_opt == '3' and soup_opt.enabled()) -@@ -120,7 +120,7 @@ adaptive_deps = [gmodule_dep, gst_dep, gsttag_dep, gstnet_dep, gstbase_dep, gstp - adaptive_args = [gst_plugins_good_args, soup_loader_args, hls_cargs, - '-DGST_ISOFF_API=G_GNUC_INTERNAL'] - --if host_system != 'linux' -+if false - adaptivedemux2 = library('gstadaptivedemux2', - c_args: [adaptive_args, soup_link_args], - dependencies: [adaptive_deps, soup_link_deps], -diff --git a/ext/soup/gstsouploader.c b/ext/soup/gstsouploader.c -index 9192e4dac5..8082b2614d 100644 ---- a/ext/soup/gstsouploader.c -+++ b/ext/soup/gstsouploader.c -@@ -34,12 +34,18 @@ GST_DEBUG_CATEGORY (gst_soup_debug); - - #ifndef LINK_SOUP - --#if defined(__APPLE__) || defined(G_OS_WIN32) --#error "dlopen of libsoup is only supported on Linux" -+#if defined(G_OS_WIN32) -+#error "dlopen of libsoup is only supported on Darwin and Linux" - #endif - -+#if defined(__APPLE__) -+#define LIBSOUP_3_SONAME "libsoup-3.0.0.dylib" -+#define LIBSOUP_2_SONAME "libsoup-2.4.1.dylib" -+#define LIBSOUP_COMMON_SYMBOL "soup_get_major_version" -+#else - #define LIBSOUP_3_SONAME "libsoup-3.0.so.0" - #define LIBSOUP_2_SONAME "libsoup-2.4.so.1" -+#endif - - #define LOAD_SYMBOL(name) G_STMT_START { \ - if (!g_module_symbol (module, G_STRINGIFY (name), (gpointer *) &G_PASTE (vtable->_, name))) { \ -@@ -156,7 +162,46 @@ gst_soup_load_library (void) - GST_DEBUG_CATEGORY_INIT (gst_soup_debug, "soup", 0, "soup"); - #endif - --#ifdef HAVE_RTLD_NOLOAD -+#if defined(__APPLE__) -+ g_autofree gchar* libsoup_path = NULL; -+ { -+ /* In order to avoid causing conflicts we detect if libsoup 2 or 3 is loaded already. -+ * Darwin has to probe by checking for symbols because `dlopen` called with a dylib -+ * basename will try to locate it via the process’s rpath stack (and not find it). */ -+ -+ gpointer func = NULL; -+ Dl_info info = { 0 }; -+ -+ GModule* module = g_module_open (NULL, 0); -+ if (g_module_symbol (module, LIBSOUP_COMMON_SYMBOL, &func) -+ && dladdr (func, &info) && info.dli_sname) { -+ libsoup_path = g_strndup(info.dli_fname, PATH_MAX - 1); -+ g_autofree gchar* image_name = g_path_get_basename (libsoup_path); -+ -+ /* Make sure `libsoup_path` points to a dylib that actually exists and -+ * contains the libsoup symbol that was queried. */ -+ gpointer handle = dlopen (libsoup_path, RTLD_NOW | RTLD_NOLOAD); -+ gboolean has_symbol = dlsym (handle, LIBSOUP_COMMON_SYMBOL) != NULL; -+ if (handle && has_symbol && g_str_equal (image_name, LIBSOUP_3_SONAME)) { -+ libsoup_sonames[0] = libsoup_path; -+ GST_DEBUG ("LibSoup 3 found"); -+ } else if (handle && has_symbol && g_str_equal (image_name, LIBSOUP_2_SONAME)) { -+ libsoup_sonames[0] = libsoup_path; -+ GST_DEBUG ("LibSoup 2 found"); -+ } else { -+ g_clear_pointer (&libsoup_path, g_free); -+ } -+ g_clear_pointer (&handle, dlclose); -+ } -+ g_module_close (module); -+ -+ if (!libsoup_sonames[0]) { -+ GST_DEBUG ("Trying all libsoups"); -+ libsoup_sonames[0] = LIBSOUP_3_SONAME; -+ libsoup_sonames[1] = LIBSOUP_2_SONAME; -+ } -+ } -+#elif defined(HAVE_RTLD_NOLOAD) - { - gpointer handle = NULL; - -diff --git a/ext/soup/meson.build b/ext/soup/meson.build -index aaa01dbcf6..83b7cf3fbf 100644 ---- a/ext/soup/meson.build -+++ b/ext/soup/meson.build -@@ -20,8 +20,8 @@ soup_link_deps = [] - libsoup2_dep = disabler() - libsoup3_dep = disabler() - default_library = get_option('default_library') --soup_lookup_dep = get_option('soup-lookup-dep') and host_system == 'linux' --if host_system != 'linux' or default_library in ['static', 'both'] or soup_lookup_dep -+soup_lookup_dep = get_option('soup-lookup-dep') -+if default_library in ['static', 'both'] or soup_lookup_dep - if soup_ver_opt in ['auto', '3'] - libsoup3_dep = dependency('libsoup-3.0', allow_fallback: true, - required: soup_ver_opt == '3' and soup_opt.enabled()) -@@ -33,7 +33,7 @@ if host_system != 'linux' or default_library in ['static', 'both'] or soup_looku - endif - endif - --if host_system != 'linux' or default_library in ['static', 'both'] -+if default_library in ['static', 'both'] - if libsoup3_dep.found() - soup_link_deps += libsoup3_dep - soup_link_args += '-DLINK_SOUP=3' -@@ -60,7 +60,7 @@ soup_library_kwargs = { - soup_library_deps = [gst_dep, gstbase_dep, gsttag_dep, gmodule_dep, gio_dep, libdl_dep] - soup_library_c_args = gst_plugins_good_args - --if host_system != 'linux' -+if false - gstsouphttpsrc = library('gstsoup', - c_args : soup_library_c_args + soup_link_args, - dependencies : soup_library_deps + soup_link_deps, diff --git a/pkgs/development/libraries/gstreamer/good/souploader.diff b/pkgs/development/libraries/gstreamer/good/souploader.diff index 49917cad91dec..56736d12a9ab2 100644 --- a/pkgs/development/libraries/gstreamer/good/souploader.diff +++ b/pkgs/development/libraries/gstreamer/good/souploader.diff @@ -1,17 +1,8 @@ diff --git a/ext/soup/gstsouploader.c b/ext/soup/gstsouploader.c -index 85a033668e..8082b2614d 100644 +index 41f3aa3783..451e15b40d 100644 --- a/ext/soup/gstsouploader.c +++ b/ext/soup/gstsouploader.c -@@ -197,7 +197,7 @@ gst_soup_load_library (void) - - if (!libsoup_sonames[0]) { - GST_DEBUG ("Trying all libsoups"); -- libsoup_sonames[0] = LIBSOUP_3_SONAME; -+ libsoup_sonames[0] = "@nixLibSoup3Path@/" LIBSOUP_3_SONAME; - libsoup_sonames[1] = LIBSOUP_2_SONAME; - } - } -@@ -216,7 +216,7 @@ gst_soup_load_library (void) +@@ -178,7 +178,7 @@ gst_soup_load_library (void) GST_DEBUG ("LibSoup 2 found"); } else { GST_DEBUG ("Trying all libsoups"); diff --git a/pkgs/development/libraries/gstreamer/libav/default.nix b/pkgs/development/libraries/gstreamer/libav/default.nix index 1b96686774054..63b05d2b02869 100644 --- a/pkgs/development/libraries/gstreamer/libav/default.nix +++ b/pkgs/development/libraries/gstreamer/libav/default.nix @@ -1,29 +1,35 @@ -{ stdenv -, lib -, fetchurl -, meson -, ninja -, pkg-config -, python3 -, gstreamer -, gst-plugins-base -, gettext -, ffmpeg-headless -# Checks meson.is_cross_build(), so even canExecute isn't enough. -, enableDocumentation ? stdenv.hostPlatform == stdenv.buildPlatform, hotdoc +{ + stdenv, + lib, + fetchurl, + meson, + ninja, + pkg-config, + python3, + gstreamer, + gst-plugins-base, + gettext, + ffmpeg-headless, + # Checks meson.is_cross_build(), so even canExecute isn't enough. + enableDocumentation ? stdenv.hostPlatform == stdenv.buildPlatform, + hotdoc, + directoryListingUpdater, }: -stdenv.mkDerivation rec { +stdenv.mkDerivation (finalAttrs: { pname = "gst-libav"; - version = "1.24.10"; + version = "1.26.0"; + + outputs = [ + "out" + "dev" + ]; src = fetchurl { - url = "https://gstreamer.freedesktop.org/src/${pname}/${pname}-${version}.tar.xz"; - hash = "sha256-TPLi2CBOVLqK+VGai5t/+m6VGnCHr6Df6DwSXUm7tfs="; + url = "https://gstreamer.freedesktop.org/src/gst-libav/gst-libav-${finalAttrs.version}.tar.xz"; + hash = "sha256-cHqLaH/1/dzuWwJBXi7JtxtKxE0Leuw7R3Nkzuy/Hs8="; }; - outputs = [ "out" "dev" ]; - nativeBuildInputs = [ meson ninja @@ -49,6 +55,10 @@ stdenv.mkDerivation rec { scripts/extract-release-date-from-doap-file.py ''; + passthru = { + updateScript = directoryListingUpdater { }; + }; + meta = with lib; { description = "FFmpeg plugin for GStreamer"; homepage = "https://gstreamer.freedesktop.org"; @@ -56,4 +66,4 @@ stdenv.mkDerivation rec { platforms = platforms.unix; maintainers = [ ]; }; -} +}) diff --git a/pkgs/development/libraries/gstreamer/rs/default.nix b/pkgs/development/libraries/gstreamer/rs/default.nix index c80c40b1d3f49..06a6a2fef42ca 100644 --- a/pkgs/development/libraries/gstreamer/rs/default.nix +++ b/pkgs/development/libraries/gstreamer/rs/default.nix @@ -157,7 +157,7 @@ assert lib.assertMsg (invalidPlugins == [ ]) stdenv.mkDerivation (finalAttrs: { pname = "gst-plugins-rs"; - version = "0.13.3"; + version = "0.13.5"; outputs = [ "out" @@ -169,7 +169,7 @@ stdenv.mkDerivation (finalAttrs: { owner = "gstreamer"; repo = "gst-plugins-rs"; rev = finalAttrs.version; - hash = "sha256-G6JdZXBNiZfbu6EBTOsJ4Id+BvPhIToZmHHi7zuapnE="; + hash = "sha256-5jR/YLCBeFnB0+O2OOCLBEKwikiQ5e+SbOeQCijnd8Q="; # TODO: temporary workaround for case-insensitivity problems with color-name crate - https://github.com/annymosse/color-name/pull/2 postFetch = '' sedSearch="$(cat <<\EOF | sed -ze 's/\n/\\n/g' @@ -191,13 +191,25 @@ stdenv.mkDerivation (finalAttrs: { ''; }; - cargoDeps = - with finalAttrs; - rustPlatform.fetchCargoVendor { - inherit src; - name = "${pname}-${version}"; - hash = "sha256-NFB9kNmCF3SnOgpSd7SSihma+Ooqwxtrym9Il4A+uQY="; - }; + cargoDeps = rustPlatform.fetchCargoVendor { + inherit (finalAttrs) src patches; + name = "gst-plugins-rs-${finalAttrs.version}"; + hash = "sha256-ErQ5Um0e7bWhzDErEN9vmSsKTpTAm4MA5PZ7lworVKU="; + }; + + patches = [ + # Disable uriplaylistbin test that requires network access. + # https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/676 + # TODO: Remove in 0.14, it has been replaced by a different fix: + # https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2140 + ./ignore-network-tests.patch + + # Fix reqwest tests failing due to broken TLS lookup in native-tls dependency. + # https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/675 + # Cannot be upstreamed due to MSRV bump in native-tls: + # https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/2142 + ./reqwest-init-tls.patch + ]; strictDeps = true; @@ -257,6 +269,11 @@ stdenv.mkDerivation (finalAttrs: { mesonCheckFlags = [ "--verbose" ]; + preCheck = '' + # Fontconfig error: No writable cache directories + export XDG_CACHE_HOME=$(mktemp -d) + ''; + doInstallCheck = (lib.elem "webp" selectedPlugins) && !stdenv.hostPlatform.isStatic && stdenv.hostPlatform.isElf; installCheckPhase = '' diff --git a/pkgs/development/libraries/gstreamer/rs/ignore-network-tests.patch b/pkgs/development/libraries/gstreamer/rs/ignore-network-tests.patch new file mode 100644 index 0000000000000..22bcce3f2e37f --- /dev/null +++ b/pkgs/development/libraries/gstreamer/rs/ignore-network-tests.patch @@ -0,0 +1,12 @@ +diff --git a/utils/uriplaylistbin/tests/uriplaylistbin.rs b/utils/uriplaylistbin/tests/uriplaylistbin.rs +index dfd1c9ce..8ed24949 100644 +--- a/utils/uriplaylistbin/tests/uriplaylistbin.rs ++++ b/utils/uriplaylistbin/tests/uriplaylistbin.rs +@@ -534,6 +534,7 @@ fn infinite_to_finite() { + assert_eq!(current_uri_index, 0); + } + ++#[ignore = "Requires network access"] + #[test] + /// cache HTTP playlist items + fn cache() { diff --git a/pkgs/development/libraries/gstreamer/rs/reqwest-init-tls.patch b/pkgs/development/libraries/gstreamer/rs/reqwest-init-tls.patch new file mode 100644 index 0000000000000..24764673bec0e --- /dev/null +++ b/pkgs/development/libraries/gstreamer/rs/reqwest-init-tls.patch @@ -0,0 +1,85 @@ +The reqwest tests fail due to reqwest Client initialization. +Bisected the issue to https://github.com/sfackler/rust-native-tls/compare/v0.2.12...v0.2.13 bump +in https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/commit/6d5d9753f4a28be350dc657c08a9ecc7f13b922a +the upcoming version of native-tls fixes that so let’s bump to that. +https://github.com/sfackler/rust-native-tls/compare/v0.2.13...v0.2.14 + +diff --git a/Cargo.lock b/Cargo.lock +index 244256cd..24f0c607 100644 +--- a/Cargo.lock ++++ b/Cargo.lock +@@ -1700,7 +1700,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" + checksum = "33d852cb9b869c2a9b3df2f71a3074817f01e1844f839a144f5fcef059a4eb5d" + dependencies = [ + "libc", +- "windows-sys 0.59.0", ++ "windows-sys 0.52.0", + ] + + [[package]] +@@ -2149,7 +2149,7 @@ dependencies = [ + "gobject-sys", + "libc", + "system-deps 7.0.3", +- "windows-sys 0.59.0", ++ "windows-sys 0.52.0", + ] + + [[package]] +@@ -4407,7 +4407,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" + checksum = "fc2f4eb4bc735547cfed7c0a4922cbd04a4655978c09b54f1f7b228750664c34" + dependencies = [ + "cfg-if", +- "windows-targets 0.52.6", ++ "windows-targets 0.48.5", + ] + + [[package]] +@@ -4791,9 +4791,9 @@ dependencies = [ + + [[package]] + name = "native-tls" +-version = "0.2.13" ++version = "0.2.14" + source = "registry+https://github.com/rust-lang/crates.io-index" +-checksum = "0dab59f8e050d5df8e4dd87d9206fb6f65a483e20ac9fda365ade4fab353196c" ++checksum = "87de3442987e9dbec73158d5c715e7ad9072fda936bb03d19d7fa10e00520f0e" + dependencies = [ + "libc", + "log", +@@ -5572,7 +5572,7 @@ dependencies = [ + "once_cell", + "socket2", + "tracing", +- "windows-sys 0.59.0", ++ "windows-sys 0.52.0", + ] + + [[package]] +@@ -6017,7 +6017,7 @@ dependencies = [ + "errno", + "libc", + "linux-raw-sys", +- "windows-sys 0.59.0", ++ "windows-sys 0.52.0", + ] + + [[package]] +@@ -6702,7 +6702,7 @@ dependencies = [ + "getrandom 0.3.1", + "once_cell", + "rustix", +- "windows-sys 0.59.0", ++ "windows-sys 0.52.0", + ] + + [[package]] +@@ -7523,7 +7523,7 @@ version = "0.1.9" + source = "registry+https://github.com/rust-lang/crates.io-index" + checksum = "cf221c93e13a30d793f7645a0e7762c55d169dbb0a49671918a2319d289b10bb" + dependencies = [ +- "windows-sys 0.59.0", ++ "windows-sys 0.48.0", + ] + + [[package]] diff --git a/pkgs/development/libraries/gstreamer/rtsp-server/default.nix b/pkgs/development/libraries/gstreamer/rtsp-server/default.nix index b3fc60c35259c..ce5276cfe6dc7 100644 --- a/pkgs/development/libraries/gstreamer/rtsp-server/default.nix +++ b/pkgs/development/libraries/gstreamer/rtsp-server/default.nix @@ -1,32 +1,35 @@ -{ stdenv -, lib -, fetchurl -, meson -, ninja -, pkg-config -, python3 -, gettext -, gobject-introspection -, gst-plugins-base -, gst-plugins-bad -# Checks meson.is_cross_build(), so even canExecute isn't enough. -, enableDocumentation ? stdenv.hostPlatform == stdenv.buildPlatform, hotdoc +{ + stdenv, + lib, + fetchurl, + meson, + ninja, + pkg-config, + python3, + gettext, + gobject-introspection, + gst-plugins-base, + gst-plugins-bad, + # Checks meson.is_cross_build(), so even canExecute isn't enough. + enableDocumentation ? stdenv.hostPlatform == stdenv.buildPlatform, + hotdoc, + directoryListingUpdater, }: -stdenv.mkDerivation rec { +stdenv.mkDerivation (finalAttrs: { pname = "gst-rtsp-server"; - version = "1.24.10"; - - src = fetchurl { - url = "https://gstreamer.freedesktop.org/src/${pname}/${pname}-${version}.tar.xz"; - hash = "sha256-2yHf3Xvy5xhWTVVzeK2lNYtBHv4qPonp8Ph6dFN+Ktw="; - }; + version = "1.26.0"; outputs = [ "out" "dev" ]; + src = fetchurl { + url = "https://gstreamer.freedesktop.org/src/gst-rtsp-server/gst-rtsp-server-${finalAttrs.version}.tar.xz"; + hash = "sha256-6YPAOUluP3XjlpZVTOdNtBIOJGXeF6ocw3FgVo6bQLw="; + }; + nativeBuildInputs = [ meson ninja @@ -44,6 +47,7 @@ stdenv.mkDerivation rec { ]; mesonFlags = [ + "-Dglib_debug=disabled" # cast checks should be disabled on stable releases "-Dexamples=disabled" # requires many dependencies and probably not useful for our users (lib.mesonEnable "doc" enableDocumentation) ]; @@ -53,6 +57,10 @@ stdenv.mkDerivation rec { scripts/extract-release-date-from-doap-file.py ''; + passthru = { + updateScript = directoryListingUpdater { }; + }; + meta = with lib; { description = "GStreamer RTSP server"; homepage = "https://gstreamer.freedesktop.org"; @@ -63,4 +71,4 @@ stdenv.mkDerivation rec { platforms = platforms.unix; maintainers = with maintainers; [ bkchr ]; }; -} +}) diff --git a/pkgs/development/libraries/gstreamer/ugly/default.nix b/pkgs/development/libraries/gstreamer/ugly/default.nix index 374500f9a7082..6c438d6d61984 100644 --- a/pkgs/development/libraries/gstreamer/ugly/default.nix +++ b/pkgs/development/libraries/gstreamer/ugly/default.nix @@ -1,37 +1,43 @@ -{ stdenv -, fetchurl -, meson -, ninja -, pkg-config -, python3 -, gst-plugins-base -, orc -, gettext -, a52dec -, libcdio -, libdvdread -, libmad -, libmpeg2 -, x264 -, libintl -, lib -, IOKit -, CoreFoundation -, DiskArbitration -, enableGplPlugins ? true -# Checks meson.is_cross_build(), so even canExecute isn't enough. -, enableDocumentation ? stdenv.hostPlatform == stdenv.buildPlatform, hotdoc +{ + stdenv, + fetchurl, + meson, + ninja, + pkg-config, + python3, + gst-plugins-base, + orc, + gettext, + a52dec, + libcdio, + libdvdread, + libmad, + libmpeg2, + x264, + libintl, + lib, + IOKit, + CoreFoundation, + DiskArbitration, + enableGplPlugins ? true, + # Checks meson.is_cross_build(), so even canExecute isn't enough. + enableDocumentation ? stdenv.hostPlatform == stdenv.buildPlatform, + hotdoc, + directoryListingUpdater, }: -stdenv.mkDerivation rec { +stdenv.mkDerivation (finalAttrs: { pname = "gst-plugins-ugly"; - version = "1.24.10"; + version = "1.26.0"; - outputs = [ "out" "dev" ]; + outputs = [ + "out" + "dev" + ]; src = fetchurl { - url = "https://gstreamer.freedesktop.org/src/${pname}/${pname}-${version}.tar.xz"; - hash = "sha256-nfb9haclYkHvuyX4SzN1deOzRSZvXas4STceRpR3nxg="; + url = "https://gstreamer.freedesktop.org/src/gst-plugins-ugly/gst-plugins-ugly-${finalAttrs.version}.tar.xz"; + hash = "sha256-qGtRyEVKgTEghIyANCHzJ9jAeqvK5GHgWXzEk5jA/N4="; }; nativeBuildInputs = [ @@ -62,6 +68,7 @@ stdenv.mkDerivation rec { ]; mesonFlags = [ + "-Dglib_debug=disabled" # cast checks should be disabled on stable releases "-Dsidplay=disabled" # sidplay / sidplay/player.h isn't packaged in nixpkgs as of writing (lib.mesonEnable "doc" enableDocumentation) ] ++ (if enableGplPlugins then [ @@ -80,6 +87,10 @@ stdenv.mkDerivation rec { scripts/extract-release-date-from-doap-file.py ''; + passthru = { + updateScript = directoryListingUpdater { }; + }; + meta = with lib; { description = "Gstreamer Ugly Plugins"; homepage = "https://gstreamer.freedesktop.org"; @@ -93,4 +104,4 @@ stdenv.mkDerivation rec { platforms = platforms.unix; maintainers = with maintainers; [ matthewbauer ]; }; -} +}) diff --git a/pkgs/development/libraries/gstreamer/vaapi/default.nix b/pkgs/development/libraries/gstreamer/vaapi/default.nix index 3f93a52671b8b..eccbb415ee9dc 100644 --- a/pkgs/development/libraries/gstreamer/vaapi/default.nix +++ b/pkgs/development/libraries/gstreamer/vaapi/default.nix @@ -1,42 +1,46 @@ -{ lib, stdenv -, fetchurl -, meson -, ninja -, pkg-config -, gst-plugins-base -, bzip2 -, libva -, wayland -, wayland-protocols -, wayland-scanner -, libdrm -, udev -, xorg -, libGLU -, libGL -, gstreamer -, gst-plugins-bad -, nasm -, libvpx -, python3 -# Checks meson.is_cross_build(), so even canExecute isn't enough. -, enableDocumentation ? stdenv.hostPlatform == stdenv.buildPlatform, hotdoc +{ + lib, + stdenv, + fetchurl, + meson, + ninja, + pkg-config, + gst-plugins-base, + bzip2, + libva, + wayland, + wayland-protocols, + wayland-scanner, + libdrm, + udev, + xorg, + libGLU, + libGL, + gstreamer, + gst-plugins-bad, + nasm, + libvpx, + python3, + # Checks meson.is_cross_build(), so even canExecute isn't enough. + enableDocumentation ? stdenv.hostPlatform == stdenv.buildPlatform, + hotdoc, + directoryListingUpdater, }: -stdenv.mkDerivation rec { +stdenv.mkDerivation (finalAttrs: { pname = "gstreamer-vaapi"; - version = "1.24.10"; - - src = fetchurl { - url = "https://gstreamer.freedesktop.org/src/${pname}/${pname}-${version}.tar.xz"; - hash = "sha256-IVk9veXGvNz+mRld7748P02gHLhfjsEKrpQ4h9Odikw="; - }; + version = "1.26.0"; outputs = [ "out" "dev" ]; + src = fetchurl { + url = "https://gstreamer.freedesktop.org/src/gstreamer-vaapi/gstreamer-vaapi-${finalAttrs.version}.tar.xz"; + hash = "sha256-Vzkx1FX1qW9j23yNNdUTIrjSh4FujGp32Ez7ufoTUfE="; + }; + nativeBuildInputs = [ meson ninja @@ -82,6 +86,10 @@ stdenv.mkDerivation rec { scripts/extract-release-date-from-doap-file.py ''; + passthru = { + updateScript = directoryListingUpdater { }; + }; + meta = with lib; { description = "Set of VAAPI GStreamer Plug-ins"; homepage = "https://gstreamer.freedesktop.org"; @@ -89,4 +97,4 @@ stdenv.mkDerivation rec { platforms = platforms.linux; maintainers = [ ]; }; -} +}) diff --git a/pkgs/development/python-modules/gst-python/default.nix b/pkgs/development/python-modules/gst-python/default.nix index 8b744206d1481..301da0fc46dd2 100644 --- a/pkgs/development/python-modules/gst-python/default.nix +++ b/pkgs/development/python-modules/gst-python/default.nix @@ -2,6 +2,7 @@ lib, buildPythonPackage, fetchurl, + fetchpatch, meson, ninja, @@ -11,11 +12,12 @@ gobject-introspection, gst_all_1, isPy3k, + directoryListingUpdater, }: buildPythonPackage rec { pname = "gst-python"; - version = "1.24.10"; + version = "1.26.0"; format = "other"; @@ -25,10 +27,20 @@ buildPythonPackage rec { ]; src = fetchurl { - url = "https://gstreamer.freedesktop.org/src/gst-python/${pname}-${version}.tar.xz"; - hash = "sha256-E1vPi28UaLwx5WYECf6O04EJ8B3sRHQ1FKovprOGMwk"; + url = "https://gstreamer.freedesktop.org/src/gst-python/gst-python-${version}.tar.xz"; + hash = "sha256-5QRqBdd6uxVnGtAc0ZCNF9YuWgb114Qb5DQq3io/uNs="; }; + patches = [ + # Fix segfault with PyGObject>=3.52.0 + # https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8653 + (fetchpatch { + url = "https://gitlab.freedesktop.org/gstreamer/gstreamer/-/commit/69bba61e548c7a63bc18137e63e41489a7de9d36.patch"; + stripLen = 2; + hash = "sha256-BfWPc8dsB09KiEm9bNT8e+jH76jiDefQlEhhLJoq7tI="; + }) + ]; + # Python 2.x is not supported. disabled = !isPy3k; @@ -42,21 +54,34 @@ buildPythonPackage rec { gst_all_1.gst-plugins-base ]; + buildInputs = [ + # for gstreamer-analytics-1.0 + gst_all_1.gst-plugins-bad + ]; + propagatedBuildInputs = [ gst_all_1.gst-plugins-base pygobject3 ]; + checkInputs = [ + gst_all_1.gst-rtsp-server + ]; + mesonFlags = [ "-Dpygi-overrides-dir=${placeholder "out"}/${python.sitePackages}/gi/overrides" # Exec format error during configure - "-Dpython=${python.pythonOnBuildForHost.interpreter}" + "-Dpython-exe=${python.pythonOnBuildForHost.interpreter}" ]; # TODO: Meson setup hook does not like buildPythonPackage # https://github.com/NixOS/nixpkgs/issues/47390 installCheckPhase = "meson test --print-errorlogs"; + passthru = { + updateScript = directoryListingUpdater { }; + }; + meta = with lib; { homepage = "https://gstreamer.freedesktop.org"; description = "Python bindings for GStreamer";