2015-09-18 03:57:51 +01:00
|
|
|
{ stdenv, fetchurl, flex, bison, linuxHeaders }:
|
2010-06-12 11:22:09 +01:00
|
|
|
|
2009-04-30 03:37:00 +01:00
|
|
|
let
|
2015-09-18 03:57:51 +01:00
|
|
|
version = "5.1.1";
|
|
|
|
name = "autofs-${version}";
|
|
|
|
in stdenv.mkDerivation {
|
|
|
|
inherit name;
|
2010-06-12 11:22:09 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
2015-09-18 03:57:51 +01:00
|
|
|
url = "mirror://kernel/linux/daemons/autofs/v5/${name}.tar.xz";
|
|
|
|
sha256 = "1hr1f11wp538h7r298wpa5khfkhfs8va3p1kdixxhrgkkzpz13z0";
|
2010-06-12 11:22:09 +01:00
|
|
|
};
|
2009-04-30 03:37:00 +01:00
|
|
|
|
|
|
|
preConfigure = ''
|
2013-10-30 21:04:25 +00:00
|
|
|
configureFlags="--disable-move-mount --with-path=$PATH"
|
2009-04-30 03:37:00 +01:00
|
|
|
export MOUNT=/var/run/current-system/sw/bin/mount
|
2009-05-01 06:42:32 +01:00
|
|
|
export UMOUNT=/var/run/current-system/sw/bin/umount
|
2015-04-01 21:57:06 +01:00
|
|
|
export MODPROBE=/var/run/current-system/sw/bin/modprobe
|
2009-04-30 03:37:00 +01:00
|
|
|
# Grrr, rpcgen can't find cpp. (NIXPKGS-48)
|
|
|
|
mkdir rpcgen
|
|
|
|
echo "#! $shell" > rpcgen/rpcgen
|
|
|
|
echo "exec $(type -tp rpcgen) -Y $(dirname $(type -tp cpp)) \"\$@\"" >> rpcgen/rpcgen
|
|
|
|
chmod +x rpcgen/rpcgen
|
|
|
|
export RPCGEN=$(pwd)/rpcgen/rpcgen
|
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
make install SUBDIRS="lib daemon modules man" # all but samples
|
|
|
|
#make install SUBDIRS="samples" # impure!
|
|
|
|
'';
|
|
|
|
|
2015-09-18 03:57:51 +01:00
|
|
|
buildInputs = [ flex bison linuxHeaders ];
|
2009-04-30 03:37:00 +01:00
|
|
|
|
2015-09-18 03:57:51 +01:00
|
|
|
meta = {
|
|
|
|
inherit version;
|
|
|
|
description = "Kernel-based automounter";
|
|
|
|
homepage = http://www.linux-consulting.com/Amd_AutoFS/autofs.html;
|
2014-06-19 05:19:00 +01:00
|
|
|
license = stdenv.lib.licenses.gpl2;
|
2009-04-30 03:37:00 +01:00
|
|
|
executables = [ "automount" ];
|
2016-08-02 18:50:55 +01:00
|
|
|
platforms = stdenv.lib.platforms.linux;
|
2009-04-30 03:37:00 +01:00
|
|
|
};
|
|
|
|
}
|