diff mbox

[2/2] gnu: gnupg: patch scdaemon libpcsclite path

Message ID 0af65ca27af349d24cb59f9b824480f5d2bf9258.1477454587.git.mtg@gnu.org
State New
Headers show

Commit Message

Mike Gerwitz Oct. 22, 2016, 4:06 p.m. UTC
* gnu/packages/gnupg.scm (gnupg): Use absolute path of pcsc-lite for
  libpcsclite in `scd/scdaemon.c'
---
 gnu/packages/gnupg.scm | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)
diff mbox

Patch

diff --git a/gnu/packages/gnupg.scm b/gnu/packages/gnupg.scm
index da48e26..52af7c0 100644
--- a/gnu/packages/gnupg.scm
+++ b/gnu/packages/gnupg.scm
@@ -293,6 +293,7 @@  compatible to GNU Pth.")
        ("libksba" ,libksba)
        ("npth" ,npth)
        ("openldap" ,openldap)
+       ("libpcsclite" ,pcsc-lite)
        ("readline" ,readline)
        ("sqlite" ,sqlite)
        ("zlib" ,zlib)))
@@ -301,9 +302,15 @@  compatible to GNU Pth.")
       #:phases
       (modify-phases %standard-phases
         (add-before 'configure 'patch-config-files
-          (lambda _
+          (lambda* (#:key inputs outputs #:allow-other-keys)
             (substitute* "tests/openpgp/defs.inc"
               (("/bin/pwd") (which "pwd")))
+            (substitute* "scd/scdaemon.c"
+              (("\"(libpcsclite\\.so[^\"]*)\"" _ name)
+               (string-append "\""
+                              (assoc-ref inputs "libpcsclite")
+                              "/lib/" name
+                              "\"")))
             #t)))))
     (home-page "https://gnupg.org/")
     (synopsis "GNU Privacy Guard")