suid-chroot 1.0.1 -> 1.0.2 (and refactor)

More of a conversion excercise than anything, but here you go.
This commit is contained in:
Tobias Geerinckx-Rice 2015-04-22 22:11:31 +02:00
parent 1adb482638
commit b7135f496e
2 changed files with 15 additions and 27 deletions

View File

@ -1,34 +1,22 @@
a :
let
fetchurl = a.fetchurl;
{ stdenv, fetchurl }:
let version = "1.0.2"; in
stdenv.mkDerivation rec {
name = "suid-chroot-${version}";
version = a.lib.attrByPath ["version"] "1.0.1" a;
buildInputs = with a; [
];
in
rec {
src = fetchurl {
url = "http://myweb.tiscali.co.uk/scottrix/linux/download/suid-chroot-${version}.tar.bz2";
sha256 = "15gs09md4lyym47ipzffm1ws8jkg028x0cgwxxs9qkdqbl5zb777";
sha256 = "1a9xqhck0ikn8kfjk338h9v1yjn113gd83q0c50k78xa68xrnxjx";
url = "http://myweb.tiscali.co.uk/scottrix/linux/download/${name}.tar.bz2";
};
inherit buildInputs;
configureFlags = [];
postPatch = ''
substituteInPlace Makefile --replace /usr $out
'';
/* doConfigure should be removed if not needed */
phaseNames = ["replacePaths" "doMakeInstall"];
installFlags = "PREFIX=$out";
replacePaths = a.fullDepEntry (''
sed -e "s@/usr/@$out/@g" -i Makefile
'') ["minInit" "doUnpack"];
name = "suid-chroot-" + version;
meta = {
meta = with stdenv.lib; {
inherit version;
description = "Setuid-safe wrapper for chroot";
maintainers = [
];
license = with licenses; gpl2Plus;
maintainers = with maintainers; [ nckx ];
};
}

View File

@ -2769,7 +2769,7 @@ let
sudo = callPackage ../tools/security/sudo { };
suidChroot = builderDefsPackage (import ../tools/system/suid-chroot) { };
suidChroot = callPackage ../tools/system/suid-chroot { };
super = callPackage ../tools/security/super { };