Results 1 to 10 of 14
Hi,
I was trying to remove gcc-3.3 and then install gcc-3.4 compiler. However, when I remove gcc-3.3-base, I found a lot of packages have also been removed. The worst thing ...
- 12-21-2006 #1Just Joined!
- Join Date
- Dec 2006
- Posts
- 6
cannot find apt-get command
Hi,
I was trying to remove gcc-3.3 and then install gcc-3.4 compiler. However, when I remove gcc-3.3-base, I found a lot of packages have also been removed. The worst thing is that I cannot use apt-get to install anything.
When I use:
sudo apt-get install gcc-3.4
I got:
sudo: apt-get: command not found
I am so sad about it. Can anyone help me reinstall apt-get?
- 12-21-2006 #2Linux User
- Join Date
- Feb 2006
- Posts
- 484
hohoho dude you made a big mistake
try dpkg-reconfigure base-config
and wait for a debian guru like antidrugue or send him a pm
- 12-21-2006 #3Just Joined!
- Join Date
- Dec 2006
- Posts
- 6
No. It doesn't work. When I type:
sudo dpkg-reconfigure base-config
I got:
/usr/sbin/dpkg-reconfigure: base-config is broken or not fully installed.
This is too bad. I am going to
- 12-21-2006 #4Linux User
- Join Date
- Jun 2006
- Posts
- 311
Hi sillybird,
Download the source of apt from the Debian website and install it from source. First, open the following webpage in Debian site and checkout the required libraries and install them first, in case, they are missing in your system : -
http://packages.debian.org/stable/admin/apt
The following is the link for source of apt : -
http://ftp.debian.org/debian/pool/ma....5.28.6.tar.gz
With Regards,
Thinker
- 12-21-2006 #5Just Joined!
- Join Date
- Dec 2006
- Posts
- 3
While I do use apt-get and Kanotix scripts, if you're not used to the consequences of apt-get actions, I would use Adept for awhile. I find that people like to bad-mouth it BUT you can view all the consequences of your actions before you do it. It will show all the dependencies and what you are really doing. It's an eye-opener when you think you are getting rid of one file and most of KDE disappears!
- 12-21-2006 #6Just Joined!
- Join Date
- Dec 2006
- Posts
- 6
Thinker,
Yes. I installed apt and some other packages on my machine. Thank you so much!
I have one more question:
How can I set default gcc compiler to gcc-4.0 instead of gcc-3.4?
- 12-21-2006 #7Linux User
- Join Date
- Jun 2006
- Posts
- 311
Hi sillybird,
Can you give the output of the following command?
Or otherwise, do you know which are the executable files for gcc-4.0 and gcc-3.4? If you can find that, then you can create a backup of the existing /usr/bin/gcc file into a location with a special name so that you will remember it and after creating the backup, you can remove the current /usr/bin/gcc file and then create a symbolic link /usr/bin/gcc pointing to the exceutable file for gcc-4.0.]$ ls /usr/bin/gcc*
But, I just do not recommend doing the above method even if it is possible.
A better method than the above one would be create an alias for gcc pointing it to execute the gcc-4.0 compiler in your $HOME/.bashrc file. If you want to use the original gcc, run unalias -a. Also, to revert back in future simply comment or remove that line from $HOME/.bashrc.
This would be possible if you can find the separate executable for gcc-4.0.
With Regards,
Thinker
- 12-21-2006 #8Just Joined!
- Join Date
- Dec 2006
- Posts
- 6
The output for "ls /usr/bin/gcc*" is
/usr/bin/gcc /usr/bin/gcc-3.3 /usr/bin/gcc-3.4 /usr/bin/gccbug /usr/bin/gccbug-3.3 /usr/bin/gccbug-3.4
- 12-21-2006 #9Just Joined!
- Join Date
- Dec 2006
- Posts
- 6
I see what you mean. I will try the second method.
- 12-21-2006 #10Linux User
- Join Date
- Jun 2006
- Posts
- 311
Hi sillybird,
So where is the one for gcc-4.0? Have you installed it? Run the following command and post its output : -
]$ gcc --version
With Regards,
Thinker


Reply With Quote
