on iko/ghcjs-patch-master help sign in
Fixes to help building of all packages in stackage (#1503)
d3ba497Hamish Mackenzie
builder/make-config-files.nix+2−1
@@ -91,7 +91,8 @@ let
91 (map (p: "${lib.getBin p}/bin")
91 (map (p: "${lib.getBin p}/bin")
92 (lib.flatten component.libs ++ lib.concatLists component.pkgconfig));
92 (lib.flatten component.libs ++ lib.concatLists component.pkgconfig));
93 "extra-include-dirs" = map (p: "${lib.getDev p}/include") (lib.flatten component.libs);
93 "extra-include-dirs" = map (p: "${lib.getDev p}/include") (lib.flatten component.libs);
94+ "extra-framework-dirs" = lib.optionals (stdenv.hostPlatform.isDarwin)
94− "extra-framework-dirs" = map (p: "${p}/Library/Frameworks") component.frameworks;
95+ (map (p: "${p}/Library/Frameworks") component.frameworks);
95 })}
96 })}
96
97
97 ghc=${ghc}
98 ghc=${ghc}
lib/pkgconf-nixpkgs-map.nix+3
@@ -47,6 +47,7 @@ pkgs:
47 "gobject-2.0" = [ pkgs."glib" ];
47 "gobject-2.0" = [ pkgs."glib" ];
48 "gmodule-2.0" = [ pkgs."glib" ];
48 "gmodule-2.0" = [ pkgs."glib" ];
49 "gobject-introspection-1.0" = [ pkgs."gobject-introspection" ];
49 "gobject-introspection-1.0" = [ pkgs."gobject-introspection" ];
50+ "graphene-gobject-1.0" = [ pkgs."graphene" ];
50 "gstreamer-audio-0.10" = [ pkgs."gst-plugins-base" ];
51 "gstreamer-audio-0.10" = [ pkgs."gst-plugins-base" ];
51 "gstreamer-audio-1.0" = [ pkgs."gst-plugins-base" ];
52 "gstreamer-audio-1.0" = [ pkgs."gst-plugins-base" ];
52 "gstreamer-base-0.10" = [ pkgs."gst-plugins-base" ];
53 "gstreamer-base-0.10" = [ pkgs."gst-plugins-base" ];
@@ -83,7 +84,9 @@ pkgs:
83 "ldap" = [ pkgs."openldap" ];
84 "ldap" = [ pkgs."openldap" ];
84 "libavutil" = [ pkgs."ffmpeg" ];
85 "libavutil" = [ pkgs."ffmpeg" ];
85 "libcrypto" = [ pkgs."openssl".dev ];
86 "libcrypto" = [ pkgs."openssl".dev ];
87+ "libfreenect" = [ pkgs."freenect" ];
86 "libgsasl" = [ pkgs."gsasl" ];
88 "libgsasl" = [ pkgs."gsasl" ];
89+ "liboath" = [ pkgs."liboauth" ];
87 "libpcre" = [ pkgs."pcre" ];
90 "libpcre" = [ pkgs."pcre" ];
88 "libqrencode" = [ pkgs."qrencode" ];
91 "libqrencode" = [ pkgs."qrencode" ];
89 "libR" = [ pkgs."R" ];
92 "libR" = [ pkgs."R" ];
lib/system-nixpkgs-map.nix+12−1
@@ -27,7 +27,7 @@ in
27 gcc = gcclibs;
27 gcc = gcclibs;
28 ssl = [ openssl ];
28 ssl = [ openssl ];
29 z = [ zlib ];
29 z = [ zlib ];
30− m = null;
30+ m = []; # Included with ghc
31 pcap = [ libpcap ];
31 pcap = [ libpcap ];
32 pthread = null; # available by default
32 pthread = null; # available by default
33 GL = [ libGL ];
33 GL = [ libGL ];
@@ -50,6 +50,7 @@ in
50 util = [ utillinux ];
50 util = [ utillinux ];
51 magic = [ file ];
51 magic = [ file ];
52 pq = [ postgresql ];
52 pq = [ postgresql ];
53+ libpq = [ postgresql ];
53 iconv = [ libiconv ];
54 iconv = [ libiconv ];
54 lapack = [ liblapack ];
55 lapack = [ liblapack ];
55 boost_atomic = [ boost ];
56 boost_atomic = [ boost ];
@@ -102,6 +103,16 @@ in
102 gfortran = [ gfortran.cc.lib ];
103 gfortran = [ gfortran.cc.lib ];
103 ssh2 = [ libssh2 ];
104 ssh2 = [ libssh2 ];
104 gpiod = [ libgpiod ];
105 gpiod = [ libgpiod ];
106+ png = [ libpng ];
107+ jpeg = [ libjpeg ];
108+ freenect_sync = [ freenect ];
109+ FLAC = [ flac ];
110+ mp3lame = [ lame ];
111+ tag_c = [ taglib ];
112+ jwt = [ libjwt ];
113+ GeoIP = [ geoip ];
114+ pulse-simple = [ libpulseaudio ];
115+ oath = [ liboauth ];
105}
116}
106# -- windows
117# -- windows
107// { advapi32 = null; gdi32 = null; imm32 = null; msimg32 = null;
118// { advapi32 = null; gdi32 = null; imm32 = null; msimg32 = null;
modules/configuration-nix.nix+28
@@ -84,4 +84,32 @@ in {
84 # this adds support for __int128_t and __uint128_t to language-c
84 # this adds support for __int128_t and __uint128_t to language-c
85 (fromUntil "0.9.1" "0.9.2" ../patches/languge-c-int128.patch)
85 (fromUntil "0.9.1" "0.9.2" ../patches/languge-c-int128.patch)
86 ];
86 ];
87+
88+ packages.discount.components.library.libs = pkgs.lib.mkForce [ pkgs.discount ];
89+
90+ packages.llvm-hs.components.library.build-tools = pkgs.lib.mkForce [ pkgs.llvm ];
91+
92+ packages.BNFC.components.tests.doctests.build-tools = [
93+ config.hsPkgs.buildPackages.alex
94+ config.hsPkgs.buildPackages.happy
95+ ];
96+
97+ packages.Sit.components.library.build-tools = [
98+ # These may not be in `config.hsPkgs.buildPackages` are not even included
99+ # as dependencies of the Sit package at all.
100+ (pkgs.buildPackages.haskell-nix.tool config.compiler.nix-name "alex" {})
101+ (pkgs.buildPackages.haskell-nix.tool config.compiler.nix-name "happy" {})
102+ ];
103+
104+ packages.bindings-GLFW.components.library.libs = [
105+ pkgs.xorg.libXext
106+ ];
107+
108+ packages.GLFW-b.components.library.libs = [
109+ pkgs.xorg.libXi
110+ ];
111+
112+ packages.closed.components.tests.readme.build-tools = [
113+ config.hsPkgs.buildPackages.markdown-unlit
114+ ];
87}
115}
modules/package.nix+1−1
@@ -351,7 +351,7 @@ in {
351 # (a common use case for `all` is in `shellFor` and it only has an
351 # (a common use case for `all` is in `shellFor` and it only has an
352 # install phase).
352 # install phase).
353 builtins.removeAttrs c ["preCheck" "postCheck" "keepSource"]
353 builtins.removeAttrs c ["preCheck" "postCheck" "keepSource"]
354− ) allComps
354+ ) (lib.filter (c: c.buildable && c.planned) allComps)
355 ) // {
355 ) // {
356 # If any one of the components needs us to keep the source
356 # If any one of the components needs us to keep the source
357 # then keep it for the `all` component
357 # then keep it for the `all` component
overlays/hackage-quirks.nix+8
@@ -25,6 +25,14 @@ in { haskell-nix = prev.haskell-nix // {
25 ];
25 ];
26 };
26 };
27
27
28+ lsp-test = {
29+ cabalProject = ''
30+ packages: .
31+ package lsp
32+ flags: +demo
33+ '';
34+ };
35+
28 pandoc = {
36 pandoc = {
29 # Function that returns a sha256 string by looking up the location
37 # Function that returns a sha256 string by looking up the location
30 # and tag in a nested attrset
38 # and tag in a nested attrset