Ruby compile error on new slicehost.com vps

I just purchased a centOS5 vps from slicehost.com earlier today.

I have installed the following so far:

yum install httpd
yum install glibc
yum install gcc
yum install gcc-c++
yum install make

I downloaded ruby 1.8.6 and can ./configure just fine

when i try to make it gets about half way through then gets this error:

compiling nkf
make[1]: Entering directory /usr/local/src/ruby-1.8.6/ext/nkf' gcc -I. -I../.. -I../../. -I../.././ext/nkf -fPIC -g -O2 -c nkf.c nkf.c:654: internal compiler error: Segmentation fault Please submit a full bug report, with preprocessed source if appropriate. See <URL:http://bugzilla.redhat.com/bugzilla> for instructions. The bug is not reproducible, so it is likely a hardware or OS problem. make[1]: *** [nkf.o] Error 1 make[1]: Leaving directory /usr/local/src/ruby-1.8.6/ext/nkf’
make: *** [all] Error 1

I haven’t had any issues compiling on other Redhat Linux Server. Do you
know what the problem could be? I couldn’t find anything on google yet.

thanks!

nevermind. i figured it out. i had to run the following:

yum install compat-gcc-34-g77.x86_64
yum install compat-gcc-34-c++.x86_64

Scott K. wrote:

nevermind. i figured it out. i had to run the following:

yum install compat-gcc-34-g77.x86_64
yum install compat-gcc-34-c++.x86_64

oops…i guess i have another problem.

im trying to install rails with gem and i’m getting the following:

gem install rails --include-dependencies

INFO: gem install -y is now default and will be removed
INFO: use --ignore-dependencies to install only the gems you list
Bulk updating Gem source index for: http://gems.rubyforge.org/
/usr/local/lib/ruby/site_ruby/1.8/rubygems/specification.rb:554: [BUG]
Segmentation fault
ruby 1.8.6 (2007-03-13) [x86_64-linux]

any ideas?

On 26 Jun 2008, at 21:04, Scott K. wrote:

Is your ruby the very latest and greatest? 1.8.6p230 is known to
segfault.

Fred

Frederick C. wrote:

On 26 Jun 2008, at 21:04, Scott K. wrote:

Is your ruby the very latest and greatest? 1.8.6p230 is known to
segfault.

Fred

it is ruby 1.8.6 (2007-03-13 patchlevel 0) [x86_64-linux]

i tried it again and it’s getting farther…at least it installed some
gems this time before it seg faulted.

gem install rails --include-dependencies
INFO: gem install -y is now default and will be removed
INFO: use --ignore-dependencies to install only the gems you list
Bulk updating Gem source index for: http://gems.rubyforge.org/
Successfully installed rake-0.8.1
Successfully installed activesupport-2.1.0
Successfully installed activerecord-2.1.0
Successfully installed actionpack-2.1.0
Successfully installed actionmailer-2.1.0
Successfully installed activeresource-2.1.0
Successfully installed rails-2.1.0
7 gems installed
Installing ri documentation for rake-0.8.1…
Installing ri documentation for activesupport-2.1.0…
/usr/local/lib/ruby/1.8/irb/slex.rb:204: [BUG] Segmentation fault
ruby 1.8.6 (2007-03-13) [x86_64-linux]

Aborted

i’ll keep trying.

Frederick C. wrote:

On 26 Jun 2008, at 21:15, Scott K. wrote:

it is ruby 1.8.6 (2007-03-13 patchlevel 0) [x86_64-linux]
i’d try the latest patch level before 230

Fred

ok i downloaded patch level 114

now i’m getting errors trying to compile that:

[ruby-1.8.6-p114]# make
pack.c: In function ‘pack_unpack’:
pack.c:2120: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See URL:http://bugzilla.redhat.com/bugzilla for instructions.
The bug is not reproducible, so it is likely a hardware or OS problem.
make: *** [pack.o] Error 1

then if i run make again (and anytime after) i get this error:

[ruby-1.8.6-p114]# make
gcc -g -O2 -DRUBY_EXPORT -D_GNU_SOURCE=1 -I. -I. -c pack.c
gcc -g -O2 -DRUBY_EXPORT -D_GNU_SOURCE=1 -I. -I. -c parse.c
parse.c: In function ‘ruby_yyparse’:
parse.c:4074: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See URL:http://bugzilla.redhat.com/bugzilla for instructions.
The bug is not reproducible, so it is likely a hardware or OS problem.
make: *** [parse.o] Error 1

hmm…this is frustrating since it installed so easy on my 32-bit intel
redhat es3.

is there some standard versions i should be using for 64-bit amd centOS
5?

do you think i should try the newest gem? i am running 1.1.1 and i just
noticed there is 1.2.0.

On Jun 26, 9:37 pm, Scott K. [email protected]
wrote:

