nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 51 lines 1.2 kB view raw
1{ 2 lib, 3 stdenv, 4 fetchurl, 5 openldap, 6 perl, 7}: 8 9stdenv.mkDerivation (finalAttrs: { 10 pname = "nss_ldap"; 11 version = "265"; 12 13 src = fetchurl { 14 url = "http://www.padl.com/download/nss_ldap-${finalAttrs.version}.tar.gz"; 15 sha256 = "1a16q9p97d2blrj0h6vl1xr7dg7i4s8x8namipr79mshby84vdbp"; 16 }; 17 18 preConfigure = '' 19 patchShebangs ./vers_string 20 sed -i s,vers_string,./vers_string, Makefile* 21 substituteInPlace vers_string --replace "cvslib.pl" "./cvslib.pl" 22 ''; 23 24 patches = [ ./crashes.patch ]; 25 26 postPatch = '' 27 patch -p0 < ${./nss_ldap-265-glibc-2.16.patch} 28 ''; 29 30 preInstall = '' 31 installFlagsArray=(INST_UID=$(id -u) INST_GID=$(id -g) LIBC_VERS=2.5 NSS_VERS=2 NSS_LDAP_PATH_CONF=$out/etc/ldap.conf) 32 substituteInPlace Makefile \ 33 --replace '/usr$(libdir)' $TMPDIR \ 34 --replace 'install-data-local:' 'install-data-local-disabled:' 35 mkdir -p $out/etc 36 ''; 37 38 nativeBuildInputs = [ 39 perl # shebang of vers_string 40 ]; 41 42 buildInputs = [ 43 openldap 44 ]; 45 46 meta = { 47 description = "LDAP module for the Solaris Nameservice Switch (NSS)"; 48 license = lib.licenses.gpl2Plus; 49 platforms = lib.platforms.linux; 50 }; 51})