nixpkgs/pkgs/by-name/pa/pam_ldap/package.nix
aleksana 571c71e6f7 treewide: migrate packages to pkgs/by-name, take 1
We are migrating packages that meet below requirements:

1. using `callPackage`
2. called path is a directory
3. overriding set is empty (`{ }`)
4. not containing path expressions other than relative path (to
makenixpkgs-vet happy)
5. not referenced by nix files outside of the directory, other
than`pkgs/top-level/all-packages.nix`
6. not referencing nix files outside of the directory
7. not referencing `default.nix` (since it's changed to `package.nix`)
8. `outPath` doesn't change after migration

The tool is here: https://github.com/Aleksanaa/by-name-migrate.
2024-11-09 20:04:51 +08:00

35 lines
949 B
Nix

{ stdenv, fetchurl, pam, openldap, perl }:
stdenv.mkDerivation rec {
pname = "pam_ldap";
version = "186";
src = fetchurl {
url = "https://www.padl.com/download/pam_ldap-${version}.tar.gz";
sha256 = "0lv4f7hc02jrd2l3gqxd247qq62z11sp3fafn8lgb8ymb7aj5zn8";
};
postPatch = ''
patchShebangs ./vers_string
substituteInPlace vers_string --replace "cvslib.pl" "./cvslib.pl"
'';
preInstall = "
substituteInPlace Makefile --replace '-o root -g root' ''
";
nativeBuildInputs = [ perl ];
buildInputs = [ pam openldap ];
meta = {
homepage = "https://www.padl.com/OSS/pam_ldap.html";
description = "LDAP backend for PAM";
longDescription = ''
The pam_ldap module provides the means for Solaris and Linux servers and
workstations to authenticate against LDAP directories, and to change their
passwords in the directory.'';
license = "LGPL";
inherit (pam.meta) platforms;
};
}