compiling ruby on red hat linux

  • Thread starter Philip J. Mikal
  • Start date
P

Philip J. Mikal

Hi,

I'm having no luck compiling Ruby - getting the
following error:

make[1]: Entering directory
`/usr/local/src/ruby/ext/iconv'
gcc -fPIC -g -O2 -I. -I../.. -I../../.
-I../.././ext/iconv -DICONV_INPTR_CAST=3D"(char **)" -c
iconv.c
gcc323: **): No such file or directory
iconv.c: In function `iconv_try':
iconv.c:246: parse error before "inptr"
make[1]: *** [iconv.o] Error 1
make[1]: Leaving directory
`/usr/local/src/ruby/ext/iconv'
make: *** [all] Error 1

Any ideas?

-Philip
 
P

Philip J. Mikal

Yes!

--- Joe Van Dyk said:
Did you run the configure script?
=20
Hi,
=20
I'm having no luck compiling Ruby - getting the
following error:
=20
make[1]: Entering directory
`/usr/local/src/ruby/ext/iconv'
gcc -fPIC -g -O2 -I. -I../.. -I../../.
-I../.././ext/iconv -DICONV_INPTR_CAST=3D"(char **)" -c
iconv.c
gcc323: **): No such file or directory
iconv.c: In function `iconv_try':
iconv.c:246: parse error before "inptr"
make[1]: *** [iconv.o] Error 1
make[1]: Leaving directory
`/usr/local/src/ruby/ext/iconv'
make: *** [all] Error 1
=20
Any ideas?
=20
-Philip
=20
=20
=20
=20
 
A

Ara.T.Howard

Hi,

I'm having no luck compiling Ruby - getting the
following error:

make[1]: Entering directory
`/usr/local/src/ruby/ext/iconv'
gcc -fPIC -g -O2 -I. -I../.. -I../../.
-I../.././ext/iconv -DICONV_INPTR_CAST="(char **)" -c
iconv.c
gcc323: **): No such file or directory
iconv.c: In function `iconv_try':
iconv.c:246: parse error before "inptr"
make[1]: *** [iconv.o] Error 1
make[1]: Leaving directory
`/usr/local/src/ruby/ext/iconv'
make: *** [all] Error 1

Any ideas?

-Philip

~ > tar xvfz ruby.tgz
~ > cd ruby/
~ > export prefix=/full/path/to/where/you/want/to/install # eg. /usr/local/
~ > export LD_RUN_PATH=$prefix
~ > export LD_LIBRARY_PATH=$prefix
~ > ./configure --prefix=$prefix && make && sudo make install

hth.

-a
--
===============================================================================
| email :: ara [dot] t [dot] howard [at] noaa [dot] gov
| phone :: 303.497.6469
| Your life dwells amoung the causes of death
| Like a lamp standing in a strong breeze. --Nagarjuna
===============================================================================
 
P

Philip J. Mikal

Thanks for the suggestion, but same results as before:

compiling iconv
make[1]: Entering directory
`/usr/local/src/ruby-1.8.2/ext/iconv'
gcc -fPIC -g -O2 -I. -I../.. -I../../.
-I../.././ext/iconv -DICONV_INPTR_CAST=3D"(char **)" -c
iconv.c
gcc323: **): No such file or directory
iconv.c: In function `iconv_try':
iconv.c:231: parse error before "inptr"
make[1]: *** [iconv.o] Error 1
make[1]: Leaving directory
`/usr/local/src/ruby-1.8.2/ext/iconv'
make: *** [all] Error 1
[root@misha-server2 ruby-1.8.2]#=20
 
S

speechexpert

I am interested in writing a debugger that single-steps, highlights lines,
displays variables, etc.

Any Recommendations for a GUI to work in? Should be simple, I hope. Rails?

JB
 
C

Curt Hibbs

------=_Part_2164_29055417.1126224329111
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

