From 24c14a8fc90917cf0e2575166ac25b3cf4de3e15 Mon Sep 17 00:00:00 2001 From: Will Dietz Date: Sun, 12 Jan 2020 17:24:59 -0600 Subject: ocrmypdf: fix patching of leptonica lib path --- pkgs/tools/text/ocrmypdf/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/tools') diff --git a/pkgs/tools/text/ocrmypdf/default.nix b/pkgs/tools/text/ocrmypdf/default.nix index 3c6e606601b..a301e9310d9 100644 --- a/pkgs/tools/text/ocrmypdf/default.nix +++ b/pkgs/tools/text/ocrmypdf/default.nix @@ -70,8 +70,8 @@ in buildPythonApplication rec { postPatch = '' substituteInPlace src/ocrmypdf/leptonica.py \ - --replace "lept = ffi.dlopen(_libpath)" \ - 'lept = ffi.dlopen("${stdenv.lib.makeLibraryPath [leptonica]}/liblept${stdenv.hostPlatform.extensions.sharedLibrary}")' + --replace '_libpath = find_library(libname)' \ + '_libpath = "${stdenv.lib.getLib leptonica}/lib/liblept${stdenv.hostPlatform.extensions.sharedLibrary}"' ''; # The tests take potentially 20+ minutes, depending on machine -- cgit 1.4.1