emerge -C python
by Dr D on Apr.13, 2008, under Computers, Funny
Okay, so I had a conflict with phyton and python-updater on my gentoo box the other day, and being tired and not thinking, i did a emerge -C pyton, which removes the program.
Shortly afterwards remembering the emerge program (gentoo’s portage application) is dependant on python. Doing a series of “whoops”, “oh shits”, and “damns”, I did a quick google, and found this link, and used it with updated versions/commands. http://forums.gentoo.org/viewtopic.php?t=5746
Basically what I did:
cd /tmp/
tar xjf /usr/portage/distfiles/Python-2.4.4.tar.bz2
cd Python-2.4.4/
./configure –with-fpectl –infodir=/usr/share/info/ –mandir=/usr/share/man
make
make install prefix=/usr
emerge python
cd ; rm -rf /tmp/Python-2.4.4
Which got me back up and operational. Kudos to the original poster to fix this!















July 29th, 2008 on 4:53 pm
Wow – thanks man. You saved me hours and lots of palpitations.
You titled your post exactly right for the search engine too.
Gentoo should just have a command:
emerge –fix-stupid-python-removal
May 1st, 2010 on 2:22 pm
I’ve just did the similar mistake (too fast ‘emerge –prune –nodep’), but thanks to you it wasn’t that hard to fix it. It should be somehow forbidden for emerge to remove python that easy…
January 22nd, 2011 on 7:10 am
You (the reader) whould consider that the temp directory could be be mounted as noexec or similar in fstab which means you won’t be able to run any executables (no matther how much you sudo and chmod).
So if you happen to encounter error messages about permission denied when trying to run configure, this most probably is the cause.