python3Packages.pyoprf: init at 0.7.1
Signed-off-by: Ethan Carter Edwards <ethan@ethancedwards.com>
This commit is contained in:
parent
a5bebf0fb7
commit
1631285382
54
pkgs/development/python-modules/pyoprf/default.nix
Normal file
54
pkgs/development/python-modules/pyoprf/default.nix
Normal file
@ -0,0 +1,54 @@
|
||||
{
|
||||
lib,
|
||||
stdenv,
|
||||
buildPythonPackage,
|
||||
liboprf,
|
||||
setuptools,
|
||||
pysodium,
|
||||
securestring,
|
||||
pytestCheckHook,
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "pyoprf";
|
||||
pyproject = true;
|
||||
|
||||
inherit (liboprf)
|
||||
version
|
||||
src
|
||||
;
|
||||
|
||||
postPatch =
|
||||
let
|
||||
soext = stdenv.hostPlatform.extensions.sharedLibrary;
|
||||
in
|
||||
''
|
||||
substituteInPlace ./pyoprf/__init__.py --replace-fail \
|
||||
"ctypes.util.find_library('oprf') or ctypes.util.find_library('liboprf')" "'${lib.getLib liboprf}/lib/liboprf${soext}'"
|
||||
'';
|
||||
|
||||
sourceRoot = "${src.name}/python";
|
||||
|
||||
build-system = [ setuptools ];
|
||||
|
||||
dependencies = [
|
||||
pysodium
|
||||
securestring
|
||||
];
|
||||
|
||||
pythonImportsCheck = [ "pyoprf" ];
|
||||
|
||||
nativeCheckInputs = [ pytestCheckHook ];
|
||||
|
||||
pytestFlagsArray = [ "tests/test.py" ];
|
||||
|
||||
meta = {
|
||||
inherit (liboprf.meta)
|
||||
description
|
||||
homepage
|
||||
changelog
|
||||
license
|
||||
teams
|
||||
;
|
||||
};
|
||||
}
|
@ -13508,6 +13508,8 @@ self: super: with self; {
|
||||
|
||||
pyoppleio-legacy = callPackage ../development/python-modules/pyoppleio-legacy { };
|
||||
|
||||
pyoprf = callPackage ../development/python-modules/pyoprf { };
|
||||
|
||||
pyorc = callPackage ../development/python-modules/pyorc { };
|
||||
|
||||
pyorthanc = callPackage ../development/python-modules/pyorthanc { };
|
||||
|
Loading…
x
Reference in New Issue
Block a user