The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.
|
 |
|
Dev Shed Forums
> Operating Systems
> Linux Help
|
Lost C compiler - Help!
Discuss Lost C compiler - Help! in the Linux Help forum on Dev Shed. Lost C compiler - Help! Linux Help forum discussing topics including usage, troubleshooting, modules, and distributions. Linux is an open source OS, based on UNIX.
|
|
 |
|
|
|
|

Dev Shed Forums Sponsor:
|
|
|

November 23rd, 2001, 05:57 PM
|
 |
Ole` Timer
|
|
Join Date: Dec 2000
Location: N.W. Iowa
Posts: 472

Time spent in forums: 5 h 29 m 6 sec
Reputation Power: 13
|
|
Lost C compiler - Help!
I sure hope someone can help out here! I upgraded our gcc from 2.91 to 2.95, using the rpm file. I thought it upgraded properly, but know for some reason, I no longer have a C compiler! I was going to install a module, and I get the error: Can not compile C compiler no working.
This is on a RH/Linux 6.2. Everything was working fine till I upgraded the gcc... which was probably a mistake!
I was hoping someone may guide in the right direction as how to get our C compiler back or what I need to do to re-install it.
TIA,
Mickalo
|

November 23rd, 2001, 06:18 PM
|
|
Contributing User
|
|
Join Date: Jan 2001
Posts: 5
Time spent in forums: < 1 sec
Reputation Power: 0
|
|
|
>> Everything was working fine till I upgraded the gcc... which was probably a mistake!
Biggest mistake. Just so you know, gcc, being the most critical utility in *NIX, should be upgraded only if you have a valid reason and know what you're doing.
>> what I need to do to re-install it
Backup your stuff and redo a fresh install. Ditch Redhat and go for FreeBSD if at all possible. Or simply reinstall with the latest version - 7.2.
|

November 23rd, 2001, 07:29 PM
|
 |
11
|
|
Join Date: Jul 2001
Location: Lynn, MA
|
|
You might try removing whatever RPMs you installed and installing/compiling gcc from the source, at
http://gcc.gnu.org
I think we all learn the "only upgrade if you have a really good reason" lesson a few times in the past. . .
I use RH 7.2 on a few different boxes now, and I have to admit that it's really tight. Hopefully you have separate /home, /usr, /tmp, and root partitions, this makes reinstalls much, much easier. . .
|

November 23rd, 2001, 08:17 PM
|
 |
Ole` Timer
|
|
Join Date: Dec 2000
Location: N.W. Iowa
Posts: 472

Time spent in forums: 5 h 29 m 6 sec
Reputation Power: 13
|
|
Quote: Originally posted by Hero Zzyzzx
You might try removing whatever RPMs you installed and installing/compiling gcc from the source, at
http://gcc.gnu.org
I think we all learn the "only upgrade if you have a really good reason" lesson a few times in the past. . .
I use RH 7.2 on a few different boxes now, and I have to admit that it's really tight. Hopefully you have separate /home, /usr, /tmp, and root partitions, this makes reinstalls much, much easier. . . |
Thanks. this is what I was thinking of doing, installing from source. But if I don't have a C compiler, I can't install anything from source! that's how I found out in the first place, when installing MySQL 3.23.45 from source!
I would attempt to upgrade from our current 6.2 to 7.2,.. but I don't feel real sure about that. The dedicated server we're on has about 40 clients hosted on it, and I don't want to screw it up.
I'll contact our support to see if they can help me out.
YES!! I am learning the "IN's and OUT's" of a system admin,... THE HARD WAY!! 
|

November 24th, 2001, 05:56 AM
|
|
Not there when you need me
|
|
Join Date: Oct 2001
Location: Berlin, Germany
Posts: 1,430
Time spent in forums: 17 m 46 sec
Reputation Power: 13
|
|
|
Sorry it didn't work, mickalo.
Have you tried just typing gcc -v ? To see if it's there at all?
|

November 24th, 2001, 08:44 AM
|
 |
Ole` Timer
|
|
Join Date: Dec 2000
Location: N.W. Iowa
Posts: 472

Time spent in forums: 5 h 29 m 6 sec
Reputation Power: 13
|
|
Quote: Originally posted by realnowhereman
Sorry it didn't work, mickalo.
Have you tried just typing gcc -v ? To see if it's there at all? |
Well after burning the midnite oil last nite. I was able to get it back,..I think!
I found the problem when attempting to install MySQL from source, and it wouldn't compile. If I now run this configuration:
Code:
CCFLAGS="-O3" CXX=gcc CXXFLAGS="-O3 -felide-constructors -fno-exceptions -fno-rtti" \
./configure --prefix=/usr/local/mysql --with-berkeley-db --without-docs --without-bench \
--without-readline --enable-assembler --with-mysqld-ldflags=-all-static \
--with-mysqld-user=mysql2 --with-low-memory --with-tcp-port=3307 \
--with-unix-socket=/tmp/mysql2.sock --localstatedir=/usr/local/mysql/var
I get the error message: CCFLAGS command not found
but if I remove this:
Code:
CCFLAGS="-O3" CXX=gcc CXXFLAGS="-O3 -felide-constructors -fno-exceptions -fno-rtti" \
and run it like this:
Code:
./configure --prefix=/usr/local/mysql --with-berkeley-db --without-docs --without-bench \
--without-readline --enable-assembler --with-mysqld-ldflags=-all-static \
--with-mysqld-user=mysql2 --with-low-memory --with-tcp-port=3307 \
--with-unix-socket=/tmp/mysql2.sock --localstatedir=/usr/local/mysql/var
it seems to compile without any errors. I didn't run the make or make install, I just wanted to see if it would get past the configuration, which it didn't yesterday, it does today.
If I enter: gcc -v it display the correct information now, as it did before I attempted to upgrade the gcc. I think I removed everything I tried to install. So I believe it's back to it's orginal state! I think.
If I attempt to use "export" at the command line, I get the error, "command not found.." not sure if this part of the problem or not. So right now I can't use the CCFLAGS= or CXX= enviromental variables.
Mickalo
|

November 24th, 2001, 08:49 AM
|
|
Not there when you need me
|
|
Join Date: Oct 2001
Location: Berlin, Germany
Posts: 1,430
Time spent in forums: 17 m 46 sec
Reputation Power: 13
|
|
Quote:
If I attempt to use "export" at the command line, I get the error, "command not found.." |
What shell are you using?
|

November 24th, 2001, 08:53 AM
|
 |
Ole` Timer
|
|
Join Date: Dec 2000
Location: N.W. Iowa
Posts: 472

Time spent in forums: 5 h 29 m 6 sec
Reputation Power: 13
|
|
Quote: Originally posted by realnowhereman
What shell are you using? |
/bin/bash as root
Is that incorrect?
|

November 24th, 2001, 09:01 AM
|
|
Not there when you need me
|
|
Join Date: Oct 2001
Location: Berlin, Germany
Posts: 1,430
Time spent in forums: 17 m 46 sec
Reputation Power: 13
|
|
Quote:
/bin/bash as root
Is that incorrect? |
It's all right. Just checking. Dunno why it doesn't like export ...
|

November 24th, 2001, 09:10 AM
|
 |
Ole` Timer
|
|
Join Date: Dec 2000
Location: N.W. Iowa
Posts: 472

Time spent in forums: 5 h 29 m 6 sec
Reputation Power: 13
|
|
Quote: Originally posted by realnowhereman
It's all right. Just checking. Dunno why it doesn't like export ... |
I tried it again, changed the shell in the /etc/passwd for root to /bin/bash, logged in,.. and bingo! I can export now.
Go figure!
I think I've got the problem resolved now...
I really appreciate all the help!
Mickalo
|
Developer Shed Advertisers and Affiliates
| Thread Tools |
Search this Thread |
|
|
|
| Display Modes |
Rate This Thread |
Linear Mode
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
|
|