[gobolinux-users] Issues while building Mercurial

Daed Lee daed at thoughtsofcode.com
Fri Apr 3 13:43:49 NZDT 2009


2009/4/2 Michael Homer <michael at gobolinux.org>:
>> Fixed by editing StartRootless:
>>
>> export
>> PYTHONPATH="${goboPrefix}/System/Links/Libraries/python2.3/site-packages:${
>>goboPrefix}/System/Links/Libraries/python2.4/site-packages${PYTHONPATH:+:$PY
>>THONPATH}"
>>
>> changed to:
>>
>> export
>> PYTHONPATH="${goboPrefix}/System/Links/Libraries/python2.3/site-packages:${
>>goboPrefix}/System/Links/Libraries/python2.4/site-packages:${goboPrefix}/Sys
>>tem/Links/Libraries/python2.5/site-packages${PYTHONPATH:+:$PYTHONPATH}"
>>
>> Is this required every for every new version of Python?
> Probably, yes. It's a Rootless-specific problem (as is the one above, I think);
> if you use our Python, PYTHONPATH isn't used and /S/L/L/python2.{6,5,4,3} is
> inserted directly into sys.path. If you're using the system Python though that
> won't be there and you have to override it; in that case, yes, you'll have to
> update it each time (and you probably want to reverse the order).

How about using the following patch:

--- CreateRootlessEnvironment.original	2009-03-25 11:51:14.000000000 -0400
+++ CreateRootlessEnvironment.python	2009-04-02 20:32:57.000000000 -0400
@@ -158,7 +158,12 @@ then
    [ -e "${goboPrefix}/System/Settings/bashrc" ] && .
"${goboPrefix}/System/Settings/bashrc"
 fi

-export PYTHONPATH="${goboPrefix}/System/Links/Libraries/python2.3/site-packages:${goboPrefix}/System/Links/Libraries/python2.4/site-packages${PYTHONPATH:+:$PYTHONPATH}"
+for pythonDirectory in `find "${goboPrefix}/System/Links/Libraries"
-name "python*" | sort --reverse`
+do
+    PYTHONPATH="${PYTHONPATH:+$PYTHONPATH:}${pythonDirectory}/site-packages"
+done
+
+export PYTHONPATH

 export PKG_CONFIG_PATH="${goboPrefix}/System/Links/Libraries/pkgconfig${PKG_CONFIG_PATH:+:$PKG_CONFIG_PATH}:/usr/local/lib/pkgconfig:/usr/local/share/pkgconfig:/usr/lib/pkgconfig:/usr/share/pkgconfig"


> In fact, it looks like the latest version doesn't need that environmental
> override anyway, so I've taken it out too. You should just be able to Compile
> it without errors now.

Thanks, I'll give it a try.


More information about the gobolinux-users mailing list