Bug #7956

Install fail with RVM

Added by Сергей Е about 1 year ago. Updated 6 months ago.

[ruby-core:52875]
Status:Third Party's Issue
Priority:Urgent
Assignee:-
Category:-
Target version:-
ruby -v:2.0.0 Backport:

Description

$ uname -a
Linux my-debian.ru 2.6.32-5-686 #1 SMP Fri Feb 15 15:48:27 UTC 2013 i686 GNU/Linux

$ $ \curl -L https://get.rvm.io | bash -s stable --ruby

...

Error running 'make', please read /home/ruby2/.rvm/log/ruby-2.0.0-p0/make.log
There has been an error while running make. Halting the installation.

/home/ruby2/.rvm/log/ruby-2.0.0-p0/make.log:

->CC = gcc
<------>LD = ld
<------>LDSHARED = gcc -shared
<------>CFLAGS = -O3 -fno-fast-math -ggdb3 -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wno-long-long -Wno-missing-field-initialize
<------>XCFLAGS = -include ruby/config.h -include ruby/missing.h -DFORTIFYSOURCE=2 -fstack-protector -fno-strict-overflow -fvisibility=hid
<------>CPPFLAGS = -I/home/ruby2/.rvm/usr/include -I. -I.ext/include/i686-linux -I./include -I.
<------>DLDFLAGS = -Wl,-soname,libruby.so.2.0 -L/home/ruby2/.rvm/usr/lib -Wl,-R/home/ruby2/.rvm/usr/lib -fstack-protector..
<------>SOLIBS = -lpthread -lrt -ldl -lcrypt -lm..
linking miniruby
rbconfig.rb unchanged
generating enc.mk
generating prelude.c
compiling prelude.c
linking static-library libruby-static.a
verifying static-library libruby-static.a
linking shared-library libruby.so.2.0.0
generating encdb.h
encdb.h unchanged
making enc
make[1]: Entering directory /home/ruby2/.rvm/src/ruby-2.0.0-p0'
make[1]: Цель
enc' не требует выполнения команд.
make[1]: Leaving directory /home/ruby2/.rvm/src/ruby-2.0.0-p0'
making srcs under enc
make[1]: Entering directory
/home/ruby2/.rvm/src/ruby-2.0.0-p0'
make[1]: Цель srcs' не требует выполнения команд.
make[1]: Leaving directory
/home/ruby2/.rvm/src/ruby-2.0.0-p0'
generating transdb.h
transdb.h unchanged
making trans
make[1]: Entering directory /home/ruby2/.rvm/src/ruby-2.0.0-p0'
compiling ./enc/trans/emoji_sjis_softbank.c
./enc/trans/emoji_sjis_softbank.c:6348:43: error: invalid suffix "y" on integer constant
make[1]: *** [enc/trans/emoji_sjis_softbank.o] Ошибка 1
make[1]: Leaving directory
/home/ruby2/.rvm/src/ruby-2.0.0-p0'
make: *** [trans] Ошибка 2

display.txt Magnifier - Output from rvm get head && rvm install 2.0.0 (2.91 KB) Neil Stoker Stoker, 02/27/2013 06:57 PM

make.log (3.5 KB) Neil Stoker Stoker, 02/27/2013 06:57 PM

miniruby_2013-03-03-205700-1_LinkSys.crash - And a variant of the diagnostic log (3.46 KB) Neil Stoker Stoker, 03/04/2013 06:11 AM

output.txt Magnifier - command line and output (2.94 KB) Neil Stoker Stoker, 03/04/2013 06:11 AM

make.log - copy of the make.log (5.14 KB) Neil Stoker Stoker, 03/04/2013 06:11 AM

miniruby_2013-03-03-205700_LinkSys.crash - the CrashReporter log (3.46 KB) Neil Stoker Stoker, 03/04/2013 06:11 AM

