[PATCH 0/2] gnu: ruby-libxml: Update to 5.0.3.

  • Open
  • quality assurance status badge
Details
One participant
  • gemmaro
Owner
unassigned
Submitted by
gemmaro
Severity
normal
G
G
gemmaro wrote on 9 Jul 16:11 +0200
(address . guix-patches@gnu.org)(name . gemmaro)(address . gemmaro.dev@gmail.com)
cover.1720534195.git.gemmaro.dev@gmail.com
Hello,

This updates ruby-libxml to 5.0.3 and make use of newer package style.

Thank you,
gemmaro.

gemmaro (2):
gnu: ruby-libxml: Update to 5.0.3.
gnu: ruby-libxml: Use newer package style.

gnu/packages/ruby.scm | 46 +++++++++++++++++++++++++++++++++----------
1 file changed, 36 insertions(+), 10 deletions(-)


base-commit: 6b496c071537e399710ff5ec0284f74a44b66c71
prerequisite-patch-id: 7243f4196faacbbb69b65baecf49b488e4c8a910
prerequisite-patch-id: 9b13ec2a36c340b6f7ab5530d43fab3dfb6cf912
--
2.45.2
G
G
gemmaro wrote on 9 Jul 16:18 +0200
[PATCH 1/2] gnu: ruby-libxml: Update to 5.0.3.
(address . 72009@debbugs.gnu.org)(name . gemmaro)(address . gemmaro.dev@gmail.com)
96fc8bfd1055a3202fde32beaadfda8d10fff19a.1720534195.git.gemmaro.dev@gmail.com
* gnu/packages/ruby.scm (ruby-libxml): Update to 5.0.3.
[native-inputs]: Add ruby-minitest and ruby-rake-compiler.
[arguments]<#:tests?>: Remove to turn on tests.
<#:phases>: Add skip-failing-tests and set-gem-path phase.
Move check phase after set-gem-path in order to use compiled and installed
extension files.

Change-Id: Id9a3670bd84bc31b886748336aeb6b850a5b1b5d
---
gnu/packages/ruby.scm | 35 ++++++++++++++++++++++++++++++-----
1 file changed, 30 insertions(+), 5 deletions(-)

