2007-04-02 16:22:10 +00:00
|
|
|
{stdenv, fetchurl, zlib, libjpeg, libpng, libtiff, pam}:
|
2005-10-21 13:06:08 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation {
|
2007-04-02 16:22:10 +00:00
|
|
|
name = "cups-1.2.10";
|
|
|
|
|
2005-10-21 13:06:08 +00:00
|
|
|
src = fetchurl {
|
2007-04-02 16:22:10 +00:00
|
|
|
url = http://ftp.funet.fi/pub/mirrors/ftp.easysw.com/pub/cups/1.2.10/cups-1.2.10-source.tar.bz2;
|
|
|
|
sha256 = "0dmvjl513kqbb7m4m0b22wa4xvn9avdyihr7fi3n2ly5as93n6v0";
|
2005-10-21 13:06:08 +00:00
|
|
|
};
|
2007-04-02 16:22:10 +00:00
|
|
|
|
|
|
|
buildInputs = [zlib libjpeg libpng libtiff pam];
|
2007-04-02 17:30:11 +00:00
|
|
|
|
|
|
|
preConfigure = "
|
|
|
|
configureFlags=\"--localstatedir=/var\"
|
|
|
|
";
|
|
|
|
|
2007-04-02 16:22:10 +00:00
|
|
|
preBuild = "
|
|
|
|
makeFlagsArray=(INITDIR=$out/etc/rc.d)
|
|
|
|
";
|
2007-04-02 17:30:11 +00:00
|
|
|
|
|
|
|
# Awful hack: CUPS' `make install' wants to write in /var, but it
|
|
|
|
# can't. So redirect it with a BUILDROOT (=DESTDIR).
|
|
|
|
preInstall = "
|
|
|
|
installFlagsArray=(BUILDROOT=$out/destdir)
|
|
|
|
";
|
|
|
|
|
|
|
|
postInstall = "
|
|
|
|
mv $out/destdir/$out/* $out
|
|
|
|
rm -rf $out/destdir
|
|
|
|
";
|
2005-10-21 13:06:08 +00:00
|
|
|
}
|