Modification of the Ruby build system preparing for the Nokogiri patch
(next mail).

Pj.


>From 8bdeef9e44abc0ed5e8491d360cc1e9e9de72420 Mon Sep 17 00:00:00 2001
From: pjotrp <pjotr.publi...@thebird.nl>
Date: Sun, 5 Jul 2015 18:00:22 +0200
Subject: [PATCH]   gnu: ruby: Allow 'rake gem' in ruby-build-system.

  * guix/build/ruby-build-system.scm (Ruby): Added 'rake gem' when gemspec is missing.
---
 guix/build/ruby-build-system.scm |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/guix/build/ruby-build-system.scm b/guix/build/ruby-build-system.scm
index 531cf38..ce0c17d 100644
--- a/guix/build/ruby-build-system.scm
+++ b/guix/build/ruby-build-system.scm
@@ -49,7 +49,10 @@ directory."
 
 (define build
   (lambda _
-    (zero? (system* "gem" "build" (first-matching-file "\\.gemspec$")))))
+    (let ((fnlist (find-files "." "\\.gemspec$")))
+      (if (null? fnlist)
+	  (zero? (system* "rake" "gem"))
+	  (zero? (system* "gem" "build" (car fnlist)))))))
 
 (define* (check #:key tests? test-target #:allow-other-keys)
   (if tests?
-- 
1.7.10.4

Reply via email to