Skip to content

Commit ea6035d

Browse files
committed
fix coverage build
1 parent b08bdf3 commit ea6035d

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

flake.nix

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,16 @@
4444
};
4545

4646
coverage =
47-
pkgs.releaseTools.coverageAnalysis {
47+
(pkgs.releaseTools.coverageAnalysis {
4848
name = "patchelf-coverage";
4949
src = self.hydraJobs.tarball;
5050
lcovFilter = ["*/tests/*"];
51-
};
51+
}).overrideAttrs (old: {
52+
preCheck = ''
53+
# coverage cflag breaks this target
54+
NIX_CFLAGS_COMPILE=''${NIX_CFLAGS_COMPILE//--coverage} make -C tests phdr-corruption.so
55+
'';
56+
});
5257

5358
build = forAllSystems (system: nixpkgsFor.${system}.patchelf-new);
5459
build-sanitized = forAllSystems (system: nixpkgsFor.${system}.patchelf-new.overrideAttrs (old: {

0 commit comments

Comments
 (0)