guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

01/01: gnu: perl-net-ssleay: Avoid patching source in 'origin'.


From: Mark H. Weaver
Subject: 01/01: gnu: perl-net-ssleay: Avoid patching source in 'origin'.
Date: Thu, 16 Jul 2015 03:48:37 +0000

mhw pushed a commit to branch core-updates
in repository guix.

commit 1084ec08c2fba55c436f9e2167c310ada0e3f632
Author: Mark H Weaver <address@hidden>
Date:   Wed Jul 15 23:43:33 2015 -0400

    gnu: perl-net-ssleay: Avoid patching source in 'origin'.
    
    * gnu/packages/tls.scm (perl-net-ssleay)[source]: Move patch to ...
      [native-inputs]: ... here, and also add the 'patch' program.
      [arguments]: Use 'modify-phases'.  Add 'apply-patch' phase.  Return
      boolean result from 'set-ssl-prefix' phase.
---
 gnu/packages/tls.scm |   30 +++++++++++++++++++++---------
 1 files changed, 21 insertions(+), 9 deletions(-)

diff --git a/gnu/packages/tls.scm b/gnu/packages/tls.scm
index 3d0000e..61a26ce 100644
--- a/gnu/packages/tls.scm
+++ b/gnu/packages/tls.scm
@@ -276,18 +276,30 @@ security, and applying best practice development 
processes.")
                                   "Net-SSLeay-" version ".tar.gz"))
               (sha256
                (base32
-                "1m2wwzhjwsg0drlhp9w12fl6bsgj69v8gdz72jqrqll3qr7f408p"))
-              (patches
-               ;; XXX Try removing this patch for perl-net-ssleay > 1.68
-               (list (search-patch 
"perl-net-ssleay-disable-ede-test.patch")))))
+                "1m2wwzhjwsg0drlhp9w12fl6bsgj69v8gdz72jqrqll3qr7f408p"))))
     (build-system perl-build-system)
+    (native-inputs
+     `(("patch" ,patch)
+       ("patch/disable-ede-test"
+        ,(search-patch "perl-net-ssleay-disable-ede-test.patch"))))
     (inputs `(("openssl" ,openssl)))
     (arguments
-     `(#:phases (alist-cons-before
-                 'configure 'set-ssl-prefix
-                 (lambda* (#:key inputs #:allow-other-keys)
-                   (setenv "OPENSSL_PREFIX" (assoc-ref inputs "openssl")))
-                 %standard-phases)))
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-after
+          'unpack 'apply-patch
+          (lambda* (#:key inputs #:allow-other-keys)
+            ;; XXX We apply this patch here instead of in the 'origin' because
+            ;; this package's build system fails badly when the source file
+            ;; times are zeroed.
+            ;; XXX Try removing this patch for perl-net-ssleay > 1.68
+            (zero? (system* "patch" "--force" "-p1" "-i"
+                            (assoc-ref inputs "patch/disable-ede-test")))))
+         (add-before
+          'configure 'set-ssl-prefix
+          (lambda* (#:key inputs #:allow-other-keys)
+            (setenv "OPENSSL_PREFIX" (assoc-ref inputs "openssl"))
+            #t)))))
     (synopsis "Perl extension for using OpenSSL")
     (description
      "This module offers some high level convenience functions for accessing



reply via email to

[Prev in Thread] Current Thread [Next in Thread]