nixpkgs/pkgs/tools/system/at/default.nix

42 lines
1.1 KiB
Nix
Raw Normal View History

{ fetchurl, stdenv, bison, flex, pam, ssmtp }:
stdenv.mkDerivation {
2014-09-06 17:04:08 +00:00
name = "at-3.1.15";
src = fetchurl {
# Debian is apparently the last location where it can be found.
2014-09-06 17:04:08 +00:00
url = mirror://debian/pool/main/a/at/at_3.1.15.orig.tar.gz;
sha256 = "1z7pgglr0zmwapb4sc1bdb3z0hgig1asyzqv4gs5xafmjd94za03";
};
patches = [ ./install.patch ];
buildInputs =
[ bison flex pam
# `configure' and `atd' want the `sendmail' command.
ssmtp
];
preConfigure =
''
export PATH="${ssmtp}/sbin:$PATH"
# Purity: force atd.pid to be placed in /var/run regardless of
# whether it exists now.
substituteInPlace ./configure --replace "test -d /var/run" "true"
'';
configureFlags =
''
--with-etcdir=/etc/at
--with-jobdir=/var/spool/atjobs --with-atspool=/var/spool/atspool
--with-daemon_username=atd --with-daemon_groupname=atd
'';
meta = {
description = ''The classical Unix `at' job scheduling command'';
license = stdenv.lib.licenses.gpl2Plus;
homepage = http://packages.qa.debian.org/at;
};
}