SDL2: add pipewire & libdecor support
Co-authored-by: jakobrs <jakobrs100@gmail.com>
This commit is contained in:
parent
acc1ac4535
commit
baee63f5e1
|
@ -31,6 +31,10 @@
|
||||||
, ibus
|
, ibus
|
||||||
, fcitxSupport ? false
|
, fcitxSupport ? false
|
||||||
, fcitx
|
, fcitx
|
||||||
|
, libdecorSupport ? stdenv.isLinux && !stdenv.hostPlatform.isAndroid
|
||||||
|
, libdecor
|
||||||
|
, pipewireSupport ? stdenv.isLinux && !stdenv.hostPlatform.isAndroid
|
||||||
|
, pipewire # NOTE: must be built with SDL2 without pipewire support
|
||||||
, pulseaudioSupport ? config.pulseaudio or stdenv.isLinux && !stdenv.hostPlatform.isAndroid
|
, pulseaudioSupport ? config.pulseaudio or stdenv.isLinux && !stdenv.hostPlatform.isAndroid
|
||||||
, libpulseaudio
|
, libpulseaudio
|
||||||
, AudioUnit
|
, AudioUnit
|
||||||
|
@ -75,6 +79,8 @@ stdenv.mkDerivation rec {
|
||||||
|
|
||||||
dlopenBuildInputs = optionals alsaSupport [ alsa-lib audiofile ]
|
dlopenBuildInputs = optionals alsaSupport [ alsa-lib audiofile ]
|
||||||
++ optional dbusSupport dbus
|
++ optional dbusSupport dbus
|
||||||
|
++ optional libdecorSupport libdecor
|
||||||
|
++ optional pipewireSupport pipewire
|
||||||
++ optional pulseaudioSupport libpulseaudio
|
++ optional pulseaudioSupport libpulseaudio
|
||||||
++ optional udevSupport udev
|
++ optional udevSupport udev
|
||||||
++ optionals waylandSupport [ wayland wayland-protocols libxkbcommon ]
|
++ optionals waylandSupport [ wayland wayland-protocols libxkbcommon ]
|
||||||
|
|
|
@ -20,7 +20,6 @@
|
||||||
, udev
|
, udev
|
||||||
, libva
|
, libva
|
||||||
, libsndfile
|
, libsndfile
|
||||||
, SDL2
|
|
||||||
, vulkan-headers
|
, vulkan-headers
|
||||||
, vulkan-loader
|
, vulkan-loader
|
||||||
, webrtc-audio-processing
|
, webrtc-audio-processing
|
||||||
|
@ -129,7 +128,6 @@ let
|
||||||
vulkan-headers
|
vulkan-headers
|
||||||
vulkan-loader
|
vulkan-loader
|
||||||
webrtc-audio-processing
|
webrtc-audio-processing
|
||||||
SDL2
|
|
||||||
systemd
|
systemd
|
||||||
] ++ lib.optionals gstreamerSupport [ gst_all_1.gst-plugins-base gst_all_1.gstreamer ]
|
] ++ lib.optionals gstreamerSupport [ gst_all_1.gst-plugins-base gst_all_1.gstreamer ]
|
||||||
++ lib.optionals libcameraSupport [ libcamera libdrm ]
|
++ lib.optionals libcameraSupport [ libcamera libdrm ]
|
||||||
|
@ -139,7 +137,7 @@ let
|
||||||
++ lib.optional zeroconfSupport avahi
|
++ lib.optional zeroconfSupport avahi
|
||||||
++ lib.optional raopSupport openssl
|
++ lib.optional raopSupport openssl
|
||||||
++ lib.optional rocSupport roc-toolkit
|
++ lib.optional rocSupport roc-toolkit
|
||||||
++ lib.optionals x11Support [ libcanberra xorg.libxcb ];
|
++ lib.optionals x11Support [ libcanberra xorg.libX11 ];
|
||||||
|
|
||||||
# Valgrind binary is required for running one optional test.
|
# Valgrind binary is required for running one optional test.
|
||||||
checkInputs = lib.optional withValgrind valgrind;
|
checkInputs = lib.optional withValgrind valgrind;
|
||||||
|
@ -169,6 +167,7 @@ let
|
||||||
"-Dsession-managers="
|
"-Dsession-managers="
|
||||||
"-Dvulkan=enabled"
|
"-Dvulkan=enabled"
|
||||||
"-Dx11=${mesonEnableFeature x11Support}"
|
"-Dx11=${mesonEnableFeature x11Support}"
|
||||||
|
"-Dsdl2=disabled" # required only to build examples, causes dependency loop
|
||||||
];
|
];
|
||||||
|
|
||||||
# Fontconfig error: Cannot load default config file
|
# Fontconfig error: Cannot load default config file
|
||||||
|
|
|
@ -13962,8 +13962,18 @@ with pkgs;
|
||||||
|
|
||||||
pipenv = callPackage ../development/tools/pipenv {};
|
pipenv = callPackage ../development/tools/pipenv {};
|
||||||
|
|
||||||
pipewire = callPackage ../development/libraries/pipewire {};
|
pipewire = callPackage ../development/libraries/pipewire {
|
||||||
|
# ffmpeg depends on SDL2 which depends on pipewire by default.
|
||||||
|
# Break the cycle by disabling pipewire support in our ffmpeg.
|
||||||
|
ffmpeg = ffmpeg.override {
|
||||||
|
SDL2 = SDL2.override {
|
||||||
|
pipewireSupport = false;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
pipewire-media-session = callPackage ../development/libraries/pipewire/media-session.nix {};
|
pipewire-media-session = callPackage ../development/libraries/pipewire/media-session.nix {};
|
||||||
|
|
||||||
pipewire_0_2 = callPackage ../development/libraries/pipewire/0.2.nix {};
|
pipewire_0_2 = callPackage ../development/libraries/pipewire/0.2.nix {};
|
||||||
wireplumber = callPackage ../development/libraries/pipewire/wireplumber.nix {};
|
wireplumber = callPackage ../development/libraries/pipewire/wireplumber.nix {};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue