2012-05-22 16:30:12 +02:00
|
|
|
{stdenv, fetchurl, which, libjpeg
|
|
|
|
, withQt4 ? false, qt4 ? null}:
|
2011-08-13 10:59:00 +02:00
|
|
|
|
2012-05-22 16:30:12 +02:00
|
|
|
assert withQt4 -> qt4 != null;
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2012-12-21 11:58:31 +01:00
|
|
|
name = "v4l-utils-0.9.3";
|
2012-05-22 16:30:12 +02:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://linuxtv.org/downloads/v4l-utils/${name}.tar.bz2";
|
2012-12-21 11:58:31 +01:00
|
|
|
sha256 = "0gaag38x47wlvmp4j60wgf9ma1rxzfyg7i12zxxxi4m3cpcb0bah";
|
2011-08-13 10:59:00 +02:00
|
|
|
};
|
|
|
|
|
2012-05-22 16:30:12 +02:00
|
|
|
buildInputs = [ libjpeg which ] ++ stdenv.lib.optional withQt4 qt4;
|
2011-08-13 10:59:00 +02:00
|
|
|
|
2012-05-22 16:30:12 +02:00
|
|
|
# The keytable wants to touch /etc files and udev scripts in /lib.
|
|
|
|
# I skip it.
|
|
|
|
patchPhase = ''
|
2012-12-21 11:58:31 +01:00
|
|
|
sed -i s/keytable// utils/Makefile.in
|
2012-05-22 16:30:12 +02:00
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
make PREFIX=$out install
|
|
|
|
'';
|
2011-08-13 10:59:00 +02:00
|
|
|
|
|
|
|
meta = {
|
2012-05-22 16:30:12 +02:00
|
|
|
homepage = http://linuxtv.org/projects.php;
|
|
|
|
description = "V4L utils and libv4l, that provides common image formats regardless of the v4l device";
|
|
|
|
# (The libs are of LGPLv2.1+, some other pieces are GPL)
|
|
|
|
license = "free";
|
|
|
|
maintainers = with stdenv.lib.maintainers; [viric];
|
|
|
|
platforms = with stdenv.lib.platforms; linux;
|
2011-08-13 10:59:00 +02:00
|
|
|
};
|
2012-05-22 16:30:12 +02:00
|
|
|
}
|