Can't install g++


 
Thread Tools Search this Thread
Operating Systems Linux Debian Can't install g++
# 1  
Old 01-25-2009
Can't install g++

Yo chaps.

So. While I was trying to compile lighttpd from source (first time I've ever been so brave) I ran across this error:
"C compiler cannot create executables"

I Googled around a bit and found someone suggesting that the error came from not having g++ installed. Which makes sense.

So I tried:
Code:
> apt-get install g++
...
The following packages have unmet dependencies.
  g++: Depends: g++-4.1 (>= 4.1.1-2) but it is not going to be installed

If I then tried to install g++-4.1 and got a similar error, and traced it right down to having the wrong version of libc6:

Code:
g++-4.1: Depends: libstdc++6-4.1-dev (= 4.1.1-21) but it is not going to be installed
....
libstdc++6-4.1-dev: Depends: libc6-dev (>= 2.3.6-7) but it is not going to be installed
...
libc6-dev: Depends: libc6 (= 2.3.6.ds1-13etch8) but 2.7-18 is to be installed

Now. If it was a less important package I'd just remove it and then re-install it. But to do that with libc6 I'd have to uninstall about 30 system packages including apt, which I'm not that inclined to do.

Does anyone know of a way around this?

Oh by the way, here's my apt sources list (might be relevant):

Code:
deb ftp://ftp.uk.debian.org/debian/ stable main contrib non-free
deb-src ftp://ftp.uk.debian.org/debian/ stable main

deb http://security.debian.org/ stable/updates main

Cheers,
Robin
# 2  
Old 01-27-2009
Yo, indeed, my good fellow.

You should be able to upgrade libc6 without uninstalling. Even on debian.
# 3  
Old 01-27-2009
This should do it:
Code:
aptitude update
aptitude upgrade
aptitude install g++

By the way, I suggest changing the 'stable' keyword in your sources.list to the release you use (woody/sarge/etch). It happened before that packages got broken because of this when a new release got out.
# 4  
Old 03-13-2009
Indeed, and it might be the case here, as well.
Lenny was recently released.

...You could also try:

Code:
apt-get update
apt-get upgrade
apt-get install build-essential

Instead of apt-get, you can use aptitude, if aptitude is the package manager that you prefer.

build-essential is a metapackage which includes several useful libraries.
Login or Register to Ask a Question

Previous Thread | Next Thread

8 More Discussions You Might Find Interesting

1. AIX

Install software in another directory with smitty install

Hello, I would like to ask if someone knows if is possible to install sofware via smitty or installp in another directorie , or we have to accept the default location? i would like to intall in /opt folder , but smitty installed it in /usr Thanks in advance (4 Replies)
Discussion started by: prpkrk
4 Replies

2. Fedora

Make check install and make all install

hi dear i want to know what is different between make check install and make all install? thanks in advane fereshte (3 Replies)
Discussion started by: komijani
3 Replies

3. Red Hat

Install Red Hat 4.2 (Not Enterprise) from install tree

Hi guys I would like to install Red Hat Linux 4.2 on my old box (pIII). However there is a problem: i can't find the .iso image anywhere in the Net, all the material that i've found is (i think) an install tree of the OS. It will be possible for me to install the OS from that install tree? ... (3 Replies)
Discussion started by: mk2soldier
3 Replies

4. Red Hat

CentOS 6.1 base install (like FreeBSD base install)?

Hello, What is the simplest way to install CentOS 6.1 with console base-system only using official LiveDVD image on VirtualBox machine? I'd like to get simplest console with network support like FreeBSD base installation. Then, install services which I need. The installer jest extracts the... (2 Replies)
Discussion started by: newbie_develope
2 Replies

5. Solaris

Solaris 10 install dvd drive boots, but not recoginized by install process

I am trying to build a Sun Ultra 10 with solaris 10. This computer is one of a collection that was donated to the non-profic company I work for. All media was wiped before I recieved them, so I am starting from stratch. I downloaded the Solaris 10 ISO and burned a DVD. The computer came with a... (4 Replies)
Discussion started by: gwillhight
4 Replies

6. Linux

install macbook pro fedora10 ???((<<if can install, how to install? >> ))

If may install can Tells everybody ??? (0 Replies)
Discussion started by: kzBSD
0 Replies

7. HP-UX

Oracle 9i install: Error in invoking target install of makefile

I receive an error while installing Oracle 9i: Error in invoking target install of makefile /opt/oracle/product/9.2.0/sqlplus/lib/ins_sqlplus.mk Furthermore: $ whoami oracle $ echo $ORACLE_HOME /opt/oracle/product/9.2.0 $ pwd /opt/oracle/product/9.2.0/sqlplus/lib $ ll total... (5 Replies)
Discussion started by: chris2005
5 Replies

8. HP-UX

Install HP UX

Hey whats up all of you pro's i have one question for you im not to familiar with HP UX 11i, but i would like to load it on my home machine. I am sure this is a dumb question but is there any special hardware requirements. I have reloaded the sysem at my work on a L class 9000 well not exactly by... (9 Replies)
Discussion started by: bbutler3295
9 Replies
Login or Register to Ask a Question