nixpkgs/pkgs/development/python-modules/python-pam/default.nix
Michael Daniels 075e8c2c4f
treewide: change 'format = "pyproject";' to 'pyproject = true;'
This is almost all find-and-replace.

I manually edited:
* pkgs/development/python-modules/notifications-android-tv/default.nix,
* pkgs/servers/home-assistant/default.nix,
* pkgs/development/tools/continuous-integration/buildbot/master.nix

A few files have not been changed in this PR because they would cause rebuilds.

This PR should have 0 rebuilds.
2026-01-12 17:50:35 -05:00

48 lines
937 B
Nix

{
lib,
buildPythonPackage,
fetchFromGitHub,
setuptools,
pam,
six,
toml,
}:
buildPythonPackage rec {
pname = "python-pam";
version = "2.0.2";
pyproject = true;
src = fetchFromGitHub {
owner = "FirefighterBlu3";
repo = "python-pam";
tag = "v${version}";
hash = "sha256-MR9LYXtkbltAmn7yoyyKZn4yMHyh3rj/i/pA8nJy2xU=";
};
postPatch = ''
substituteInPlace src/pam/__internals.py \
--replace 'find_library("pam")' '"${pam}/lib/libpam.so"' \
--replace 'find_library("pam_misc")' '"${pam}/lib/libpam_misc.so"'
'';
nativeBuildInputs = [ setuptools ];
buildInputs = [ pam ];
propagatedBuildInputs = [
six
toml
];
pythonImportsCheck = [ "pam" ];
meta = {
description = "Python pam module";
homepage = "https://github.com/FirefighterBlu3/python-pam";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [
mkg20001
];
};
}