Something went wrong. Try again.
What happens if I push all of nixpkgs
Something went wrong. Try again.
1.7 kB · 73 lines
Nix
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374{ lib, stdenv, fetchFromGitHub, cmake, imath, libdeflate, pkg-config, libjxl, pkgsCross,}:
stdenv.mkDerivation rec { pname = "openexr"; version = "3.3.4";
src = fetchFromGitHub { owner = "AcademySoftwareFoundation"; repo = "openexr"; rev = "v${version}"; hash = "sha256-dPPL9ML5O/u0FXuLxE3bkkgetOzNU3qni3n0pq25bT0="; };
outputs = [ "bin" "dev" "out" "doc" ];
patches = # Disable broken test on musl libc # https://github.com/AcademySoftwareFoundation/openexr/issues/1556 lib.optional stdenv.hostPlatform.isMusl ./disable-iex-test.patch;
# tests are determined to use /var/tmp on unix postPatch = '' cat <(find . -name tmpDir.h) <(echo src/test/OpenEXRCoreTest/main.cpp) | while read -r f ; do substituteInPlace $f --replace '/var/tmp' "$TMPDIR" done '';
cmakeFlags = lib.optional stdenv.hostPlatform.isStatic "-DCMAKE_SKIP_RPATH=ON";
nativeBuildInputs = [ cmake pkg-config ]; propagatedBuildInputs = [ imath libdeflate ];
# Without 'sse' enforcement tests fail on i686 as due to excessive precision as: # error reading back channel B pixel 21,-76 got -nan expected -nan env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.hostPlatform.isi686 "-msse2 -mfpmath=sse";
# https://github.com/AcademySoftwareFoundation/openexr/issues/1400 doCheck = !stdenv.hostPlatform.isAarch32;
passthru.tests = { inherit libjxl; musl = pkgsCross.musl64.openexr; };
meta = with lib; { description = "High dynamic-range (HDR) image file format"; homepage = "https://www.openexr.com"; license = licenses.bsd3; maintainers = with maintainers; [ paperdigits ]; platforms = platforms.all; };}