summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Baines <mail@cbaines.net>2019-01-27 19:41:26 +0000
committerChristopher Baines <christopher.baines@digital.cabinet-office.gov.uk>2019-01-29 22:56:12 +0000
commit05858c97572e25b0cb898815a0ad38ac65e49148 (patch)
tree3190a14f113a1b28cc2b9a33818de58298bec015
parent5998e55bb7e492d08e8d9d832fa78e50309099bd (diff)
downloadgnu-guix-05858c97572e25b0cb898815a0ad38ac65e49148.tar
gnu-guix-05858c97572e25b0cb898815a0ad38ac65e49148.tar.gz
gnu: Add ruby-idn-ruby.
Required for the ruby-addressable tests. * gnu/packages/ruby.scm (ruby-idn-ruby): New variable.
-rw-r--r--gnu/packages/ruby.scm45
1 files changed, 45 insertions, 0 deletions
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 676f1ecad0..72f9a9234f 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -40,6 +40,7 @@
#:use-module (gnu packages autotools)
#:use-module (gnu packages java)
#:use-module (gnu packages libffi)
+ #:use-module (gnu packages libidn)
#:use-module (gnu packages maths)
#:use-module (gnu packages ncurses)
#:use-module (gnu packages networking)
@@ -1993,6 +1994,50 @@ irb's last-word approach.")
(home-page "http://tagaholic.me/bond/")
(license license:expat)))
+(define-public ruby-idn-ruby
+ (package
+ (name "ruby-idn-ruby")
+ (version "0.1.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (rubygems-uri "idn-ruby" version))
+ (sha256
+ (base32
+ "07vblcyk3g72sbq12xz7xj28snpxnh3sbcnxy8bglqbfqqhvmawr"))))
+ (build-system ruby-build-system)
+ (arguments
+ '(#:phases
+ (modify-phases %standard-phases
+ (add-before 'build 'run-extconf.rb
+ (lambda _
+ (with-directory-excursion "ext"
+ (invoke "ruby" "extconf.rb")
+ (invoke "make"))
+ #t))
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ (apply invoke
+ "ruby" "--verbose" "-Iext"
+ (find-files "./test" ".*\\.rb")))
+ #t)))))
+ (inputs
+ `(("libidn" ,libidn)))
+ (synopsis "Ruby Bindings for the GNU LibIDN library")
+ (description
+ "Ruby Bindings for the GNU LibIDN library, an implementation of the
+Stringprep, Punycode and IDNA specifications. These are used to encode and
+decode internationalized domain + names according to the IDNA2003
+specifications.
+
+Included are the most important parts of the Stringprep, Punycode and IDNA
+APIs like performing Stringprep processings, encoding to and decoding from
+Punycode strings and converting entire domain names to and from the ACE
+encoded form.")
+ (home-page "https://github.com/deepfryed/idn-ruby")
+ (license license:asl2.0)))
+
(define-public ruby-instantiator
(package
(name "ruby-instantiator")