1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-23 14:11:36 +00:00
nixpkgs/pkgs/os-specific/linux/upstart/default.nix
Eelco Dolstra 7d2b8fe48f * Upstart 1.5.
svn path=/nixpkgs/trunk/; revision=33615
2012-04-05 12:24:08 +00:00

43 lines
1.2 KiB
Nix

{ stdenv, fetchurl, pkgconfig, dbus, libnih }:
let version = "1.5"; in
stdenv.mkDerivation rec {
name = "upstart-${version}";
src = fetchurl {
url = "http://upstart.ubuntu.com/download/${version}/${name}.tar.gz";
md5 = "870920a75f8c13f3a3af4c35916805ac";
};
buildInputs = [ pkgconfig dbus libnih ];
NIX_CFLAGS_COMPILE =
''
-DSHELL="${stdenv.shell}"
-DCONFFILE="/etc/init.conf"
-DCONFDIR="/etc/init"
-DPATH="/no-path"
'';
# The interface version prevents NixOS from switching to an
# incompatible Upstart at runtime. (Switching across reboots is
# fine, of course.) It should be increased whenever Upstart changes
# in a backwards-incompatible way. If the interface version of two
# Upstart builds is the same, then we can switch between them at
# runtime; otherwise we can't and we need to reboot.
passthru.interfaceVersion = 2;
postInstall =
''
t=$out/etc/bash_completion.d
mkdir -p $t
cp ${./upstart-bash-completion} $t/upstart
'';
meta = {
homepage = "http://upstart.ubuntu.com/";
description = "An event-based replacement for the /sbin/init daemon";
};
}