Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Supported ruby versions undeclared in gemspec, ext/Rakefile unsupported with ruby 2.4.2 #68

Open
MatthewRalston opened this issue Oct 28, 2017 · 1 comment

Comments

@MatthewRalston
Copy link

MatthewRalston commented Oct 28, 2017

To avoid the Open-URI redirection issue described in #67, I tried installing the 2.3.0 gem for ruby version 2.4.2. In this case, the redirection is successful, but the rake still fails with a nameerror from Config=>RbConfig constant incompatability between ruby versions. Shouldn't the appropriate ruby versions be declared in the gemspec?

cd samtools-0.1.19
patch < ../Makefile-bioruby.patch
patching file Makefile
patch < ../Makefile-suse.patch
patching file Makefile
Hunk #1 succeeded at 15 with fuzz 1 (offset 2 lines).
rake aborted!
NameError: uninitialized constant Config
Did you mean?  RbConfig
/home/matt/.rvm/gems/ruby-2.4.2@ngsci/gems/bio-samtools-2.3.0/ext/Rakefile:23:in `block (2 levels) in <top (required)>'
/home/matt/.rvm/gems/ruby-2.4.2@ngsci/gems/bio-samtools-2.3.0/ext/Rakefile:19:in `block in <top (required)>'
/home/matt/.rvm/gems/ruby-2.4.2@ngsci/gems/rake-12.2.1/exe/rake:27:in `<main>'
Tasks: TOP => default => compile
(See full trace by running task with --trace)

rake failed, exit code 1
@MatthewRalston
Copy link
Author

MatthewRalston commented Oct 30, 2017

The actual issue in the source could be easily patched with the following, but a supported ruby version(s) statement should be included in the gemspec.

cfgConstant = Kernel.const_defined?('RbConfig') ? 'RbConfig' : 'Config'

...

case #{cfgConstant}::CONFIG['host_os']

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant