nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 fetchurl,
3 lib,
4 stdenv,
5}:
6
7stdenv.mkDerivation (finalAttrs: {
8 pname = "check";
9 version = "0.15.2";
10
11 src = fetchurl {
12 url = "https://github.com/libcheck/check/releases/download/${finalAttrs.version}/check-${finalAttrs.version}.tar.gz";
13 sha256 = "02m25y9m46pb6n46s51av62kpd936lkfv3b13kfpckgvmh5lxpm8";
14 };
15
16 # fortify breaks the libcompat vsnprintf implementation
17 hardeningDisable = lib.optionals (
18 stdenv.hostPlatform.isMusl && (stdenv.hostPlatform != stdenv.buildPlatform)
19 ) [ "fortify" ];
20
21 # Test can randomly fail: https://hydra.nixos.org/build/7243912
22 doCheck = false;
23
24 meta = {
25 description = "Unit testing framework for C";
26
27 longDescription = ''
28 Check is a unit testing framework for C. It features a simple
29 interface for defining unit tests, putting little in the way of the
30 developer. Tests are run in a separate address space, so Check can
31 catch both assertion failures and code errors that cause
32 segmentation faults or other signals. The output from unit tests
33 can be used within source code editors and IDEs.
34 '';
35
36 homepage = "https://libcheck.github.io/check/";
37
38 license = lib.licenses.lgpl2Plus;
39 mainProgram = "checkmk";
40 platforms = lib.platforms.all;
41 };
42})