=20
I am interested in writing a debugger that single-steps, highlights lines= ,
displays variables, etc.
=20
Any Recommendations for a GUI to work in? Should be simple, I hope. Rails= ?
=20
There is already one in FreeRIDE (http://freeride.rubyforge.org/), perhap=
s=20
you could contribute to improving it instead of starting from scratch. It=
=20
uses the FXRuby/FOX GUI library.

Curt

------=_Part_2164_29055417.1126224329111--
 
N

nobu.nokada

Hi,

At Fri, 9 Sep 2005 04:25:29 +0900,
Philip J. Mikal wrote in [ruby-talk:155369]:
I'm having no luck compiling Ruby - getting the
following error:

It works for me, with gcc 3.4.2 on Redhat.
make[1]: Entering directory
`/usr/local/src/ruby/ext/iconv'
gcc -fPIC -g -O2 -I. -I../.. -I../../.
-I../.././ext/iconv -DICONV_INPTR_CAST="(char **)" -c
iconv.c
gcc323: **): No such file or directory

What's this gcc323? Why does it differ from the command called
by make?
 
P

Philip J. Mikal

Hi Nobu,

It looks like my gcc is bombing out on:

-DICONV_INPTR_CAST=3D"(char **)"

Any ideas?

Thanks,

Philip

--- [email protected] said:
Hi,
=20
At Fri, 9 Sep 2005 04:25:29 +0900,
Philip J. Mikal wrote in [ruby-talk:155369]:
I'm having no luck compiling Ruby - getting the
following error:
=20
It works for me, with gcc 3.4.2 on Redhat.
=20
make[1]: Entering directory
`/usr/local/src/ruby/ext/iconv'
gcc -fPIC -g -O2 -I. -I../.. -I../../.
-I../.././ext/iconv -DICONV_INPTR_CAST=3D"(char **)" -c
iconv.c
gcc323: **): No such file or directory
=20
What's this gcc323? Why does it differ from the
command called
by make?
=20
--=20
Nobu Nakada
=20
=20
 
N

nobu.nokada

Hi,

At Fri, 9 Sep 2005 11:12:52 +0900,
Philip J. Mikal wrote in [ruby-talk:155397]:
It looks like my gcc is bombing out on:

-DICONV_INPTR_CAST="(char **)"

What is `your gcc'? Maybe a wrapper script?
Try:

type -a gcc
file `type -p gcc`
 
P

Philip J. Mikal

Hi Nobu,

Yes, it looks like a wrapper script.

[root@server2 src]# type -a gcc
gcc is /usr/bin/gcc
[root@server2 src]# file `type -p gcc`
/usr/bin/gcc: Bourne shell script text executable

Here is the script:

#!/bin/sh

if id | grep -q gcc296; then
#Use the compat gcc
exec /usr/bin/gcc296 $@
elif [ -n "$GCC296" ]; then
# Use the compat gcc
exec /usr/bin/gcc296 $@
else
# Use the standard gcc
exec /usr/bin/gcc323 $@
fi

I symlinked gcc to gcc323 and now it works!=20

I've run into this problem on a few boxes and they are
all Red Hat 9. I'm suprised this problem hasn't shown
up before.

Maybe there is a better way to set up the -D arg to
iconv to support legacy distros with this shell
wrapper?=20

Thanks for your help!

-Philip

--- [email protected] said:
Hi,
=20
At Fri, 9 Sep 2005 11:12:52 +0900,
Philip J. Mikal wrote in [ruby-talk:155397]:
It looks like my gcc is bombing out on:
=20
-DICONV_INPTR_CAST=3D"(char **)"
=20
What is `your gcc'? Maybe a wrapper script?
Try:
=20
type -a gcc
file `type -p gcc`
=20
--=20
Nobu Nakada
=20
=20
 
N

nobu.nokada

Hi,

At Fri, 9 Sep 2005 12:57:26 +0900,
Philip J. Mikal wrote in [ruby-talk:155413]:
Here is the script:

#!/bin/sh

if id | grep -q gcc296; then
#Use the compat gcc
exec /usr/bin/gcc296 $@
elif [ -n "$GCC296" ]; then
# Use the compat gcc
exec /usr/bin/gcc296 $@
else
# Use the standard gcc
exec /usr/bin/gcc323 $@
fi

