7f728ae2e1
On a OSX 10.10 system: libtool: compile: clang++ -DHAVE_CONFIG_H -I. -I../include/IL -I ./../src-IL/include -I ./../include -fgnu89-inline -msse -msse2 -msse3 -D_THREAD_SAFE -I/nix/store/7n9c36hz9sl2dqvfry8d554l935hq4ma-openexr-2.2.0/include/OpenEXR -I/nix/store/3jxslxa37wmfdnyfj1hckpxl0skscgj0-ilmbase-2.2.0/include/OpenEXR -O3 -c ./../src-IL/src/il_exr.cpp -fno-common -DPIC -o .libs/libIL_la-il_exr.o In file included from ./../src-IL/src/il_exr.cpp:22: In file included from ./../src-IL/include/il_exr.h:18: In file included from /nix/store/7n9c36hz9sl2dqvfry8d554l935hq4ma-openexr-2.2.0/include/OpenEXR/ImfIO.h:49: In file included from /nix/store/3qsrpjbsmn7w4d18i8zc6a44myiaa516-libc++-3.5.0/include/c++/v1/string:434: /nix/store/3qsrpjbsmn7w4d18i8zc6a44myiaa516-libc++-3.5.0/include/c++/v1/__config:32:22: error: expected value in expression #if __LITTLE_ENDIAN__ ^ /nix/store/3qsrpjbsmn7w4d18i8zc6a44myiaa516-libc++-3.5.0/include/c++/v1/__config:110:11: fatal error: 'endian.h' file not found # include <endian.h> ^ 2 errors generated. make[1]: *** [libIL_la-il_exr.lo] Error 1 make[1]: Leaving directory `/private/var/folders/1g/yfm550_10sb76p0z469bq9mr5zsthm/T/nix-build-libdevil-1.7.8.drv-1/devil-1.7.8/lib' make: *** [all-recursive] Error 1 See http://sourceforge.net/p/resil/tickets/8/
45 lines
1.3 KiB
Nix
45 lines
1.3 KiB
Nix
{ stdenv, fetchurl, libjpeg, libpng, libmng, lcms1, libtiff, openexr, mesa
|
|
, libX11, pkgconfig }:
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name ="libdevil-${version}";
|
|
version = "1.7.8";
|
|
|
|
src = fetchurl {
|
|
url = "mirror://sourceforge/openil/DevIL-${version}.tar.gz";
|
|
sha256 = "1zd850nn7nvkkhasrv7kn17kzgslr5ry933v6db62s4lr0zzlbv8";
|
|
};
|
|
|
|
buildInputs = [ libjpeg libpng libmng lcms1 libtiff openexr mesa libX11 ];
|
|
nativeBuildInputs = [ pkgconfig ];
|
|
|
|
configureFlags = [ "--enable-ILU" "--enable-ILUT" ];
|
|
|
|
preConfigure = ''
|
|
sed -i 's, -std=gnu99,,g' configure
|
|
sed -i 's,malloc.h,stdlib.h,g' src-ILU/ilur/ilur.c
|
|
'';
|
|
|
|
postConfigure = ''
|
|
sed -i '/RESTRICT_KEYWORD/d' include/IL/config.h
|
|
'';
|
|
|
|
patches =
|
|
[ ( fetchurl {
|
|
url = http://patch-tracker.debian.org/patch/series/dl/devil/1.7.8-6.1/03_CVE-2009-3994.diff;
|
|
sha256 = "0qkx2qfv02igbrmsn6z5a3lbrbwjfh3rb0c2sj54wy0j1f775hbc";
|
|
} )
|
|
./ftbfs-libpng15.patch
|
|
./il_endian.h.patch
|
|
];
|
|
|
|
meta = with stdenv.lib; {
|
|
homepage = http://openil.sourceforge.net/;
|
|
description = "An image library which can can load, save, convert, manipulate, filter and display a wide variety of image formats";
|
|
license = licenses.lgpl2;
|
|
platforms = platforms.mesaPlatforms;
|
|
maintainers = [ maintainers.phreedom maintainers.urkud ];
|
|
};
|
|
}
|