libpng: force-declare feenableexcept on FreeBSD

This commit is contained in:
Audrey Dutcher 2024-06-17 01:30:34 -07:00
parent bd8d034e65
commit e05182c4e8

View File

@ -20,7 +20,11 @@ in stdenv.mkDerivation (finalAttrs: {
url = "mirror://sourceforge/libpng/libpng-${finalAttrs.version}.tar.xz";
hash = "sha256-alygZSOSotfJ2yrltAIQhDwLvAgcvUEIJasAzFnxSmw=";
};
postPatch = whenPatched "gunzip < ${patch_src} | patch -Np1";
postPatch = whenPatched "gunzip < ${patch_src} | patch -Np1"
+ lib.optionalString stdenv.isFreeBSD ''
sed -i 1i'int feenableexcept(int __mask);' contrib/libtests/pngvalid.c
'';
outputs = [ "out" "dev" "man" ];
outputBin = "dev";