[DRE-maint] Bug#986254: gem2deb creates gemspec file as a binary file for ruby-magic-static? gem
Pirate Praveen
praveen at onenetbeyond.org
Wed Apr 7 19:16:54 BST 2021
On Wed, 7 Apr 2021 14:36:25 -0300 Antonio Terceiro <terceiro at debian.org> wrote:
> On Wed, Apr 07, 2021 at 02:20:34PM -0300, Antonio Terceiro wrote:
> > On Wed, Apr 07, 2021 at 04:49:38PM +0530, Nilesh Patra wrote:
> > > And I tried changing the second "-lib" entry to ruby-lib (it does not
> > > mean anything, this is a random example)
> > >
> > > and I get the same offending term: ruby lib^@ruby-lib
> > > attaching the output, for ref
> > >
> > > So it looks like more than one entry in "require_paths" outputs a
> > > "binary" gemspec which is troublesome.
> > >
> > > Nilesh
> >
> > This sounds like a bug in rubygems itself.
>
> On the other hand, this seems to be done on purpose.
>
> def to_ruby
> require_relative 'openssl'
> mark_version
> result = []
> result << "# -*- encoding: utf-8 -*-"
> result << "#{Gem::StubSpecification::PREFIX}#{name} #{version} #{platform} #{raw_require_paths.join("\0")}"
> result << "#{Gem::StubSpecification::PREFIX}#{extensions.join "\0"}" unless
> extensions.empty?
>
> However, trying to load such gemspec should work fine:
>
> $ ruby -e 'puts Gem::Specification.new { |s| s.version = "1"; s.require_paths = ["foo", "bar"] }.to_ruby' > /tmp/g
> $ file /tmp/g
> /tmp/g: data
> $ ruby -e 'puts Gem::Specification.load("/tmp/g")'
> #<Gem::Specification name= version=1>
>
> Praveen, can you share the exact error that you got originally?
We can't create a patch for gemspec, for example I want to remove mini_portile2 from runtime dependencies. quilt refresh fails on it. Even git diff fails to show the diff.
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-ruby-extras-maintainers/attachments/20210407/961dcea6/attachment.htm>
More information about the Pkg-ruby-extras-maintainers
mailing list