2021-04-19 11:39:19 +01:00
|
|
|
{ lib, stdenv, fetchFromGitHub, fetchpatch, cmake }:
|
2015-05-25 09:38:42 +01:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 13:41:18 +01:00
|
|
|
pname = "catch";
|
2018-11-11 16:28:04 +00:00
|
|
|
version = "1.12.2";
|
2015-05-25 09:38:42 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
2017-11-17 22:10:19 +00:00
|
|
|
owner = "catchorg";
|
2015-05-25 09:38:42 +01:00
|
|
|
repo = "Catch";
|
2017-06-17 16:21:50 +01:00
|
|
|
rev = "v${version}";
|
2018-11-11 16:28:04 +00:00
|
|
|
sha256 = "1gdp5wm8khn02g2miz381llw3191k7309qj8s3jd6sasj01rhf23";
|
2015-05-25 09:38:42 +01:00
|
|
|
};
|
|
|
|
|
2017-06-17 16:21:50 +01:00
|
|
|
nativeBuildInputs = [ cmake ];
|
2017-02-02 19:47:01 +00:00
|
|
|
cmakeFlags = [ "-DUSE_CPP14=ON" ];
|
2015-05-25 09:38:42 +01:00
|
|
|
|
2021-04-19 11:39:19 +01:00
|
|
|
patches = [
|
|
|
|
# https://github.com/catchorg/Catch2/pull/2151
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/catchorg/Catch2/commit/bb6d08323f23a39eb65dd86671e68f4f5d3f2d6c.patch";
|
|
|
|
sha256 = "1vhbzx84nrhhf9zlbl6h5zmg3r5w5v833ihlswsysb9wp2i4isc5";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2017-02-02 19:47:01 +00:00
|
|
|
doCheck = true;
|
|
|
|
checkTarget = "test";
|
2015-05-25 09:38:42 +01:00
|
|
|
|
2021-01-21 17:00:13 +00:00
|
|
|
meta = with lib; {
|
2015-05-25 09:38:42 +01:00
|
|
|
description = "A multi-paradigm automated test framework for C++ and Objective-C (and, maybe, C)";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "http://catch-lib.net";
|
2015-05-25 09:38:42 +01:00
|
|
|
license = licenses.boost;
|
2017-02-02 19:47:01 +00:00
|
|
|
maintainers = with maintainers; [ edwtjo knedlsepp ];
|
2016-08-02 18:50:55 +01:00
|
|
|
platforms = with platforms; unix;
|
2015-05-25 09:38:42 +01:00
|
|
|
};
|
|
|
|
}
|