diff --git a/flake.nix b/flake.nix index dec9bb2..6c3618c 100644 --- a/flake.nix +++ b/flake.nix @@ -22,7 +22,7 @@ # list directory contents as absolute paths lsAbsolute = with builtins; path: - map (name: toPath path + toPath name) (attrNames (readDir path)); + map (name: (toPath path) + "/" + name) (attrNames (readDir path)); in { overlays.default = final: prev: { dorne = final.haskellPackages.developPackage { @@ -47,6 +47,7 @@ # C Dependencies pipewire + pipewire.dev # Language/Development Tooling clang-tools @@ -58,9 +59,24 @@ shell = "${pkgs.bash}/bin/bash"; # SPA API is provided by pipewire's "dev" derivation output - C_INCLUDE_PATH = - builtins.concatStringSep ":" - (lsAbsolute "${pkgs.pipewire.dev}/include"); + NIX_CFLAGS_COMPILE = let + # libpipewire (and libspa) + Ipipewire = + lsAbsolute "${pkgs.pipewire.dev}/include"; + + Ivendor = + builtins.map + (x: "-isystem ${x}") + Ipipewire; + in + builtins.concatStringsSep " " ([ + (builtins.getEnv + "NIX_CFLAGS_COMPILE") + ] + ++ Ivendor); + + DORNE_LDFLAGS = let + in "-L${pkgs.pipewire}/lib"; }; } );