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

RVM(1.20.12) does not install Ruby 2.0.0p195 but it installs 1.8.7 . #1925

Closed
acnalesso opened this issue May 26, 2013 · 8 comments
Closed

Comments

@acnalesso
Copy link

Hi, I asked this question on the mailing list and @mpapis told me to open a bug report.
My OS was Debian Lenny old-stable so that made me to migrate to Debian Wheezy
The former OS was running rvm perfectly, without any error. I do know wether this is a OS incomparability or an rvm bug.

Debian Wheezy 2.6.32-5-amd64

 gcc      4.4.7-2
 git        1.8.1.2
 curl      7.21.0
 bash    4.1.5
 libxml2 2.8.0

After installing all the dependencies ruby, rvm need I installed rvm:

\curl -L https://get.rvm.io | bash -s -- --ignore-dotfiles

So far so good, However when I tried to install ruby 2.0

 rvm install ruby-2.0.0

It installs but it does not compile ruby-2.0.0 and it finishes without prompting any error, Therefore when I do:

 #installation output - https://gist.github.com/nbit001/5651567
 rvm 2.0.0
 ruby -v

It outputs:

$HOME/.rvm/rubies/ruby-2.0.0-p195/bin/ruby: No such file or directory

As it shows, somehow it is not being compiled, Now I don't know how the lastest rvm works when installing ruby.
It is not a permission issue because I am using sudo.

So I started looking for the solution,
What I came up with was:

 rvm install ruby-2.0.0 --with-gcc=gcc

When I do this it does compile and work perfectly.
Thereafter when I do:

rvm 2.0
 ruby -v #=> ruby 2.0.0p195 (2013-05-14 revision 40734) [x86_64-linux]

Okay it is working, but I am so curious why it works that I need to ask the ones more experienced than me.
Due to some hacking in the expectation of getting it to work, I have seen that when I type rvm install 2.0, it downloads ruby-2.0.0-p195.tar.bz2 and it renames it pre-pending 'bin' to its name.
When I run rvm install 2.0 --with-gcc=gcc which downloads ruby-2.0.0-p195.tar.bz2 and does not prepend bin to its file's name.

What I have also noticed is that bin-ruby-2.0.0-p195 has a dir tree totally different than ruby-2.0.0-p195(without bin-) .
Moreover, I installed ruby 1.8.7 and it worked perfectly, without using any flag(Weird?) and the ruby-1.8.7-p371.tar.bz2's tree directory is in the same order of ruby-2.00.tar.bz2(without bin- at the beginning of its name).
Also rvm install 2.0.0 does not generate any blob_number_extract.log, _name.log, _install.log.
However it generates blob_number_gem.install.log, _gemsets.initial.log, etc.
Whereas rvm install 2.0.0 --with-gcc=gcc generates all sorts of logs.

I will be glad to help, I am also going to 'dig a bit deeper' trying some things to see if I find where the bug is.

Thanks

@mpapis
Copy link
Member

mpapis commented May 27, 2013

please run:

rvm remove ruby-2.0.0
rvm install ruby-2.0.0 --debug

@acnalesso
Copy link
Author

I've done it, here is the gist.
As you can see it clearly is not compiling ruby source code when ruby rvm install 1.9.3
It outputs: Fixing ruby compiler from '' to '/usr/bin/gcc'. Which I think, it is because it does not find gcc? Correct me if I am wrong.

Here is the gist with rvm install 1.9.3 --with-gcc=gcc
It outputs: found compiler: gcc
So I guess when I do not use --with-gcc=gcc it does not find the gcc..?

Thanks :)

@mpapis
Copy link
Member

mpapis commented May 27, 2013

something else is wrong, the compiler line is proper.

can you please gist:

find /home/nbit001/.rvm/rubies/ruby-1.9.3-p429

@acnalesso
Copy link
Author

I thought so.
As I had to start developing in ruby 1.9.3 I am going to gist ruby 2.0.
gist

Thanks again @mpapis

@mpapis
Copy link
Member

mpapis commented May 27, 2013

it's all fine for 2.0.0 => /home/nbit001/.rvm/rubies/ruby-2.0.0-p195/bin/ruby I also checked the package for 1.9.3 and it also contained bin/ruby so unless you can reproduce the problem and confirm there was no bin/ruby I'm closing this ticket as invalid.

@mpapis mpapis closed this as completed May 27, 2013
@acnalesso
Copy link
Author

I sorted it out using --with-gcc=gcc.
It could be something wrong with my OS. However it is working now, but the fact that I do not know why it works upsets me. I will look deeper and see if I can figure out what it's happening.

Thanks

@richo
Copy link
Member

richo commented May 27, 2013

JQRa
On 28/05/2013 7:54 AM, "Michal Papis" notifications@github.com wrote:

it's all fine for 2.0.0 =>
/home/nbit001/.rvm/rubies/ruby-2.0.0-p195/bin/ruby I also checked the
package for 1.9.3 and it also contained bin/ruby so unless you can
reproduce the problem and confirm there was no bin/ruby I'm closing this
ticket as invalid.


Reply to this email directly or view it on GitHubhttps://github.com//issues/1925#issuecomment-18516060
.

@mpapis
Copy link
Member

mpapis commented May 27, 2013

it worked because any --with* flag disables binary build => https://github.com/wayneeseguin/rvm/blob/0ea17afac07f16bb618d81ab002b7849e3496d8c/scripts/cli#L734-L736

without the gist:

find /home/nbit001/.rvm/rubies/ruby-1.9.3-p429

I can not tell more

@pkuczynski pkuczynski added this to the rvm-1.27.0-before milestone May 8, 2019
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

4 participants