LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   GCC compiler? (https://www.linuxquestions.org/questions/linux-newbie-8/gcc-compiler-119218/)

Forezt 11-23-2003 01:23 PM

GCC compiler?
 
I recently got serious in wanting to get started with linux, and more and more I realize that I am a complete n00b. I've tried to install several programs including Xine and the newest version on xscreensaver on red hat 9. My problem is: when ever I run the install in the terminal (cd .../xine-*.* | ./configure), it goes through all of that output untill it gets to "error: no acceptable C compiler found in $PATH".

I searched google for my problem and it said that I need gcc. I had no idea what gcc was, or what it stood for, but I downloaded it and tried to install it. When I went through the installation in the terminal, I got the message:

*** The command 'cc -o conftest -g conftest.c' failed.
*** You must set the enviroment variable CC to a working compiler.

I have no idea what this means! Help, anyone? Do I need another program or what? :confused:

MartinN 11-23-2003 01:36 PM

You have downloaded source code for the gcc compiler. In order to make a working compiler out of that, you'll need to have -- a working compiler.

Try installing it from rpms instead. Or pop in your RedHat CD and add gcc from that. It's probably somewhere under "Developer tools" or something like that.

This problem raises the interesting question of how the first compiler in the world was compiled. ;)

Regards
Martin

xode 11-23-2003 02:07 PM

You want to look at, get familiar with and use the RPM utilities that your RH9 provides. Based on my Mandrake 9.0, which is probably more similar than different than your RH9, you should have:

(1) a software management section in your system control panel, which would be the RH9 equivalent of Mandrake Control Center. That section should let you see what RPM packages are installed, allow you to install or uninstall RPMs and allow you to add and edit the places where the system looks for new RPMs to install. Only root should be able to access this.

(2) A packaging utility (possibly the KPackage that I have) that will allow you to examine all installed packages in great detail, including a list of what files they contain and where those files are installed on your system. That package utility will also allow you to test and examine any new RPM that you download from the net. A regular user should be able to freely examine packages but the utility will ask for root access if you want to test or (un)install packages.

(3) A utility for building RPMs, from either software that you write or from software (binaries or sources) that you download from the net. This utility will be the hardest one to master and be ready to use the command line to do it.

Now, you might ask, what do RPMs have to do with my problem? The answers are:

(1) gcc should already be installed on your system. You can find out where and with detail with the package utility that I described above.

(2) I have yet to make the procedure that you described above work, even though I didn't get the same errors. My experience is getting to be, if you want to install other people's software, use only the RPM utility that comes with your linux system. If the software that you want to install is not in RPM format then it would need to converted to RPM format using the build utility that I described above (assuming that that can be done). I suspect that the root cause of your problems here is that you are trying to install on your system software that has been written for a different linux distribution, one whose GUI is completely different and which doesn't use RPMs.

(3) if you want to write your own software, there should be a development program (kdevelop possibly) that will allow you to do it. Then you can convert your binaries into RPM before installing it.

I was recently successful in installing my first program that I downloaded from the net and that didn't come on the install CDs and it works without any problems. It is looking more and more that the RPM utility has all of the ease of use of a Windows install program and the overwhelming advantage of being completely reversible (which Windows install programs aren't).


All times are GMT -5. The time now is 12:51 AM.