Rubinius 2.2.4 install error on Centos 6.5 #2917

Closed
Allanon29 opened this Issue Feb 4, 2014 · 9 comments

Comments

Projects
None yet
4 participants

I am trying to install Rubinius with Rbenv on a Centos 6.5 VPS, but when I run
rbenv install rbx-2.2.4

UPDATE:
It seems from the error log that the RAM (512) is not enough. Strange... It was enough for MRI 2.1 and jRuby 1.7.10.
I see this line in the logfile:
g++: internal compiler error: Killed (program cc1plus)

I get this output:

Downloading yaml-0.1.5.tar.gz...
-> http://dqw8nmjcqpjn7.cloudfront.net/24f6093c1e840ca5df2eb09291a1dbf1
Installing yaml-0.1.5...
Installed yaml-0.1.5 to /home/allanon/.rbenv/versions/rbx-2.2.4

Downloading rubinius-2.2.4.tar.bz2...
-> http://dqw8nmjcqpjn7.cloudfront.net/c10699da85a8eb5861a37b29077213bd
Installing rubinius-2.2.4...

BUILD FAILED

Inspect or clean up the working tree at /tmp/ruby-build.20140204120741.22271
Results logged to /tmp/ruby-build.20140204120741.22271.log

Last 10 log lines:
vm/gen/typechecks.gen.cpp:605: note: variable tracking size limit exceeded with -fvar-tracking-assignments, retrying without
rake aborted!
Error compiling
/tmp/ruby-build.20140204120741.22271/rubinius-2.2.4/vendor/bundle/ruby/2.0.0/gems/daedalus-core-0.0.3/lib/daedalus.rb:68:in `command'
/tmp/ruby-build.20140204120741.22271/rubinius-2.2.4/vendor/bundle/ruby/2.0.0/gems/daedalus-core-0.0.3/lib/daedalus.rb:228:in `cxx_compile'
/tmp/ruby-build.20140204120741.22271/rubinius-2.2.4/vendor/bundle/ruby/2.0.0/gems/daedalus-core-0.0.3/lib/daedalus.rb:215:in `compile'
/tmp/ruby-build.20140204120741.22271/rubinius-2.2.4/vendor/bundle/ruby/2.0.0/gems/daedalus-core-0.0.3/lib/daedalus.rb:412:in `build'
/tmp/ruby-build.20140204120741.22271/rubinius-2.2.4/vendor/bundle/ruby/2.0.0/gems/daedalus-core-0.0.3/lib/daedalus.rb:873:in `block (2 levels) in perform_tasks'
Tasks: TOP => install => build:build => vm/vm

Any idea why this happens?

Owner

YorickPeterse commented Feb 4, 2014

This is probably due to gcc being a fat pig when it comes to resource usage. Personally I'd recommend compiling Rubinius using clang as it's a bit more efficient.

On CentOS you can install clang from the epel-testing repository (you can enable this in /etc/yum.repos.d/epel.repo):

sudo yum install llvm llvm-devel llvm-libs llvm-static clang clang-devel

If my mind serves me right you can tell RVM to use clang as following:

rvm install rubinius-2.2.4 -C --cc=clang,--cxx=clang++

Note that during runtime Rubinius doesn't strictly require 512MB of RAM, though this depends on the size of your application. Average production applications will probably use around 200MB of RAM.

Owner

YorickPeterse commented Feb 4, 2014

Extra note: I'm personally working on binaries for Amazon CentOS (used on EC2), if I recall correctly @brixen was messing around with binaries for stock CentOS 6.4 (I could be mistaken). The former binaries will hopefully be available in the near future.

Thanks for the suggestions. But still doesn't work...

I get this error when I try to compile with clang:

Downloading yaml-0.1.5.tar.gz...
-> http://dqw8nmjcqpjn7.cloudfront.net/24f6093c1e840ca5df2eb09291a1dbf1
Installing yaml-0.1.5...
Installed yaml-0.1.5 to /home/allanon/.rbenv/versions/rbx-2.1.0

Downloading rubinius-2.1.0.tar.bz2...
-> http://dqw8nmjcqpjn7.cloudfront.net/908053f38fd840c75a93aab7487c20a5
Installing rubinius-2.1.0...

BUILD FAILED

Inspect or clean up the working tree at /tmp/ruby-build.20140204150111.21191
Results logged to /tmp/ruby-build.20140204150111.21191.log

Last 10 log lines:
It was installed into ./vendor/bundle
------------------------- WARNING -----------------------
The specified prefix '/home/allanon/.rbenv/versions/rbx-2.1.0' already exists.
Installing Rubinius into an existing directory may
overwrite existing unrelated files or cause conflicts
between different versions of Rubinius files.
---------------------------------------------------------
Checking /usr/bin/clang: Expected /usr/bin/clang version >= 4.1, found 2.8.0

Running 'configure' failed. Please check configure.log for more details.
Owner

YorickPeterse commented Feb 4, 2014

You need to make sure that the version of clang is 3.X or newer. The "epel" repository only contains clang 2.8, "epel-testing" contains clang 3.4 (http://dl.fedoraproject.org/pub/epel/testing/6/x86_64/repoview/clang.html). Make sure that you enable the latter.

Thanks again. Now I tried with clang 3.4.

The result:

Downloading yaml-0.1.5.tar.gz...
-> http://dqw8nmjcqpjn7.cloudfront.net/24f6093c1e840ca5df2eb09291a1dbf1
Installing yaml-0.1.5...
Installed yaml-0.1.5 to /home/allanon/.rbenv/versions/rbx-2.2.4

Downloading rubinius-2.2.4.tar.bz2...
-> http://dqw8nmjcqpjn7.cloudfront.net/c10699da85a8eb5861a37b29077213bd
Installing rubinius-2.2.4...

BUILD FAILED

Inspect or clean up the working tree at /tmp/ruby-build.20140204155735.16887
Results logged to /tmp/ruby-build.20140204155735.16887.log

Last 10 log lines:
/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vendor/bundle/ruby/2.0.0/gems/daedalus-core-0.0.3/lib/daedalus.rb:68:in `command'
/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vendor/bundle/ruby/2.0.0/gems/daedalus-core-0.0.3/lib/daedalus.rb:228:in `cxx_compile'
/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vendor/bundle/ruby/2.0.0/gems/daedalus-core-0.0.3/lib/daedalus.rb:215:in `compile'
/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vendor/bundle/ruby/2.0.0/gems/daedalus-core-0.0.3/lib/daedalus.rb:412:in `build'
/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vendor/bundle/ruby/2.0.0/gems/daedalus-core-0.0.3/lib/daedalus.rb:873:in `block (2 levels) in perform_tasks'
Tasks: TOP => install => build:build => vm/vm
(See full trace by running task with --trace)
Error: /usr/bin/clang -I/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vm -I/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vm/include -I/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vm/builtin -I. -Ivm/test/cxxtest -I/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vendor/udis86 -I/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vendor/libffi/include -Ivendor/double-conversion/src -DHAVE_CONFIG_H -I/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vm/include/capi -I/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vendor/oniguruma -I/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vendor/libtommath -pipe -Wall -fno-omit-frame-pointer -g -I/usr/local/include -fPIC  -O2 -DHAS_EXECINFO -DHAVE_SPT_REUSEARGV -DHAVE_CLOCK_GETTIME -DHAVE_NL_LANGINFO -DHAVE_POSIX_FADVISE -DHAVE_STRNLEN -DHAVE_TM_GMTOFF -DHAVE_TM_ZONE -DHAVE_TIMEZONE -DHAVE_TZNAME -DHAVE_DAYLIGHT -DHAVE_ALLOCA_H -DHAVE_STRING_H -DHAVE_SYS_TIME_H -DHAVE_SYS_TIMES_H -DHAVE_SYS_TYPES_H -DHAVE_UNISTD_H -DHAVE_STDARG_H -DSTRERROR_R_CHAR_P -I/usr/include -D_GNU_SOURCE -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -fPIC -DENABLE_LLVM -Wno-unused-function -Werror -DRBX_PROFILER -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fno-rtti -fvisibility-inlines-hidden   -c -o vm/artifacts/arguments.cpp.o vm/arguments.cpp
Error: /usr/bin/clang -I/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vm -I/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vm/include -I/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vm/builtin -I. -Ivm/test/cxxtest -I/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vendor/udis86 -I/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vendor/libffi/include -Ivendor/double-conversion/src -DHAVE_CONFIG_H -I/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vm/include/capi -I/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vendor/oniguruma -I/tmp/ruby-build.20140204155735.16887/rubinius-2.2.4/vendor/libtommath -pipe -Wall -fno-omit-frame-pointer -g -I/usr/local/include -fPIC  -O2 -DHAS_EXECINFO -DHAVE_SPT_REUSEARGV -DHAVE_CLOCK_GETTIME -DHAVE_NL_LANGINFO -DHAVE_POSIX_FADVISE -DHAVE_STRNLEN -DHAVE_TM_GMTOFF -DHAVE_TM_ZONE -DHAVE_TIMEZONE -DHAVE_TZNAME -DHAVE_DAYLIGHT -DHAVE_ALLOCA_H -DHAVE_STRING_H -DHAVE_SYS_TIME_H -DHAVE_SYS_TIMES_H -DHAVE_SYS_TYPES_H -DHAVE_UNISTD_H -DHAVE_STDARG_H -DSTRERROR_R_CHAR_P -I/usr/include -D_GNU_SOURCE -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -fPIC -DENABLE_LLVM -Wno-unused-function -Werror -DRBX_PROFILER -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fno-rtti -fvisibility-inlines-hidden   -c -o vm/artifacts/agent_components.cpp.o vm/agent_components.cpp
20 errors generated.
Owner

dbussink commented Feb 4, 2014

Can you please link the full log? This seems to miss all the essential information.

Owner

YorickPeterse commented Feb 4, 2014

Looking at the last bit it seems clang is used for C++ files, not clang++. Maybe my RVM line was incorrect but make sure that the --cxx option is set to clang++.

To give an example, the manual way would look like this:

./configure --cc=clang --cxx=clang++

@YorickPeterse ./configure --cc=clang --cxx=clang++ did the trick for Rubinius 2.2.6 on CentOS 6.5 with llvm 3.4. Thanks!

Owner

YorickPeterse commented May 22, 2014

Closing this due to the lack of further information. Feel free to re-open if needed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment