[DRE-maint] Bug#867599: gem2deb fails to install pure ruby part when a gem has both pure ruby and native libs

Antonio Terceiro terceiro at debian.org
Sat Jul 8 14:15:04 UTC 2017


Control: severity -1 wishlist
Control: retitle -1 gem2deb: support installing Ruby code not in lib/

On Sat, Jul 08, 2017 at 01:48:19PM +0530, Pirate Praveen wrote:
> On 07/08/2017 11:53 AM, Pirate Praveen wrote:
> > On 07/08/2017 07:44 AM, Antonio Terceiro wrote:
> >> if the pure ruby libraries were not being installed, you would get a
> >> LoadError (i.e. a `require` statement failed), but that's not what is
> >> happening here.
> > For tests, the pure ruby libs are available in the source tree.
> > 
> > If I move the src/ruby/lib folder (I have locally installed ruby-grpc
> > deb), then it fails with `require': cannot load such file -- grpc
> > (LoadError)
> 
> I think gem2deb expects libraries only in lib.

From what I see from the source code, grpc is a library with multiple
language bindings; packaging it as a Ruby package is wrong. there is
even already a grpc source package in Debian. you should send a patch to
that package to generate a ruby-grpc binary package from there, instead
of creating a new ruby-specific package.

your ruby-grpc has a lot of embedded code copies under third_party/,
which has been already solved in grpc source package.

also, we can't possibly make gem2deb "just work" in such packages
because they deviate a lot from what a standard ruby package looks like.

> s.require_paths = %w( src/ruby/lib src/ruby/bin src/ruby/pb ) mentions
> it in grpc.gemspec but I don't know if gem2deb can reply on that.

gem2deb could be made to work with it, but I don't expect to get to it
any time soon. For now, I suggest that you

- drop your ruby-grpc
- send a patch to the existing grpc source to produce a ruby-grcp binary
  from it
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-ruby-extras-maintainers/attachments/20170708/6d8b4edc/attachment.sig>


More information about the Pkg-ruby-extras-maintainers mailing list