Operating System - Linux
1830251 Members
2667 Online
110000 Solutions
New Discussion

How to make the c complier working

 
Binu_5
Regular Advisor

How to make the c complier working

Hi All

I have downloaded gcc-4.0.2 from the net and copied to my Linux server ..How to make it working .. How to test the same

PLease help

Binu
4 REPLIES 4
Binu_5
Regular Advisor

Re: How to make the c complier working

Hi All

When I run the follwing command the below
mentioned err is popping up ..

Please help
-Binu



/usr/local/gcc/gcc-4.0.2/configure

creating cache ./config.cache
checking host system type... i686-pc-linux-gnu
checking target system type... i686-pc-linux-gnu
checking build system type... i686-pc-linux-gnu
checking for a BSD compatible install... /usr/bin/install -c
checking whether ln works... yes
checking whether ln -s works... yes
checking for gcc... no
checking for cc... no
configure: error: no acceptable cc found in $PATH

debian111
Regular Advisor

Re: How to make the c complier working

try ./configure
then
2.make
3. make install
in folder where is your gcc-4.0.2

write some program in c
then cc programname.c -o pragramname

to test it.

Regards
Matti_Kurkela
Honored Contributor

Re: How to make the c complier working

You have downloaded a source package for gcc-4.02. To make it usable, you need to compile it... and you will need a compiler for that.

Check the installation disks for your Linux distribution: there should be a packaged gcc. Just install it first. It may request that you install several other packages as dependencies, do that.

After that, you should have a working C compiler. If you specifically need gcc-4.0.2 and your distribution has an older version of gcc, now you can use the old compiler to make the new one.
MK
Vipulinux
Respected Contributor

Re: How to make the c complier working

Download gcc rpm if you are using redhat:

http://rpmfind.net/linux/rpm2html/search.php?query=gcc

Cheers