diff --git a/pkgs/development/libraries/SDL/default.nix b/pkgs/development/libraries/SDL/default.nix index 08a52096d4b1..7ef3c4c89686 100644 --- a/pkgs/development/libraries/SDL/default.nix +++ b/pkgs/development/libraries/SDL/default.nix @@ -1,8 +1,8 @@ -{ stdenv, lib, fetchurl, fetchpatch, pkgconfig, audiofile, libcap, libiconv -, openglSupport ? false, libGL, libGLU -, alsaSupport ? true, alsaLib -, x11Support ? stdenv.hostPlatform == stdenv.buildPlatform, libXext, libICE, libXrandr -, pulseaudioSupport ? true, libpulseaudio +{ stdenv, config, libGLSupported, fetchurl, fetchpatch, pkgconfig, audiofile, libcap, libiconv +, openglSupport ? libGLSupported, libGL, libGLU +, alsaSupport ? stdenv.isLinux, alsaLib +, x11Support ? !stdenv.isCygwin, libXext, libICE, libXrandr +, pulseaudioSupport ? config.pulseaudio or stdenv.isLinux, libpulseaudio , OpenGL, CoreAudio, CoreServices, AudioUnit, Kernel, Cocoa , cf-private }: @@ -10,7 +10,7 @@ # NOTE: When editing this expression see if the same change applies to # SDL2 expression too -with lib; +with stdenv.lib; assert !stdenv.isDarwin -> alsaSupport || pulseaudioSupport; assert openglSupport -> (stdenv.isDarwin || x11Support && libGL != null && libGLU != null); @@ -114,7 +114,7 @@ stdenv.mkDerivation rec { postFixup = '' for lib in $out/lib/*.so* ; do if [[ -L "$lib" ]]; then - patchelf --set-rpath "$(patchelf --print-rpath $lib):${lib.makeLibraryPath propagatedBuildInputs}" "$lib" + patchelf --set-rpath "$(patchelf --print-rpath $lib):${makeLibraryPath propagatedBuildInputs}" "$lib" fi done ''; diff --git a/pkgs/development/libraries/SDL2/default.nix b/pkgs/development/libraries/SDL2/default.nix index 4b358f68a117..242b1b8a3f58 100644 --- a/pkgs/development/libraries/SDL2/default.nix +++ b/pkgs/development/libraries/SDL2/default.nix @@ -1,12 +1,12 @@ -{ stdenv, lib, fetchurl, pkgconfig, pruneLibtoolFiles -, openglSupport ? false, libGL -, alsaSupport ? true, alsaLib -, x11Support ? true, libX11, xproto, libICE, libXi, libXScrnSaver, libXcursor, libXinerama, libXext, libXxf86vm, libXrandr -, waylandSupport ? true, wayland, wayland-protocols, libxkbcommon -, dbusSupport ? false, dbus +{ stdenv, config, libGLSupported, fetchurl, pkgconfig, pruneLibtoolFiles +, openglSupport ? libGLSupported, libGL +, alsaSupport ? stdenv.isLinux, alsaLib +, x11Support ? !stdenv.isCygwin, libX11, xproto, libICE, libXi, libXScrnSaver, libXcursor, libXinerama, libXext, libXxf86vm, libXrandr +, waylandSupport ? stdenv.isLinux, wayland, wayland-protocols, libxkbcommon +, dbusSupport ? stdenv.isLinux, dbus , udevSupport ? false, udev , ibusSupport ? false, ibus -, pulseaudioSupport ? true, libpulseaudio +, pulseaudioSupport ? config.pulseaudio or stdenv.isLinux, libpulseaudio , AudioUnit, Cocoa, CoreAudio, CoreServices, ForceFeedback, OpenGL , audiofile, cf-private, libiconv }: @@ -14,7 +14,7 @@ # NOTE: When editing this expression see if the same change applies to # SDL expression too -with lib; +with stdenv.lib; assert !stdenv.isDarwin -> alsaSupport || pulseaudioSupport; assert openglSupport -> (stdenv.isDarwin || x11Support && libGL != null); diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 0c61e47ce575..07f0bf2bed2a 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -12122,10 +12122,6 @@ with pkgs; schroedinger = callPackage ../development/libraries/schroedinger { }; SDL = callPackage ../development/libraries/SDL { - openglSupport = libGLSupported; - alsaSupport = stdenv.isLinux; - x11Support = !stdenv.isCygwin; - pulseaudioSupport = config.pulseaudio or stdenv.isLinux; inherit (darwin) cf-private; inherit (darwin.apple_sdk.frameworks) OpenGL CoreAudio CoreServices AudioUnit Kernel Cocoa; }; @@ -12147,12 +12143,6 @@ with pkgs; SDL_ttf = callPackage ../development/libraries/SDL_ttf { }; SDL2 = callPackage ../development/libraries/SDL2 { - openglSupport = libGLSupported; - alsaSupport = stdenv.isLinux; - x11Support = !stdenv.isCygwin; - waylandSupport = stdenv.isLinux; - udevSupport = stdenv.isLinux; - pulseaudioSupport = config.pulseaudio or stdenv.isLinux; inherit (darwin) cf-private; inherit (darwin.apple_sdk.frameworks) AudioUnit Cocoa CoreAudio CoreServices ForceFeedback OpenGL; };