10 stdenv.mkDerivation (finalAttrs: {
14 src = fetchFromGitHub {
17 rev = "v${finalAttrs.version}";
18 hash = "sha256-mrpkWIb6kfLvppmIfzhjF1/3m1zSd8XG1D07V6Zjlu0=";
21 # Avoid downloading googletest: we already have it.
23 substituteInPlace CMakeLists.txt --replace-fail \
24 "FetchContent_MakeAvailable(googletest)" \
25 "add_subdirectory(${gtest.src} googletest SYSTEM)"
29 # Remove installed tests and googletest stuff
30 rm -rf $out/bin $out/include/gmock $out/include/gtest $out/lib
33 nativeBuildInputs = [ cmake ];
34 propagatedBuildInputs = [ eigen ];
35 checkInputs = [ gtest ];
39 cmakeFlags = [ "-DCMAKE_CTEST_ARGUMENTS=--exclude-regex;EigenRand-test" ];
42 description = "Fastest Random Distribution Generator for Eigen";
43 homepage = "https://github.com/bab2min/EigenRand";
44 license = lib.licenses.mit;
45 maintainers = with lib.maintainers; [ nim65s ];
46 platforms = lib.platforms.unix;