Toggle diff (63 lines)
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 9547481caf..74877ac4a9 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -3211,26 +3211,51 @@ (define-public ruby-orderedhash
(define-public ruby-libxml
(package
(name "ruby-libxml")
- (version "3.0.0")
+ (version "5.0.3")
(source
(origin
(method url-fetch)
(uri (rubygems-uri "libxml-ruby" version))
(sha256
(base32
- "0xy8wmjwjcnv36zi042678ncjzpxvy351ccbv7mzkns2n3kxfp54"))))
+ "1pib5bfwg684f1sczrhf3lzk9hb24dhsw5cmlnxm4rq66sx0slss"))))
(build-system ruby-build-system)
+ (native-inputs (list ruby-minitest ruby-rake-compiler))
(inputs
(list zlib libxml2))
(arguments
- '(#:tests? #f ; test suite hangs for unknown reason
- #:gem-flags
+ '(#:gem-flags
(list "--no-document" ; TODO: Re-enable when documentation
; generation works
"--"
(string-append "--with-xml2-include="
(assoc-ref %build-inputs "libxml2")
- "/include/libxml2" ))))
+ "/include/libxml2"))
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'skip-failing-tests
+ (lambda _
+ (for-each
+ (lambda (method)
+ (substitute* "test/test_canonicalize.rb"
+ (((string-append "def " method) def)
+ (string-append def "; skip \"CR/LF mismatch\";"))))
+ '("test_canonicalize_with_w3c_c14n_3_1"
+ "test_canonicalize_with_w3c_c14n_3_2"
+ "test_canonicalize_with_w3c_c14n_3_3"
+ "test_canonicalize_with_w3c_c14n_3_4"))
+ (substitute* "test/test_schema.rb"
+ (("def test_schema_load_from_uri" def)
+ (string-append def "; skip \"missing XLink schema\";")))))
+ (delete 'check)
+ (add-after 'install 'set-gem-path
+ (lambda* (#:key outputs #:allow-other-keys)
+ (setenv "GEM_PATH"
+ (string-append
+ (getenv "GEM_PATH") ":"
+ (assoc-ref outputs "out") "/lib/ruby/vendor_ruby"))))
+ (add-after 'set-gem-path 'check
+ (assoc-ref %standard-phases 'check)))))
(synopsis "Ruby bindings for GNOME Libxml2")
(description "The Libxml-Ruby project provides Ruby language bindings for
the GNOME Libxml2 XML toolkit.")
--
2.45.2
G
G
gemmaro wrote on 9 Jul 16:18 +0200
[PATCH 2/2] gnu: ruby-libxml: Use newer package style.
(address . 72009@debbugs.gnu.org)(name . gemmaro)(address . gemmaro.dev@gmail.com)
fa6ac49bc1f8e12bc00846e1eed863d64de47b09.1720534195.git.gemmaro.dev@gmail.com
* gnu/packages/ruby.scm (ruby-libxml)[arguments]:
Convert to list of G-Expressions.
Use #$output rather than the outputs alist.

Change-Id: If46c6d1a28358be03f854082570c913ee7f80cc7
---
gnu/packages/ruby.scm | 65 ++++++++++++++++++++++---------------------
1 file changed, 33 insertions(+), 32 deletions(-)

Toggle diff (78 lines)
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 74877ac4a9..fa2d474e4c 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -3224,38 +3224,39 @@ (define-public ruby-libxml
(inputs
(list zlib libxml2))
(arguments
- '(#:gem-flags
- (list "--no-document" ; TODO: Re-enable when documentation
- ; generation works
- "--"
- (string-append "--with-xml2-include="
- (assoc-ref %build-inputs "libxml2")
- "/include/libxml2"))
- #:phases
- (modify-phases %standard-phases
- (add-after 'unpack 'skip-failing-tests
- (lambda _
- (for-each
- (lambda (method)
- (substitute* "test/test_canonicalize.rb"
- (((string-append "def " method) def)
- (string-append def "; skip \"CR/LF mismatch\";"))))
- '("test_canonicalize_with_w3c_c14n_3_1"
- "test_canonicalize_with_w3c_c14n_3_2"
- "test_canonicalize_with_w3c_c14n_3_3"
- "test_canonicalize_with_w3c_c14n_3_4"))
- (substitute* "test/test_schema.rb"
- (("def test_schema_load_from_uri" def)
- (string-append def "; skip \"missing XLink schema\";")))))
- (delete 'check)
- (add-after 'install 'set-gem-path
- (lambda* (#:key outputs #:allow-other-keys)
- (setenv "GEM_PATH"
- (string-append
- (getenv "GEM_PATH") ":"
- (assoc-ref outputs "out") "/lib/ruby/vendor_ruby"))))
- (add-after 'set-gem-path 'check
- (assoc-ref %standard-phases 'check)))))
+ (list
+ #:gem-flags #~(list
+ ;; TODO: Re-enable when documentation generation works
+ "--no-document" "--"
+ (string-append "--with-xml2-include="
+ (assoc-ref %build-inputs "libxml2")
+ "/include/libxml2"))
+ #:phases #~(modify-phases %standard-phases
+ (add-after 'unpack 'skip-failing-tests
+ (lambda _
+ (for-each (lambda (method)
+ (substitute* "test/test_canonicalize.rb"
+ (((string-append "def " method)
+ def)
+ (string-append def
+ "; skip \"CR/LF mismatch\";"))))
+ '("test_canonicalize_with_w3c_c14n_3_1"
+ "test_canonicalize_with_w3c_c14n_3_2"
+ "test_canonicalize_with_w3c_c14n_3_3"
+ "test_canonicalize_with_w3c_c14n_3_4"))
+ (substitute* "test/test_schema.rb"
+ (("def test_schema_load_from_uri" def)
+ (string-append def
+ "; skip \"missing XLink schema\";")))))
+ (delete 'check)
+ (add-after 'install 'set-gem-path
+ (lambda _
+ (setenv "GEM_PATH"
+ (string-append (getenv "GEM_PATH") ":"
+ #$output "/lib/ruby/vendor_ruby"))))
+ (add-after 'set-gem-path 'check
+ (assoc-ref %standard-phases
+ 'check)))))
(synopsis "Ruby bindings for GNOME Libxml2")
(description "The Libxml-Ruby project provides Ruby language bindings for
the GNOME Libxml2 XML toolkit.")
--
2.45.2
?
Your comment

Commenting via the web interface is currently disabled.

To comment on this conversation send an email to 72009@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 72009
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch