python3Packages.orjson: Disable failing tests on 32 bit
[NixPkgs.git] / pkgs / development / libraries / openexr / default.nix
blobba0263bcad13b0722b4a08aa4a3dfa7a24617edf
1 { lib
2 , stdenv
3 , fetchFromGitHub
4 , zlib
5 , ilmbase
6 , fetchpatch
7 , cmake
8 }:
10 stdenv.mkDerivation rec {
11   pname = "openexr";
12   version = "2.5.8";
14   outputs = [ "bin" "dev" "out" "doc" ];
16   src = fetchFromGitHub {
17     owner = "AcademySoftwareFoundation";
18     repo = "openexr";
19     rev = "v${version}";
20     sha256 = "sha256-N7XdDaDsYdx4TXvHplQDTvhHNUmW5rntdaTKua4C0es=";
21   };
23   patches = [
24     (fetchpatch {
25       name = "CVE-2021-45942.patch";
26       url = "https://github.com/AcademySoftwareFoundation/openexr/commit/11cad77da87c4fa2aab7d58dd5339e254db7937e.patch";
27       stripLen = 4;
28       extraPrefix = "OpenEXR/IlmImf/";
29       sha256 = "1wa2jn6sa0n3phaqvklnlbgk1bz60y756ad4jk4d757pzpnannsy";
30     })
31   ];
33   cmakeFlags = lib.optional stdenv.hostPlatform.isStatic "-DCMAKE_SKIP_RPATH=ON";
35   nativeBuildInputs = [ cmake ];
36   propagatedBuildInputs = [ ilmbase zlib ];
38   meta = with lib; {
39     description = "A high dynamic-range (HDR) image file format";
40     homepage = "https://www.openexr.com/";
41     license = licenses.bsd3;
42     platforms = platforms.all;
43   };