[bug#34222,04/15] gnu: Add ruby-racc.

Message ID 20190127170820.28937-4-mail@cbaines.net
State Accepted
Headers show
Series Add ruby-rubocop and dependencies. | expand

Checks

Context Check Description
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied
cbaines/applying patch success Successfully applied

Commit Message

Christopher Baines Jan. 27, 2019, 5:08 p.m. UTC
Required for ruby-ast and ruby-parser.

* gnu/packages/ruby.scm (ruby-racc): New variable.
---
 gnu/packages/ruby.scm | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)

Comments

Ricardo Wurmus Jan. 27, 2019, 5:27 p.m. UTC | #1
Christopher Baines <mail@cbaines.net> writes:

> Required for ruby-ast and ruby-parser.
>
> * gnu/packages/ruby.scm (ruby-racc): New variable.
[…]
> +    (license license:expat)))

On the website it says that the license is “LGPL” (no version is
provided).  Could you please confirm the license?
Christopher Baines Jan. 27, 2019, 6:57 p.m. UTC | #2
Ricardo Wurmus <rekado@elephly.net> writes:

> Christopher Baines <mail@cbaines.net> writes:
>
>> Required for ruby-ast and ruby-parser.
>>
>> * gnu/packages/ruby.scm (ruby-racc): New variable.
> […]
>> +    (license license:expat)))
>
> On the website it says that the license is “LGPL” (no version is
> provided).  Could you please confirm the license?

Indeed, the metadata in the gem is wrong. The information on the license
is a bit sparse. LGPL 2.1 is included in the sources, and there is one
file which references this in the header.

The published gem doesn't come from the original author, so I'm guessing
the default in the gemspec simply wasn't changed.
Christopher Baines Jan. 27, 2019, 7:06 p.m. UTC | #3
Christopher Baines <mail@cbaines.net> writes:

> Ricardo Wurmus <rekado@elephly.net> writes:
>
>> Christopher Baines <mail@cbaines.net> writes:
>>
>>> Required for ruby-ast and ruby-parser.
>>>
>>> * gnu/packages/ruby.scm (ruby-racc): New variable.
>> […]
>>> +    (license license:expat)))
>>
>> On the website it says that the license is “LGPL” (no version is
>> provided).  Could you please confirm the license?
>
> Indeed, the metadata in the gem is wrong. The information on the license
> is a bit sparse. LGPL 2.1 is included in the sources, and there is one
> file which references this in the header.

Actually, there is a lot more, I forgot to pass "-r" to
licensecheck. There's also 3 files where it says:

  You can distribute/modify this program under the same terms of ruby.

So I might put this instead. What do you think?

+    (license (list license:lgpl2.1
+                   license:ruby))))
Ricardo Wurmus Jan. 27, 2019, 7:26 p.m. UTC | #4
Christopher Baines <mail@cbaines.net> writes:

> Christopher Baines <mail@cbaines.net> writes:
>
>> Ricardo Wurmus <rekado@elephly.net> writes:
>>
>>> Christopher Baines <mail@cbaines.net> writes:
>>>
>>>> Required for ruby-ast and ruby-parser.
>>>>
>>>> * gnu/packages/ruby.scm (ruby-racc): New variable.
>>> […]
>>>> +    (license license:expat)))
>>>
>>> On the website it says that the license is “LGPL” (no version is
>>> provided).  Could you please confirm the license?
>>
>> Indeed, the metadata in the gem is wrong. The information on the license
>> is a bit sparse. LGPL 2.1 is included in the sources, and there is one
>> file which references this in the header.
>
> Actually, there is a lot more, I forgot to pass "-r" to
> licensecheck. There's also 3 files where it says:
>
>   You can distribute/modify this program under the same terms of ruby.
>
> So I might put this instead. What do you think?
>
> +    (license (list license:lgpl2.1
> +                   license:ruby))))

This would be fine with a comment.

Thanks!

Patch

diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index cd756a8b9a..7c2b9d9762 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -3655,6 +3655,28 @@  differences (added or removed nodes) between two XML/HTML documents.")
       (home-page "https://github.com/postmodern/nokogiri-diff")
       (license license:expat))))
 
+(define-public ruby-racc
+  (package
+    (name "ruby-racc")
+    (version "1.4.14")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (rubygems-uri "racc" version))
+       (sha256
+        (base32
+         "00yhs2ag7yy5v83mqvkbnhk9bvsh6mx3808k53n61ddzx446v1zl"))))
+    (build-system ruby-build-system)
+    (native-inputs
+     `(("ruby-hoe" ,ruby-hoe)
+       ("ruby-rake-compiler" ,ruby-rake-compiler)))
+    (synopsis "LALR(1) parser generator for Ruby")
+    (description
+     "Racc is a LALR(1) parser generator.  It is written in Ruby itself, and
+generates Ruby program.")
+    (home-page "http://i.loveruby.net/en/projects/racc/")
+    (license license:expat)))
+
 (define-public ruby-rack
   (package
     (name "ruby-rack")