[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Re: Problem Configuring Ruby Source in Linux

Brian Candler

3/1/2007 9:35:00 AM

On Thu, Mar 01, 2007 at 05:08:05PM +0900, Edward WIJAYA wrote:
> Checking build system type... i686-pc-linux-gnu
> checking host system type... i686-pc-linux-gnu
> checking target system type... i686-pc-linux-gnu
> checking for gcc... gcc
> checking for C compiler default output file name... configure: error: C
> compiler cannot create executables
> See `config.log' for more details.

which says, at the point where gcc tries to compile its first program:

...
configure:2005: gcc I/home/ewijaya/.ocaml/include
+-I/home/ewijaya/.libstree/include -I/home/ewijaya/.gsl/include
+-I/home/ewijaya/.swish/include -I/home/ewijaya/.lapack/include
+-I/home/ewijaya/.berkeley_db/include -I/home/ewijaya/.libgd/include
+-I/home/ewijaya/.graphviz/include -L/home/ewijaya/.ocaml/lib
+-L/home/ewijaya/.libstree/lib -L/home/ewijaya/.ghc/lib -L/home/ewijaya/.gsl/lib+-L/home/ewijaya/.lapack/lib -L/home/ewijaya/.swish/lib
+-L/home/ewijaya/.berkeley_db/lib -L/home/ewijaya/.libgd/lib
+-L/home/ewijaya/.graphviz/lib conftest.c >&5
gcc: I/home/ewijaya/.ocaml/include: No such file or directory
configure:2008: $? = 1
configure: failed program was:
...

Which means you have some junk in your environment. It looks like you meant
to set
CFLAGS="-I/home/ewijaya/.ocaml/include ..."
but you actually have set is
CFLAGS="I/home/ewijaya/.ocaml/include ..."

The safest thing is to get rid of any environment variables like this which
could affect compilation (CFLAGS, LDFLAGS, LD_RUN_PATH etc). Remove them
from .profile or .bash_profile or wherever else it is that you set them,
then logout and login again.

Or, being a bit more drastic, try:

env -i ./configure ...

> And GCC versin is: gcc version 3.4.6 20060404 (Red Hat 3.4.6-3)
>
> Can anybody suggest the right Ruby version
> I can install in my Linux?

Well you didn't say what Linux distribution you have, nor what version, but
I expect ruby-1.8.5 will be fine.

Of course, if you're not comfortable compiling from source, then maybe you
would be better off getting a pre-packaged ruby binary for whatever Linux
distribution you have.

Brian.