diff options
author | Nicolas Graves <ngraves@ngraves.fr> | 2025-06-18 16:27:55 +0200 |
---|---|---|
committer | Andreas Enge <andreas@enge.fr> | 2025-06-20 20:40:07 +0200 |
commit | 912b06840e610245799c506189a823f000b9738f (patch) | |
tree | 6bbe9604bdc71ebec34c52dc9e990ee0489ebbe7 /gnu/packages/ruby-xyz.scm | |
parent | 02bed4a9c544bbc3b9c1b16adb7719a0b943798f (diff) |
gnu: ruby-hydra: Fix build with Ruby@3.3.
* gnu/packages/ruby-xyz.scm
(ruby-hydra-minimal)[arguments]{phases}: Add phase 'fix-ruby-3.3-build.
(ruby-hydra)[arguments]: Inherit from ruby-hydra-minimal phases.
(ruby-hydra-minimal/pinned)[arguments]: Rewrite to avoid derivation
change, stop inheriting from ruby-hydra-minimal phases.
Diffstat (limited to 'gnu/packages/ruby-xyz.scm')
-rw-r--r-- | gnu/packages/ruby-xyz.scm | 33 |
1 files changed, 21 insertions, 12 deletions
diff --git a/gnu/packages/ruby-xyz.scm b/gnu/packages/ruby-xyz.scm index c72ca5ff37..edced1b722 100644 --- a/gnu/packages/ruby-xyz.scm +++ b/gnu/packages/ruby-xyz.scm @@ -3511,8 +3511,15 @@ two hashes.") "1swzab7i4cqk1bck7p5m3bh526jh0v6m9qq720r3270zbjc8x8z3")))) (build-system ruby-build-system) (arguments - ;; Avoid rspec dependency. - '(#:tests? #f)) + (list + #:tests? #f ; Avoid rspec dependency. + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'fix-ruby-3.3-build + (lambda _ + (substitute* "lib/hydra.rb" + (("exists\\?") + "exist?"))))))) (synopsis "Ruby hyphenation patterns") (description "ruby-hydra-minimal is a Ruby library for working with hyphenation patterns. @@ -3549,16 +3556,18 @@ It is a low-dependency variant of ruby-hydra.") (inherit ruby-hydra-minimal) (name "ruby-hydra") (arguments - (list - #:phases - #~(modify-phases %standard-phases - (add-after 'unpack 'make-files-writable - (lambda _ - (for-each make-file-writable (find-files ".")))) - (replace 'check - (lambda* (#:key tests? #:allow-other-keys) - (when tests? - (invoke "rspec"))))))) + (substitute-keyword-arguments (package-arguments ruby-hydra-minimal) + ((#:tests? tests? #t) + #t) + ((#:phases phases #~%standard-phases) + #~(modify-phases #$phases + (add-after 'unpack 'make-files-writable + (lambda _ + (for-each make-file-writable (find-files ".")))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "rspec")))))))) (native-inputs (list ruby-rspec)) (description |