uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
59
pkgs/development/libraries/libdevil/default.nix
Normal file
59
pkgs/development/libraries/libdevil/default.nix
Normal file
|
|
@ -0,0 +1,59 @@
|
|||
{ lib, stdenv, fetchurl, libjpeg, libpng, libmng, lcms1, libtiff, openexr, libGL
|
||||
, libX11, pkg-config, OpenGL
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
|
||||
pname = "libdevil";
|
||||
version = "1.7.8";
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/openil/DevIL-${version}.tar.gz";
|
||||
sha256 = "1zd850nn7nvkkhasrv7kn17kzgslr5ry933v6db62s4lr0zzlbv8";
|
||||
};
|
||||
|
||||
outputs = [ "out" "dev" ];
|
||||
|
||||
buildInputs = [ libjpeg libpng libmng lcms1 libtiff openexr libGL libX11 ]
|
||||
++ lib.optionals stdenv.isDarwin [ OpenGL ];
|
||||
nativeBuildInputs = [ pkg-config ];
|
||||
|
||||
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
|
||||
'' + lib.optionalString stdenv.cc.isClang ''
|
||||
sed -i 's/libIL_la_CXXFLAGS = $(AM_CFLAGS)/libIL_la_CXXFLAGS =/g' lib/Makefile.in
|
||||
'';
|
||||
|
||||
postConfigure = ''
|
||||
sed -i '/RESTRICT_KEYWORD/d' include/IL/config.h
|
||||
'';
|
||||
|
||||
patches =
|
||||
[ ( fetchurl {
|
||||
url = "https://sources.debian.org/data/main/d/devil/1.7.8-10/debian/patches/03_CVE-2009-3994.diff";
|
||||
sha256 = "0qkx2qfv02igbrmsn6z5a3lbrbwjfh3rb0c2sj54wy0j1f775hbc";
|
||||
} )
|
||||
./ftbfs-libpng15.patch
|
||||
./il_endian.h.patch
|
||||
];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
postPatch = ''
|
||||
for a in test/Makefile.in test/format_test/format_checks.sh.in ; do
|
||||
substituteInPlace $a \
|
||||
--replace /bin/bash ${stdenv.shell}
|
||||
done
|
||||
'';
|
||||
|
||||
meta = with 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 = [ ];
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue