Using CentOS 5.3(which only has python 2.4) I get this: Traceback (most recent call last): File "/home/hechee/gentoo/usr/bin/emerge", line 37, in ? from _emerge.main import emerge_main File "/home/hechee/gentoo/usr/lib/portage/pym/_emerge/main.py", line 51, in ? from _emerge.actions import action_config, action_sync, action_metadata, \ File "/home/hechee/gentoo/usr/lib/portage/pym/_emerge/actions.py", line 45, in ? from _emerge.depgraph import backtrack_depgraph, depgraph, resume_depgraph File "/home/hechee/gentoo/usr/lib/portage/pym/_emerge/depgraph.py", line 1102 finally: ^ SyntaxError: invalid syntax Apparently, although the configure script of portage 2.2.00.13878 checks for python >= 2.4, it needs 2.5 so this wasn't caught during configuration
Created attachment 202201 [details, diff] Use bootstrap python for portage
The bootstrap python should pick up whatever python is in your PATH first. Are you sure that prefix'd python is first?
(In reply to comment #2) > The bootstrap python should pick up whatever python is in your PATH first. Are > you sure that prefix'd python is first? > The bootstrap portage*
Yes, the bootstrap python is first, but emerge uses the system python because the magic first line is «#!/usr/bin/python» which should be instead «#!/usr/bin/env python»
Created attachment 202206 [details, diff] Use python from environment
(In reply to comment #4) > Yes, the bootstrap python is first, but emerge uses the system python because > the magic first line is «#!/usr/bin/python» which should be instead > «#!/usr/bin/env python» > That is my point. It feels like a regression to me, because it use to grab the python in $EPREFIX/tmp/...
Ok, two things. 1) portage trunk now requires 2.5. Since the prefix branch has a different build system, it went unknown until someone with only 2.4 tried to use it. That was you, sorry... This might work?!? %% svn di Index: configure.in =================================================================== --- configure.in (revision 14154) +++ configure.in (working copy) @@ -31,7 +31,7 @@ AC_PROG_EGREP GENTOO_PATH_XCU_ID() -GENTOO_PATH_PYTHON([2.4]) +GENTOO_PATH_PYTHON([2.5]) AC_PATH_PROG(PORTAGE_RM, [rm], no) AC_PATH_PROG(PORTAGE_MV, [mv], no) 2) There is a problem with the shebang line of emerge. It should, under no circumstance, be /usr/bin/python. Either the abs path (preferred), or /usr/bin/env. Since the first line of the *source* is: #!@PORTAGE_PYTHON@ - You would think that this is plugged in from configure. Which leads me to two conclusions, a) regression *somehow*, or b) the user's path was incorrect (but Stelian says that it is correct and you can only trust what the bug reporter says otherwise you are doomed) I hope this analysis helps grobian triage the issue. =)
I tried bootstrapping again and I can't reproduce it any more, so probably my $PATH was wrong
your path was wrong, or you continued with the broken symlink you has, as reported yesterday
Jeremy's patch should be applied to the prefix branch of portage, including an ebuild update for the same dependency
fixed in 2.2.00.14159, thanks all