Heya, On Sun, Jun 02, 2013 at 07:18:00PM +0200, Christian Hofstaedtler wrote: > there is a problem with rubygems-integration in which it fails to > properly override the binary path for gems. > > This is mostly seen when having bin stubs from previously installed > gems in /usr/local/bin, for example: > > % nokogiri > /usr/local/bin/nokogiri:23:in `load': cannot load such file -- > /usr/share/rubygems-integration/1.9.1/gems/nokogiri-1.5.9/bin/nokogiri > (LoadError) > from /usr/local/bin/nokogiri:23:in `<main>' > > Explicitly calling /usr/bin/nokogiri works fine.
A log of a chroot install to reproduce this for rake in Wheezy: root@entropy:/# apt-get install rake rubygems rubygems-integration Reading package lists... Done Building dependency tree Reading state information... Done The following extra packages will be installed: libffi5 libreadline5 libruby1.8 libruby1.9.1 libssl1.0.0 libyaml-0-2 ruby ruby1.8 ruby1.9.1 Suggested packages: ri ruby-dev ruby1.8-examples ri1.8 ruby-switch ruby1.9.1-examples ri1.9.1 graphviz ruby1.9.1-dev bundler Recommended packages: zip ruby1.8-dev The following NEW packages will be installed: libffi5 libreadline5 libruby1.8 libruby1.9.1 libssl1.0.0 libyaml-0-2 rake ruby ruby1.8 ruby1.9.1 rubygems rubygems-integration 0 upgraded, 12 newly installed, 0 to remove and 0 not upgraded. Need to get 4782 B/9142 kB of archives. After this operation, 27.5 MB of additional disk space will be used. Do you want to continue [Y/n]? y [...] root@entropy:/# rake --version rake, version 0.9.2.2 root@entropy:/# gem install rake --version 0.9.0 Fetching: rake-0.9.0.gem (100%) Successfully installed rake-0.9.0 1 gem installed [...] root@entropy:/# /usr/local/bin/rake --version /usr/local/bin/rake:23:in `load': cannot load such file -- /usr/share/rubygems-integration/1.9.1/gems/rake-0.9.2.2/bin/rake (LoadError) from /usr/local/bin/rake:23:in `<main>' It seems that the problem occurs if a "older" gem with a program is installed while already the same but newer is installed via Debian and rubygem-intergration. (That is why I explicitly install rake 0.9.0, while Debian Wheezy has 0.9.2.2.) Also involved is the binary "stub" generation by our patched RubyGems implementation. It seems to put the stub(s) somewhere in /usr/local/bin and to carry no version requirement so that it takes the newest one. This is fine, but in case of it finding our Debian integration-gemspec it should use /usr/bin as bin path, not /usr/share/rubygems-integration/1.9.1/gems/<gem>-<version>/bin/<program> IMO. (Btw, it seems to disregard version specifications as well, ie. # rake _0.9.0_ --version rake, version 0.9.2.2 but that is another issue :)) Cheers, Paul -- Using the Power of Debian GNU/Linux | E-mail: pau...@debian.org Jabber/GTalk: p...@luon.net | GnuPG key ID: 0x50064181 -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org