python3Packages.pdf-oxide: init at 0.3.32

This commit is contained in:
daspk04
2026-04-19 14:19:34 -05:00
parent 9ea4556f47
commit dbec80b584
3 changed files with 53 additions and 1 deletions
+5 -1
View File
@@ -3,6 +3,7 @@
fetchFromGitHub,
rustPlatform,
nix-update-script,
python3Packages,
versionCheckHook,
}:
@@ -28,7 +29,10 @@ rustPlatform.buildRustPackage (finalAttrs: {
nativeInstallCheckInputs = [ versionCheckHook ];
doInstallCheck = true;
passthru.updateScript = nix-update-script { };
passthru = {
python-bindings = python3Packages.pdf-oxide;
updateScript = nix-update-script { };
};
meta = {
description = "Fastest PDF library for text extraction, image extraction, and markdown conversion";
@@ -0,0 +1,46 @@
{
lib,
pkgs,
fetchFromGitHub,
buildPythonPackage,
# build-system
rustPlatform,
# optional-dependencies
onnxruntime,
# tests
pytestCheckHook,
}:
buildPythonPackage (finalAttrs: {
inherit (pkgs.pdf-oxide)
pname
version
src
cargoDeps
;
pyproject = true;
nativeBuildInputs = with rustPlatform; [
cargoSetupHook
maturinBuildHook
];
optional-dependencies = {
ocr = [ onnxruntime ];
};
nativeCheckInputs = [
pytestCheckHook
];
pythonImportsCheck = [
"pdf_oxide"
];
meta = pkgs.pdf-oxide.meta // {
description = "Python bindings for the pdf_oxide library";
};
})
+2
View File
@@ -12245,6 +12245,8 @@ self: super: with self; {
pdbfixer = callPackage ../development/python-modules/pdbfixer { };
pdf-oxide = callPackage ../development/python-modules/pdf-oxide { };
pdf2docx = callPackage ../development/python-modules/pdf2docx { };
pdf2image = callPackage ../development/python-modules/pdf2image { };