2008-11-07 13:36:57 +00:00
|
|
|
{stdenv, fetchurl, zlib, libjpeg, libpng, libtiff, pam, openssl}:
|
2005-10-21 14:06:08 +01:00
|
|
|
|
2009-05-06 15:05:32 +01:00
|
|
|
let version = "1.3.10"; in
|
|
|
|
|
2005-10-21 14:06:08 +01:00
|
|
|
stdenv.mkDerivation {
|
2009-05-06 15:05:32 +01:00
|
|
|
name = "cups-${version}";
|
2007-04-02 17:22:10 +01:00
|
|
|
|
2005-10-21 14:06:08 +01:00
|
|
|
src = fetchurl {
|
2009-05-06 15:05:32 +01:00
|
|
|
url = "http://ftp.easysw.com/pub/cups/${version}/cups-${version}-source.tar.bz2";
|
|
|
|
sha256 = "0rmm1dj8ha8d5c9lpdsfpfyw6l6lnkxl36xlxqdrjnm0lr2sa0cp";
|
2005-10-21 14:06:08 +01:00
|
|
|
};
|
2007-04-02 17:22:10 +01:00
|
|
|
|
2008-11-07 13:36:57 +00:00
|
|
|
buildInputs = [zlib libjpeg libpng libtiff pam openssl];
|
2007-04-02 18:30:11 +01:00
|
|
|
|
2008-11-07 13:36:57 +00:00
|
|
|
preConfigure = ''
|
|
|
|
configureFlags="--localstatedir=/var"
|
|
|
|
'';
|
2007-04-02 18:30:11 +01:00
|
|
|
|
2008-11-07 13:36:57 +00:00
|
|
|
preBuild = ''
|
2007-04-02 17:22:10 +01:00
|
|
|
makeFlagsArray=(INITDIR=$out/etc/rc.d)
|
2008-11-07 13:36:57 +00:00
|
|
|
'';
|
2007-04-02 18:30:11 +01:00
|
|
|
|
|
|
|
# Awful hack: CUPS' `make install' wants to write in /var, but it
|
|
|
|
# can't. So redirect it with a BUILDROOT (=DESTDIR).
|
2008-11-07 13:36:57 +00:00
|
|
|
preInstall = ''
|
2007-04-02 18:30:11 +01:00
|
|
|
installFlagsArray=(BUILDROOT=$out/destdir)
|
2008-11-07 13:36:57 +00:00
|
|
|
'';
|
2007-04-02 18:30:11 +01:00
|
|
|
|
2008-11-07 13:36:57 +00:00
|
|
|
postInstall = ''
|
2007-04-02 18:30:11 +01:00
|
|
|
mv $out/destdir/$out/* $out
|
|
|
|
rm -rf $out/destdir
|
2008-11-07 13:36:57 +00:00
|
|
|
''; # */
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
homepage = http://www.cups.org/;
|
|
|
|
description = "A standards-based printing system for UNIX";
|
|
|
|
};
|
2005-10-21 14:06:08 +01:00
|
|
|
}
|