hmm…this is frustrating since it installed so easy on my 32-bit intel
redhat es3.

is there some standard versions i should be using for 64-bit amd centOS
5?

no idea, but have you tried any of the slicehost installation guides?

Fred

do you think i should try the newest gem? i am running 1.1.1 and i just
noticed there is 1.2.0.

If gcc or ruby are segfaulting then something is quite screwed. No
ruby code should ever be able to crash the interpreter itself.

On 26 Jun 2008, at 21:15, Scott K. wrote:

it is ruby 1.8.6 (2007-03-13 patchlevel 0) [x86_64-linux]
i’d try the latest patch level before 230

Fred

On Thu, 2008-06-26 at 22:37 +0200, Scott K. wrote:

now i’m getting errors trying to compile that:
then if i run make again (and anytime after) i get this error:
make: *** [parse.o] Error 1

hmm…this is frustrating since it installed so easy on my 32-bit intel
redhat es3.

is there some standard versions i should be using for 64-bit amd centOS
5?

do you think i should try the newest gem? i am running 1.1.1 and i just
noticed there is 1.2.0.


just out of curiosity, why aren’t you using the 1.8.5 ruby packages that
are standard with CentOS-5 ?

and fyi, you could probably just rebuild the source rpms for 1.8.6-114
from Fedora 9 (not the 1.8.6-230 in Fedora 9 updates) - I haven’t tried
it myself though.

Craig

i waited a little bit then tried to run:

[rubygems-1.1.1]# gem install rails --include-dependencies
INFO: gem install -y is now default and will be removed
INFO: use --ignore-dependencies to install only the gems you list
Updating metadata for 4 gems from http://gems.rubyforge.org/

complete
Bulk updating Gem source index for: http://gems.rubyforge.org/
Successfully installed rails-2.1.0
1 gem installed

looks like it installed that time. i wonder if i am going to have
problems in the future. I checked for guides on slicehost but didn’t
find any specifically for centOS and ruby so i figured i would try
myself.

oh one more thing…is there any easy way to remove the 1.8.6 rails
install i did from the source code? its installed in /usr/local/bin/

Craig W. wrote:

On Thu, 2008-06-26 at 22:37 +0200, Scott K. wrote:

now i’m getting errors trying to compile that:
then if i run make again (and anytime after) i get this error:
make: *** [parse.o] Error 1

hmm…this is frustrating since it installed so easy on my 32-bit intel
redhat es3.

is there some standard versions i should be using for 64-bit amd centOS
5?

do you think i should try the newest gem? i am running 1.1.1 and i just
noticed there is 1.2.0.


just out of curiosity, why aren’t you using the 1.8.5 ruby packages that
are standard with CentOS-5 ?

and fyi, you could probably just rebuild the source rpms for 1.8.6-114
from Fedora 9 (not the 1.8.6-230 in Fedora 9 updates) - I haven’t tried
it myself though.

Craig

well i have 1.8.6 installed on my other redhat development server so i
figured i should keep the versions the same.

i did see yum had some 1.8.5 packages that i’ll try installing. thanks!

what distro do you guys usually run rails under? all the tutorials on
slicehost are either for ubuntu or debian.

On Thu, 2008-06-26 at 23:32 +0200, Scott K. wrote:

well i have 1.8.6 installed on my other redhat development server so i
figured i should keep the versions the same.

i did see yum had some 1.8.5 packages that i’ll try installing. thanks!

what distro do you guys usually run rails under? all the tutorials on
slicehost are either for ubuntu or debian.


I use Fedora for development

I use CentOS 5 for server

I don’t run into issues but I will say that I’m still on 1.2.6 rails

Consider though that CentOS is an rpm system and it doesn’t make much
sense to compile from source but rather to package and install/upgrade
rpm’s. If you want really want newer versions than the ‘stable’
CentOS/RHEL, you probably should just rebuild from Fedora source rpms
when possible.

Craig

On Thu, 2008-06-26 at 23:37 +0200, Scott K. wrote:

oh one more thing…is there any easy way to remove the 1.8.6 rails
install i did from the source code? its installed in /usr/local/bin/


and by the way…

yum install ruby ruby-devel ruby-irb ruby-rdoc ruby-mode ruby-libs
ruby-doc

should get it done…

rpm -qa|grep ruby

ruby-libs-1.8.5-5.el5_1.1
ruby-ldap-0.9.7-1
ruby-irb-1.8.5-5.el5_1.1
ruby-devel-1.8.5-5.el5_1.1
ruby-mode-1.8.5-5.el5_1.1
ruby-docs-1.8.5-5.el5_1.1
ruby-1.8.5-5.el5_1.1
ruby-ri-1.8.5-5.el5_1.1
ruby-rdoc-1.8.5-5.el5_1.1

Craig

