diff --git a/pkgs/tools/package-management/lix/common.nix b/pkgs/tools/package-management/lix/common.nix index 2970b421fd5f..d39ddeda3ab2 100644 --- a/pkgs/tools/package-management/lix/common.nix +++ b/pkgs/tools/package-management/lix/common.nix @@ -190,7 +190,7 @@ stdenv.mkDerivation { [ # Enable LTO, since it improves eval performance a fair amount # LTO is disabled on static due to strange linking errors - (lib.mesonBool "b_lto" (!stdenv.hostPlatform.isStatic)) + (lib.mesonBool "b_lto" (!stdenv.hostPlatform.isStatic && stdenv.cc.isGNU)) (lib.mesonEnable "gc" true) (lib.mesonBool "enable-tests" true) (lib.mesonBool "enable-docs" enableDocumentation)