2011-10-13 12:37:15 +00:00
|
|
|
{ stdenv, fetchurl, which, autoconf, automake, flex, yacc,
|
2013-03-24 11:45:00 +00:00
|
|
|
kernelDev, glibc, ncurses, perl, krb5 }:
|
2009-11-10 16:00:52 +00:00
|
|
|
|
|
|
|
assert stdenv.isLinux;
|
|
|
|
|
2011-10-13 12:37:15 +00:00
|
|
|
stdenv.mkDerivation {
|
2013-03-24 11:45:00 +00:00
|
|
|
name = "openafs-1.6.1-${kernelDev.version}";
|
2009-11-10 16:00:52 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2012-05-15 17:31:53 +00:00
|
|
|
url = http://www.openafs.org/dl/openafs/1.6.1/openafs-1.6.1-src.tar.bz2;
|
2012-05-15 19:36:39 +00:00
|
|
|
sha256 = "1c7mid0dwl2x0sikr70bi5cs881y6pa4dfwkdmr3jscvx3wgfpnh";
|
2009-11-10 16:00:52 +00:00
|
|
|
};
|
|
|
|
|
2011-10-13 12:37:15 +00:00
|
|
|
buildInputs = [ autoconf automake flex yacc ncurses perl which ];
|
2009-11-10 16:00:52 +00:00
|
|
|
|
2011-10-13 12:37:15 +00:00
|
|
|
preConfigure = ''
|
2013-03-24 11:45:00 +00:00
|
|
|
ln -s ${kernelDev}/lib/modules/*/build $TMP/linux
|
2009-11-10 16:00:52 +00:00
|
|
|
|
2011-10-13 12:37:15 +00:00
|
|
|
patchShebangs .
|
|
|
|
for i in `grep -l -R '/usr/\(include\|src\)' .`; do
|
|
|
|
echo "Patch /usr/include and /usr/src in $i"
|
|
|
|
substituteInPlace $i \
|
|
|
|
--replace "/usr/include" "${glibc}/include" \
|
|
|
|
--replace "/usr/src" "$TMP"
|
2009-11-10 16:00:52 +00:00
|
|
|
done
|
|
|
|
|
|
|
|
./regen.sh
|
|
|
|
|
2011-10-13 12:37:15 +00:00
|
|
|
export KRB5_CONFIG=${krb5}/bin/krb5-config
|
2009-11-10 16:00:52 +00:00
|
|
|
|
2011-10-13 12:37:15 +00:00
|
|
|
configureFlagsArray=(
|
|
|
|
"--with-linux-kernel-build=$TMP/linux"
|
|
|
|
"--with-krb5"
|
|
|
|
"--sysconfdir=/etc/static"
|
|
|
|
)
|
2009-11-10 16:00:52 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
2011-10-13 12:37:15 +00:00
|
|
|
description = "Open AFS client";
|
|
|
|
homepage = http://www.openafs.org;
|
|
|
|
license = stdenv.lib.licenses.ipl10;
|
|
|
|
platforms = stdenv.lib.platforms.linux;
|
2013-11-04 20:07:57 +00:00
|
|
|
maintainers = stdenv.lib.maintainers.z77z;
|
|
|
|
broken = true;
|
2009-11-10 16:00:52 +00:00
|
|
|
};
|
|
|
|
}
|