miniruby_2013-03-03-205700_LinkSys.crash - Diagnostic log (3.46 KB) Neil Stoker Stoker, 03/04/2013 06:11 AM

History

#1 Updated by Chris Irish about 1 year ago

I'm seeing a similar failure when trying to install Ruby 2.0.0 with RVM. Here's a gist of the RVM install command I'm running and the error output to the make.log

https://gist.github.com/supairish/5039949

#2 Updated by Marc-Andre Lafortune about 1 year ago

Can you try rvm get head && rvm install 2.0.0?

As I mentioned on my blog, rvm get stable isn't enough apparently to compile 2.0.0 in many cases.

#3 Updated by Neil Stoker Stoker about 1 year ago

I'm getting a similar failure on OSX Snow Leopard, logs attached.

#4 Updated by Michal Papis about 1 year ago

the latest version of rvm get head solves this problem by switching to clang => gcc -v | grep -i llvm && export CC=clang - only on OSX, does not make any troubles on other platforms.

#5 Updated by Marc-Andre Lafortune about 1 year ago

  • Status changed from Open to Closed

mpapis (Michal Papis) wrote:

the latest version of rvm get head solves this problem by switching to clang => gcc -v | grep -i llvm && export CC=clang - only on OSX, does not make any troubles on other platforms.

Thanks!

I'm closing this issue, but will reopen if anyone has troubles (in which case please provide logs like nstoker did)

#6 Updated by Michal Papis about 1 year ago

I was using this trick in rvm for some time to avoid the LLVM gcc errors, maybe ruby could adopt it in ./configure => gcc -v | grep -i llvm && export CC=clang

#7 Updated by Yui NARUSE about 1 year ago

mpapis (Michal Papis) wrote:

I was using this trick in rvm for some time to avoid the LLVM gcc errors, maybe ruby could adopt it in ./configure => gcc -v | grep -i llvm && export CC=clang

Ruby itself sets CC as clang, so it's not required unless rvm sets wrong CC.

Note that old clang is buggy.
See also https://github.com/sstephenson/ruby-build/issues/290#issuecomment-14013057

#8 Updated by Neil Stoker Stoker about 1 year ago

I'm still getting the error when trying to build.

What other information can I provide that would help you to track down the issue?

#9 Updated by Marc-Andre Lafortune about 1 year ago

  • Status changed from Closed to Open

Re-opening.

I also sent an email to Michal Papis.

It might be best to open this issue on rvm's side and if Michal finds a problem that ruby-core can solve he could submit that?

#10 Updated by Michal Papis about 1 year ago

=begin
I have just rechecked both with and without RVM and I can not reproduce this problem, make sure to update RVM: (({rvm get head})) - there are two things you could check:

(1) problem with compiler - check this https://github.com/wayneeseguin/rvm/issues/1660
(2) older homebrew libraries using different compilation settings, rvm has now improved code to update libraries which are outdated if you run (({rvm install 2.0.0 --autolibs=3}))

If none of those help could you please provide a log of: (({rvm install 2.0.0 --autolibs=3 --debug})) it will contain more details about the used commands.
=end

#11 Updated by Hiroshi SHIBATA about 1 year ago

  • Status changed from Open to Third Party's Issue

#12 Updated by Michal Papis about 1 year ago

Ok now RVM 1.19 now tries to use gcc-4.2 first and it fails in this case: https://github.com/wayneeseguin/rvm/issues/1731

We followed the instructions from http://bugs.ruby-lang.org/issues/7956#note-7 / https://github.com/sstephenson/ruby-build/issues/290#issuecomment-14013057 which end as:

So if you support Xcode 3.x and 4.2,

If it is OS X
    use gcc-4.2 if it exists
    use clang if it exists
    raise error
else Don't set CC

#13 Updated by Michal Papis 6 months ago

the last reported problem is unrelated to the initial one and was fixed in #8134 - it can be reclosed

Also available in: Atom PDF