nixpkgs/pkgs/servers/ldap/389/default.nix

62 lines
1.6 KiB
Nix
Raw Normal View History

2014-12-30 20:30:15 +03:00
{ stdenv, fetchurl, pkgconfig, perl, pam, nspr, nss, openldap, db, cyrus_sasl
2015-05-29 06:31:22 +03:00
, svrcore, icu, net_snmp, libkrb5, pcre, perlPackages
2014-12-30 20:30:15 +03:00
}:
2015-01-10 02:01:01 +03:00
let
2015-04-18 00:09:41 +03:00
version = "1.3.3.9";
2015-01-10 02:01:01 +03:00
in
2014-12-30 20:30:15 +03:00
stdenv.mkDerivation rec {
2015-01-10 02:01:01 +03:00
name = "389-ds-base-${version}";
2014-12-30 20:30:15 +03:00
src = fetchurl {
url = "http://directory.fedoraproject.org/binaries/${name}.tar.bz2";
2015-04-18 00:09:41 +03:00
sha256 = "1qqwv5j60f38hz4xpbzn4pixhkj07yjzbp7kz7cvfkgvdwy9jqxx";
2014-12-30 20:30:15 +03:00
};
buildInputs = [
pkgconfig perl pam nspr nss openldap db cyrus_sasl svrcore icu
2015-05-29 06:31:22 +03:00
net_snmp libkrb5 pcre
2015-01-10 02:01:01 +03:00
] ++ (with perlPackages; [ MozillaLdap NetAddrIP DBFile ]);
# TODO: Fix bin/ds-logpipe.py, bin/logconv, bin/cl-dump
2014-12-30 20:30:15 +03:00
2015-04-18 00:09:41 +03:00
patches = [ ./perl-path.patch ];
2015-01-10 02:01:01 +03:00
preConfigure = ''
# Create perl paths for library imports in perl scripts
PERLPATH=""
for P in $(echo $PERL5LIB | sed 's/:/ /g'); do
PERLPATH="$PERLPATH $(echo $P/*/*)"
done
export PERLPATH
'';
2015-01-09 22:05:12 +03:00
2014-12-30 20:30:15 +03:00
configureFlags = [
"--sysconfdir=/etc"
2015-01-09 22:05:12 +03:00
"--localstatedir=/var"
2014-12-30 20:30:15 +03:00
"--with-openldap=${openldap}"
"--with-db=${db}"
"--with-sasl=${cyrus_sasl}"
"--with-netsnmp=${net_snmp}"
];
2015-01-09 22:05:12 +03:00
preInstall = ''
# The makefile doesn't create this directory for whatever reason
mkdir -p $out/lib/dirsrv
'';
2015-04-18 00:09:41 +03:00
installFlags = [
"sysconfdir=\${out}/etc"
"localstatedir=\${TMPDIR}"
];
2015-01-10 02:01:01 +03:00
passthru.version = version;
2014-12-30 20:30:15 +03:00
meta = with stdenv.lib; {
homepage = https://directory.fedoraproject.org/;
description = "enterprise-class Open Source LDAP server for Linux";
license = licenses.gpl2;
platforms = platforms.linux;
maintainers = with maintainers; [ wkennington ];
};
}