On Thu, 2008-06-26 at 23:37 +0200, Scott K. wrote:

oh one more thing…is there any easy way to remove the 1.8.6 rails
install i did from the source code? its installed in /usr/local/bin/


always tricky but if you did a ‘make install’ - try going to the same
build directory and try running ‘make uninstall’

Craig

I’m have multiple Centos 5 server running 1.8.6 and 1.8.7 and have
never seen issues like this… (Both 64bit and 32bit btw)

The first thing that I always do is remove any of the supplied ruby
installs that are provided with the os.

Currently I’m using gems 1.1.1

I know this does not help but just fyi…

I start with a centos5 box that is stripped to the bone then run this
command:

yum groupinstall “Development Libraries”

Here is a list of other groups that are installed:

Installed Groups:
Development Libraries
Editors
System Tools
Text-based Internet
Network Servers
Legacy Software Development
Mail Server
Server Configuration Tools
Administration Tools

Craig W. wrote:

On Thu, 2008-06-26 at 23:37 +0200, Scott K. wrote:

oh one more thing…is there any easy way to remove the 1.8.6 rails
install i did from the source code? its installed in /usr/local/bin/


always tricky but if you did a ‘make install’ - try going to the same
build directory and try running ‘make uninstall’

Craig

thanks for all the info craig. yea, no make uninstall for these
downloads. i think it might be best just to do a fresh reload of my
server and install all the ruby packages from yum.

which version of gem do you think i should go with? that latest 1.2.0
or something earlier?

thanks again for all the help so far!

heimdull wrote:

I’m have multiple Centos 5 server running 1.8.6 and 1.8.7 and have
never seen issues like this… (Both 64bit and 32bit btw)

The first thing that I always do is remove any of the supplied ruby
installs that are provided with the os.

Currently I’m using gems 1.1.1

I know this does not help but just fyi…

I start with a centos5 box that is stripped to the bone then run this
command:

yum groupinstall “Development Libraries”

Here is a list of other groups that are installed:

Installed Groups:
Development Libraries
Editors
System Tools
Text-based Internet
Network Servers
Legacy Software Development
Mail Server
Server Configuration Tools
Administration Tools

ok i just reloaded my os from scratch. the first thing i tried to do
was:

yum groupinstall “Development Libraries”

–> Processing Dependency: libXinerama.so.1 for package: gtk2
–> Processing Dependency: libXi.so.6 for package: gtk2
–> Processing Dependency: libesd.so.0()(64bit) for package: libgnome
–> Processing Dependency: libavahi-glib.so.1 for package: gnome-vfs2
–> Processing Dependency: libXrandr.so.2()(64bit) for package: gtk2
–> Processing Dependency: libavahi-client.so.3()(64bit) for package:
gnome-vfs2
–> Processing Dependency: libXau.so.6 for package: libX11
–> Processing Dependency: libhal.so.1 for package: gnome-vfs2
–> Processing Dependency: glibc-common = 2.5-18.el5_1.1 for package:
glibc
Error: No Package Matching glibc.i686

and when i do run

[root@webapp1 ~]# yum list | grep glibc.i686
glibc.i686 2.5-18.el5_1.1
installed
glibc.i686 2.5-24 base

why do you think the groupinstall isn’t finding this package?

this groupinstall would be very useful if i could get it working and
save me a ton of individual package installs.

On Thu, 2008-06-26 at 23:46 +0200, Scott K. wrote:

thanks for all the info craig. yea, no make uninstall for these
downloads. i think it might be best just to do a fresh reload of my
server and install all the ruby packages from yum.

which version of gem do you think i should go with? that latest 1.2.0
or something earlier?

thanks again for all the help so far!


You could easily enough clean out /usr/local/bin without re-installing
but that’s up to you. ‘make uninstall’ would have been nice but that’s a
strong argument for not installing from source but rather building rpm’s
and installing from rpm’s

I’m still on 0.9.4 on my CentOS-5 server…

gem -v

0.9.4

and on my fedora development system…
$ gem -v
1.1.1

But to be honest, I don’t pay much attention to the version of gem but
do pay attention to the other versions of gems that I use

Craig

On Fri, 2008-06-27 at 00:07 +0200, Scott K. wrote:

System Tools
yum groupinstall “Development Libraries”
→ Processing Dependency: glibc-common = 2.5-18.el5_1.1 for package:
why do you think the groupinstall isn’t finding this package?

this groupinstall would be very useful if i could get it working and
save me a ton of individual package installs.


probably a bit rude to conduct this on ruby list because CentOS has a
list for this sort of thing…

http://lists.centos.org/mailman/listinfo/centos

I would immediately after install do…

yum clean all
yum upgrade # because they JUST released CentOS-5.2 a few days ago.

before I tried this group install thing. You can see from the above that
what they consider ‘base’ is newer than what you have installed.

Craig