From 271926d00dbac878bd2105c1d6e191b3298f138e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benno=20F=C3=BCnfst=C3=BCck?= Date: Wed, 26 Aug 2015 16:20:21 +0200 Subject: [PATCH] haskell: fix build of SDL-* libraries --- .../haskell-modules/configuration-common.nix | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/pkgs/development/haskell-modules/configuration-common.nix b/pkgs/development/haskell-modules/configuration-common.nix index ba5f2a68f12..10e665b70a2 100644 --- a/pkgs/development/haskell-modules/configuration-common.nix +++ b/pkgs/development/haskell-modules/configuration-common.nix @@ -973,4 +973,23 @@ self: super: { hackage-security = dontDistribute super.hackage-security; hackage-security-HTTP = dontDistribute super.hackage-security-HTTP; + # The cabal files for these libraries do not list the required system dependencies. + SDL-image = overrideCabal super.SDL-image (drv: { + librarySystemDepends = [ pkgs.SDL pkgs.SDL_image ] ++ drv.librarySystemDepends or []; + }); + SDL-ttf = overrideCabal super.SDL-ttf (drv: { + librarySystemDepends = [ pkgs.SDL pkgs.SDL_ttf ]; + }); + SDL-mixer = overrideCabal super.SDL-mixer (drv: { + librarySystemDepends = [ pkgs.SDL pkgs.SDL_mixer ]; + }); + SDL-gfx = overrideCabal super.SDL-gfx (drv: { + librarySystemDepends = [ pkgs.SDL pkgs.SDL_gfx ]; + }); + SDL-mpeg = overrideCabal super.SDL-mpeg (drv: { + configureFlags = (drv.configureFlags or []) ++ [ + "--extra-lib-dirs=${pkgs.smpeg}/lib" + "--extra-include-dirs=${pkgs.smpeg}/include/smpeg" + ]; + }); }