Skip to content

Commit

Permalink
nix: add stdenvAdapters
Browse files Browse the repository at this point in the history
  • Loading branch information
fufexan committed Nov 5, 2024
1 parent 8d732fa commit 536d7d0
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions nix/default.nix
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
lib,
stdenv,
stdenvAdapters,
cmake,
hwdata,
hyprutils,
Expand All @@ -20,8 +21,19 @@
wayland-scanner,
version ? "git",
doCheck ? false,
}:
stdenv.mkDerivation {
debug ? false,
}: let
inherit (builtins) foldl';
inherit (lib.lists) flatten;

adapters = flatten [
stdenvAdapters.useMoldLinker
(lib.optional debug stdenvAdapters.keepDebugInfo)
];

customStdenv = foldl' (acc: adapter: adapter acc) stdenv adapters;
in
customStdenv.mkDerivation {
pname = "aquamarine";
inherit version doCheck;
src = ../.;
Expand Down

0 comments on commit 536d7d0

Please sign in to comment.