about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/xtensor/default.nix
blob: fe978998d6372641e01dc8f96d239f40fa4881b1 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
{ lib
, stdenv
, fetchFromGitHub
, cmake
, gtest
, xsimd
, xtl
}:
stdenv.mkDerivation rec {
  pname = "xtensor";
  version = "0.23.10";

  src = fetchFromGitHub {
    owner = "xtensor-stack";
    repo = "xtensor";
    rev = version;
    sha256 = "1ayrhyh9x33b87ic01b4jzxc8x27yxpxzya5x54ikazvz8p71n14";
  };

  nativeBuildInputs = [ cmake ];
  propagatedBuildInputs = [ xtl xsimd ];

  cmakeFlags = [ "-DBUILD_TESTS=ON" ];

  doCheck = true;
  checkInputs = [ gtest ];
  checkTarget = "xtest";

  meta = with lib; {
    description = "Multi-dimensional arrays with broadcasting and lazy computing.";
    homepage = "https://github.com/xtensor-stack/xtensor";
    license = licenses.bsd3;
    maintainers = with maintainers; [ cpcloud ];
    platforms = platforms.all;
  };
}