They must be "$@" instead of mere $@.
I've run into this problem on a few boxes and they are
all Red Hat 9. I'm suprised this problem hasn't shown
up before.

What package contains the script? What does following command
show?

rpm -qif /usr/bin/gcc
 
S

speechexpert

Thanks Curt - My mission is a bit more complicated han a Ruby debugger
though -
I am looking at a debugger for an interpreter written in Ruby for another
language.
But the FreeRIDE debugger could be modified, since it will debug Ruby code.
The trick is getting it to stop only on certain statements and display
variables in the original language. hmmmm

Do you use FreeRIDE?
curious,
John B

----- Original Message -----
From: "Curt Hibbs" <[email protected]>
To: "ruby-talk ML" <[email protected]>
Sent: Thursday, September 08, 2005 5:05 PM
Subject: Re: Windows GUI Suggestions


I am interested in writing a debugger that single-steps, highlights lines,
displays variables, etc.

Any Recommendations for a GUI to work in? Should be simple, I hope. Rails?

There is already one in FreeRIDE (http://freeride.rubyforge.org/), perhaps
you could contribute to improving it instead of starting from scratch. It
uses the FXRuby/FOX GUI library.

Curt
 
C

Curt Hibbs

------=_Part_3099_33017575.1126279213318
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

=20
Thanks Curt - My mission is a bit more complicated han a Ruby debugger
though -
I am looking at a debugger for an interpreter written in Ruby for another
language.
But the FreeRIDE debugger could be modified, since it will debug Ruby=20
code.
The trick is getting it to stop only on certain statements and display
variables in the original language. hmmmm
=20
Do you use FreeRIDE?
curious,
John B


I'm one of the original authors of FreeRIDE. If you want to explore the=20
option of reusing the FreeRIDE debugger, then the best thing would be to=20
subscribe to the FreeRIDE mailing list and post questions there for Laurent=
=20
Julliard -- the guy who wrote the FreeRIDE debugger.

Curt

------=_Part_3099_33017575.1126279213318--
 
P

Philip J. Mikal

Hi Nobu,

Name : gcc =20
Relocations: (not relocateable)
Version : 3.2.2 =20
Vendor: Red Hat, Inc.
Release : 5 Build
Date: Tue 25 Feb 2003 05:53:15 AM PST
Install Date: Wed 01 Dec 2004 04:57:40 PM PST =20
Build Host: stripples.devel.redhat.com
Group : Development/Languages Source
RPM: gcc-3.2.2-5.src.rpm
Size : 11592745 =20
License: GPL
Signature : DSA/SHA1, Tue 25 Feb 2003 07:04:13 AM
PST, Key ID 219180cddb42a60e
Packager : Red Hat, Inc.
<http://bugzilla.redhat.com/bugzilla>
URL : http://gcc.gnu.org
Summary : The GNU cc and gcc C compilers.
Description :
The gcc package includes the cc and gcc GNU compilers
for compiling C
code.

-Philip

--- [email protected] said:
Hi,
=20
At Fri, 9 Sep 2005 12:57:26 +0900,
Philip J. Mikal wrote in [ruby-talk:155413]:
Here is the script:
=20
#!/bin/sh
=20
if id | grep -q gcc296; then
#Use the compat gcc
exec /usr/bin/gcc296 $@
elif [ -n "$GCC296" ]; then
# Use the compat gcc
exec /usr/bin/gcc296 $@
else
# Use the standard gcc
exec /usr/bin/gcc323 $@
fi
=20
They must be "$@" instead of mere $@.
=20
I've run into this problem on a few boxes and they are
all Red Hat 9. I'm suprised this problem hasn't shown
up before.
=20
What package contains the script? What does
following command
show?
=20
rpm -qif /usr/bin/gcc
=20
--=20
Nobu Nakada
=20
=20
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,055
Latest member
SlimSparkKetoACVReview

Latest Threads

Top