LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   how can I start gcc after install (https://www.linuxquestions.org/questions/linux-newbie-8/how-can-i-start-gcc-after-install-59970/)

Rgamboa 05-15-2003 03:40 PM

how can I start gcc after install
 
Hi all I recently downloaded the gcc compile and installed it from an rpm. When I start to compile it give me this error message.
Checking for cygwin environment...... no
Checking for mingw32 environment....... no
Checking for working sed ....... sed
Checking host system type ..... i686-pc-linux-gnulibc1
Checking for gcc ..... gcc
Checking whether the C Compiler (gcc) works ....... no
configure: error: installation or configuration problem: C compiler cannot create executables.

Can anybody tell me what is going on. I am new to the RH 8
I have installed the gcc compile off a rpm.

BigNate 05-15-2003 03:59 PM

hmmm. your post is a little confusing. Did you:

$rpm -ivh gcc*.rpm # I assume that is what you mean when you say you *compiled* and installed from rpm??? Or was this a src.rpm??

Are you then trying to compile a C program with gcc and getting the errors or are those errors from trying to rpm gcc??

Rgamboa 05-15-2003 04:02 PM

sorry for the confusion
 
Yes I installed the gcc from an rpm successfully and I thought I could compile a php tar file but I get that error

BigNate 05-15-2003 04:18 PM

ok...I don't no much about compiled programming, however looking at the error messages you are getting I have to ask:
1. Is php a compiled lang?? # I thought it was interpreted, but I never even looked at it...so...if it is...
2 Does gcc handle php # I know it will compile C C++ ada, Fortran etc...but the man pages I just cruised thru make no mention of php.
3. If the answer to both q's above are yes then it looks to me like you are missing some important files OR gcc was corrupted somehow during install.

Rgamboa 05-15-2003 04:41 PM

thank you
 
I will look into it some more. I got a long question for you.
What if I download the php rpm for apache and install it where would the php files go (to what directory). I need to configure php to run in Apache since I have all my web page in php.

When I did the installation of RH 8 apache is installed in the /etc/httpd/conf/httpd.conf

How will I get apache to know where the php files are?

Thank for your time

david_ross 05-15-2003 04:45 PM

He isn't trying to compile php pages he is trying to install php.

Yes! Go with the rpms that is what they are designed for. After you have installed the rpm you will need to add a LoadModule and an AddType line to your httpd.conf file.

BigNate 05-16-2003 06:24 AM

Quote:

Originally posted by david_ross
He isn't trying to compile php pages he is trying to install php.

Yes! Go with the rpms that is what they are designed for.

Good enough...I have no idea what php is used for..heh, never had the need I guess. However, while I was googleing I did notice an awful lot of talk concerning a php.rpm...hmmmmm, So he was rpm'ing gcc to compile php (ahhh, now I see) :)

I'm sure somewhere on this site there has to be a recomendation to use rpms whenever possible (on an rpm based distro), however I read a ton of posts here everyday that show someone using source installs on their redhat box and they are having a hell of a time making it work...I guess for the newer user it must be confusing. They want a certain piece of software and so the figure they are going to need to *make* it. Plus I'm sure the RH/MDK crowd get even further afield when they read about all the slackers that frequent here and the instructions appear to suggest that the way one installs new software is with the make util./gcc...etc. oh well, if anyone is reading this thread...use rps if you have an rpm based distro.

david_ross 05-16-2003 07:07 AM

I agree - use rpms if you have an prm distro unless you need the program to be compiled differently from the default. The reason most people have problems compiling programs on RedHat is that the appications used for compiling are listed under a section called "Software Devlopment" Most people therefore assume that there is no need to install them unless they are going to develop software and they therefore can't compile software when neccessary.

MasterC 05-16-2003 07:19 AM

I don't agree, and guess this thread is as good as any to start a "RPM vs source" debate. :)

To me, RPM's create problems amongst themselves so bad that it isn't worth the seldom "ease" involved in installing them. You nearly always have to download a package management tool to satisfy dependencies. More than that, you don't (easily) get packages optimized for your architecture/needs.

RPM's are really more of a waste of time and can even be more of a hassle at times than source packages. They create a false sense of accomplishment/security that you are a linux guru because you can type:
rpm -ivh packagename.rpm

Source packages however are much more versatile, much more common, come (sometimes/usually) in a smaller package, run into MUCH less dependendencies, satisfy more dependencies as well, and just overall give a much less of a headache (in the long run).

The happy medium, even though I've never used it (yet) would be portage. Gentoo's package management system combines the ease of a single install application manager:
emerge mplayer
And downloads/installs mplayer from source tailored to your needs. I really think it's the best thing to have come about for package management in linux, and wish it'd get more widespread use (like RPM has, and RPM sucks).

Anyway, enough of my rant... RPM sucks IM-not-so-humble-in-this-situation-O

;)

www.apachetoolkit.com

Cool

