diff mbox series

[bug#60824,1/2] gnu: perl-xml-xpath: Wrap xpath command.

Message ID 024ddbe123ad4d22ca508e1cb998da48fb16338b.1673745598.git.mirai@makinata.eu
State New
Headers show
Series [bug#60824,1/2] gnu: perl-xml-xpath: Wrap xpath command. | expand

Commit Message

Bruno Victal Jan. 15, 2023, 1:20 a.m. UTC
* gnu/packages/xml.scm (perl-xml-xpath)[arguments]: Wrap xpath.
[description]: Document xpath command presence.
---
 gnu/packages/xml.scm | 13 ++++++++++++-
 1 file changed, 12 insertions(+), 1 deletion(-)


base-commit: fb3085e80fd3d4559057b60d9e2c1c1f1ff51022

Comments

Bruno Victal May 6, 2023, 4:07 p.m. UTC | #1
Patch still applies to master (1cb0dee3a31c6d235389d4d9787fa583c2babc30)
Maxim Cournoyer Oct. 9, 2023, 1:16 p.m. UTC | #2
Hello,

Bruno Victal <mirai@makinata.eu> writes:

> Notable changes since v3:
> * Rebased against core-updates.
> * Use search-path-as-list for wrapping.
>
> Bruno Victal (2):
>   gnu: perl-xml-xpath: Wrap xpath command.
>   gnu: perl-xml-xpath: Update to 1.48.
>
>  gnu/packages/xml.scm | 28 ++++++++++++++++++++++++----
>  1 file changed, 24 insertions(+), 4 deletions(-)

LGTM!
diff mbox series

Patch

diff --git a/gnu/packages/xml.scm b/gnu/packages/xml.scm
index b5065f9f30..7fdc3a2e32 100644
--- a/gnu/packages/xml.scm
+++ b/gnu/packages/xml.scm
@@ -33,6 +33,7 @@ 
 ;;; Copyright © 2021 Guillaume Le Vaillant <glv@posteo.net>
 ;;; Copyright © 2021 David Larsson <david.larsson@selfhosted.xyz>
 ;;; Copyright © 2021 Matthew James Kraai <kraai@ftbfs.org>
+;;; Copyright © 2023 Bruno Victal <mirai@makinata.eu>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1050,6 +1051,16 @@  (define-public perl-xml-xpath
                (base32
                 "03yxj7w5a43ibbpiqsvb3lswj2b71dydsx4rs2fw0p8n0l3i3j8w"))))
     (build-system perl-build-system)
+    (arguments
+     (list
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-after 'wrap 'wrap-xpath
+            (lambda _
+              (wrap-program (string-append #$output "/bin/xpath")
+                `("PERL5LIB" ":" prefix
+                  ,(cons (string-append #$output "/lib/perl5/site_perl")
+                         (string-split (getenv "PERL5LIB") #\:)))))))))
     (native-inputs
      (list perl-path-tiny))
     (propagated-inputs
@@ -1059,7 +1070,7 @@  (define-public perl-xml-xpath
     (description
      "This module aims to comply exactly to the @url{XPath specification,
 https://www.w3.org/TR/xpath} and yet allow extensions to be added in
-the form of functions.")
+the form of functions. It also provides the command @command{xpath}.")
     (license license:perl-license)))
 
 (define-public pugixml