LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   How to install gcc-4.5.2.tar.gz2 (https://www.linuxquestions.org/questions/linux-newbie-8/how-to-install-gcc-4-5-2-tar-gz2-867135/)

newuser432 03-08-2011 01:34 AM

How to install gcc-4.5.2.tar.gz2
 
Hello,
I am running red hat in VMWARE virtual machine. I need gcc compiler. i downloaded the gcc-4.5.2.tar.gz2 file. Can't seem to install. Here is what i tried so far
1. downloaded the gz2 file
2. placed it in /home/me
3. in terminal i cd to the folder with file in it
4. gave this command that i read here in LQ
tar xvjf gcc-4.5.2.tar.bz2
5.It extracted the files in folder gcc-4.5.2
6. cd to the extracted folder
7. gave command ./configure got this error
"make:***error: in '/home/me/gcc-4.5.2':
"make:***error: no acceptable C compiler found in $PATH
8. gave command make

here is where i am getting this error that "no target specified and no makefile found. Stop"

Please help,

Nylex 03-08-2011 01:39 AM

To compile source code (which is what you've downloaded), you need to have a compiler installed. You should install gcc using your distribution's package management system, rather than trying to build from source. Presumably you're using Red Hat Enterprise Linux, so you should read the RHEL documentation to see how to use the package management system.

knudfl 03-08-2011 03:28 AM

Welcome to LQ.

Quote:

gave command ./configure got this error
Not possible. The build of GCC must be done in a build folder outside the source.

And : You cannot build a new GCC, when you have no gcc :
# yum install gcc-c++

Example, building a GCC in EL5 :
http://www.linuxquestions.org/questi...-1-a-842567/#2

..


All times are GMT -5. The time now is 02:52 PM.