BigNate 05-16-2003 07:55 AM

Quote:

Originally posted by MasterC
I don't agree, and guess this thread is as good as any to start a "RPM vs source" debate. :)

To me, RPM's create problems amongst themselves so bad that it isn't worth the seldom "ease" involved in installing them. You nearly always have to download a package management tool to satisfy dependencies. More than that, you don't (easily) get packages optimized for your architecture/needs.

RPM's are really more of a waste of time and can even be more of a hassle at times than source packages. They create a false sense of accomplishment/security that you are a linux guru because you can type:
rpm -ivh packagename.rpm

Source packages however are much more versatile, much more common, come (sometimes/usually) in a smaller package, run into MUCH less dependendencies, satisfy more dependencies as well, and just overall give a much less of a headache (in the long run).

The happy medium, even though I've never used it (yet) would be portage. Gentoo's package management system combines the ease of a single install application manager:
emerge mplayer
And downloads/installs mplayer from source tailored to your needs. I really think it's the best thing to have come about for package management in linux, and wish it'd get more widespread use (like RPM has, and RPM sucks).

Anyway, enough of my rant... RPM sucks IM-not-so-humble-in-this-situation-O

;)

WHAT !!!!!:)

I won't argue that RPM has it's share of issues but it is sub-optimal at best to try to install source on an rpm machine (absolutely possible, but difficult)...I spend a few hours every week talking a new user down after he tried to install a tar.gz pkg instead of a common rpm. rpm is *not* the be all end all, but if you couple it with apt4rpm you can accomplish a lot. I agree it will not solve all software issues, but for most desktop hobbists they may never need another tool. If you want to learn how linux ticks then yes at some point I suggest one should seek out raw code, compile/make it...but leave that until you know what a tarball is. :)

whansard 05-16-2003 07:59 AM

his compiler isn't working.
i've gotten that error before, but i can't remember
what stuff was missing, probably some header rpm's,
maybe it's glibc development rpm or something like that

you could still search on "C compiler cannot create executables"

Rgamboa 05-16-2003 11:06 AM

thanks, I tried installing the php rpm but I get failed depend... err
most of my web pages are php and without the modules the webserver serves them as plain text. I tried reinstalling the gcc rpm but it tells me that it is installed. Yet I tried to compile the php.tar.gz file and I get err message that the C compiler can't create exe.
Where can I find the gcc after the rpm install. what commands can I check to see if it is running

david_ross 05-16-2003 12:39 PM

gcc isn't a server so you can't "see if it is running" it is a program that is used to compile other prgrams from source.

typing:
whereis gcc

should confirm that it exists but that has already be confirmed by the configure script. The chances are that you don't have write access to the compilation directory or you don't have all of the required development libraries required.

If I was you I would use the RH CDs to install ALL of the "software development" section. This should cover most of your compile problems in the future too. Like I said (sorry to disagree MasterC ;)) RPMs are usually fine for most purposes. I grant you that they aren't optimised or anything but they are much easier to install and even if you do get failed dependancies they can usually be solved by installing another package or two.

In all honesty though I mix and match depending on what is available and I have yet to run into problems with any of my systems :D!

Good luck Rgamboa

bulliver 05-16-2003 03:24 PM

I have to agree with MasterC,

rpm's are terrible. Along with MasterC's points, I have to add that rpm's install config files in seemingly arbitrary locations which are at the whim of the person who created the rpm. They allow no customization of the installed program, however the rpm wasw compiled -> that is the set of features you have to live with whether it is lacking something you need, or contains every feature making the app way larger than it needs to be.

Also, satisfying the sometimes endless list of dependancies can lead you so far away from what you were trying to install that after awhile you've forgotten :D

It is really not that hard to install from source, and it affords you the ability to install the files where you want them, include only the features you want, and optimize the software for your system (so it runs faster....)

In your specific case, it is not difficult to install apache and php together from source, and there are myriad tutorials and howto's out there that document this very task.

MasterC 05-16-2003 11:22 PM

Quote:

Originally posted by BigNate
WHAT !!!!!:)

I won't argue that RPM has it's share of issues but it is sub-optimal at best to try to install source on an rpm machine (absolutely possible, but difficult)...I spend a few hours every week talking a new user down after he tried to install a tar.gz pkg instead of a common rpm. rpm is *not* the be all end all, but if you couple it with apt4rpm you can accomplish a lot. I agree it will not solve all software issues, but for most desktop hobbists they may never need another tool. If you want to learn how linux ticks then yes at some point I suggest one should seek out raw code, compile/make it...but leave that until you know what a tarball is. :)

:)

Even with apt4rpm (which still is far from portage) the user has their share of problems. One major one being that it still uses RPM which breaks the system more often than it helps. Too many times you get corrupted rpm db's and "for the n00b" this usually means a new install. Not too efficient if you ask me ;)

Cool


All times are GMT -5. The time now is 05:11 PM.