2021-01-11 08:54:33 +01:00
|
|
|
{ lib, stdenv, fetchurl
|
2021-01-17 04:51:22 +01:00
|
|
|
, pkg-config, makeWrapper, autoreconfHook
|
2018-12-21 10:22:20 +01:00
|
|
|
, openldap, python, pam
|
|
|
|
}:
|
2012-09-14 00:06:25 +02:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 14:41:18 +02:00
|
|
|
pname = "nss-pam-ldapd";
|
2019-10-17 03:55:35 +02:00
|
|
|
version = "0.9.11";
|
2018-12-21 10:22:20 +01:00
|
|
|
|
2012-09-14 00:06:25 +02:00
|
|
|
src = fetchurl {
|
2019-08-15 14:41:18 +02:00
|
|
|
url = "https://arthurdejong.org/nss-pam-ldapd/${pname}-${version}.tar.gz";
|
2019-10-17 03:55:35 +02:00
|
|
|
sha256 = "1dna3r0q6sjhhlkhcp8x2zkslrd4y7701kk6fl5r940sdph1pmyh";
|
2012-09-14 00:06:25 +02:00
|
|
|
};
|
2018-12-21 10:22:20 +01:00
|
|
|
|
2021-01-17 04:51:22 +01:00
|
|
|
nativeBuildInputs = [ pkg-config makeWrapper autoreconfHook ];
|
2018-12-21 10:22:20 +01:00
|
|
|
buildInputs = [ openldap pam python ];
|
2012-09-14 00:06:25 +02:00
|
|
|
|
|
|
|
preConfigure = ''
|
|
|
|
substituteInPlace Makefile.in --replace "install-data-local: " "# install-data-local: "
|
|
|
|
'';
|
|
|
|
|
|
|
|
configureFlags = [
|
|
|
|
"--with-bindpw-file=/run/nslcd/bindpw"
|
|
|
|
"--with-nslcd-socket=/run/nslcd/socket"
|
|
|
|
"--with-nslcd-pidfile=/run/nslcd/nslcd.pid"
|
|
|
|
"--with-pam-seclib-dir=$(out)/lib/security"
|
2018-12-21 10:22:20 +01:00
|
|
|
"--enable-kerberos=no"
|
2012-09-14 00:06:25 +02:00
|
|
|
];
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
wrapProgram $out/sbin/nslcd --prefix LD_LIBRARY_PATH ":" $out/lib
|
|
|
|
'';
|
|
|
|
|
2021-01-11 08:54:33 +01:00
|
|
|
meta = with lib; {
|
2012-09-14 00:06:25 +02:00
|
|
|
description = "LDAP identity and authentication for NSS/PAM";
|
2020-04-01 03:11:51 +02:00
|
|
|
homepage = "https://arthurdejong.org/nss-pam-ldapd/";
|
2015-05-28 19:20:29 +02:00
|
|
|
license = licenses.lgpl21;
|
2016-08-02 19:50:55 +02:00
|
|
|
platforms = platforms.linux;
|
2012-09-14 00:06:25 +02:00
|
|
|
};
|
|
|
|
}
|