[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: sys.path.insert
From: |
Marijn Schouten (hkBst) |
Subject: |
Re: sys.path.insert |
Date: |
Thu, 25 Jan 2007 14:53:23 +0100 |
User-agent: |
Thunderbird 1.5.0.9 (X11/20061225) |
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Han-Wen Nienhuys wrote:
> Marijn Schouten (hkBst) escreveu:
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA1
>>
>> Han-Wen Nienhuys wrote:
>>> Marijn Schouten (hkBst) escreveu:
>>>> -----BEGIN PGP SIGNED MESSAGE-----
>>>> Hash: SHA1
>>>>
>>>> Marijn Schouten wrote:
>>>>> Hi list,
>>>>>
>>>>> this is a little snippet from the gentoo build script for lilypond
>>>>>
>>>>> # lilypond python scripts *prepend* /usr/share/lilypond/${PV}/python to
>>>>> # sys.path, causing python to attempt to rebuild the pyc, which
>>>>> generates
>>>>> # sandbox errors (and is wrong anyway). Change this policy to use
>>>>> # sys.path.append so that PYTHONPATH, set by the Makefiles, takes
>>>>> # precendence.
>>>>> grep -rlZ sys.path.insert --include \*.py ${S} | xargs -0r sed -i
>>>>> 's/sys.path.insert \?(0, /sys.path.append (/'
>>>>>
>>>>> any thoughts?
>>> who is setting PYTHONPATH, and for what reason?
>> on my box it is set to /usr/lib/portage/pym
>> The Gentoo package manager portage is written in python.
>
> ok, and which pyc are rebuilt ?
>
> We prepend to be sure that the .pys that we load are the ones from the
> current source package, and not from older versions that linger
> around on the build system.
The ones from an already installed version of lilypond, ironically.
Marijn
PS Here's what the sandbox says
- --------------------------- ACCESS VIOLATION SUMMARY
---------------------------
LOG FILE = "/var/log/sandbox/sandbox-media-sound_-_lilypond-2.10.13-13299.log"
unlink: /usr/share/lilypond/2.10.13/python/lilylib.pyc
open_wr: /usr/share/lilypond/2.10.13/python/lilylib.pyc
unlink: /usr/share/lilypond/2.10.13/python/lilylib.pyc
open_wr: /usr/share/lilypond/2.10.13/python/lilylib.pyc
unlink: /usr/share/lilypond/2.10.13/python/lilylib.pyc
open_wr: /usr/share/lilypond/2.10.13/python/lilylib.pyc
unlink: /usr/share/lilypond/2.10.13/python/fontextract.pyc
open_wr: /usr/share/lilypond/2.10.13/python/fontextract.pyc
unlink: /usr/share/lilypond/2.10.13/python/convertrules.pyc
open_wr: /usr/share/lilypond/2.10.13/python/convertrules.pyc
unlink: /usr/share/lilypond/2.10.13/python/lilylib.pyc
open_wr: /usr/share/lilypond/2.10.13/python/lilylib.pyc
unlink: /usr/share/lilypond/2.10.13/python/lilylib.pyc
open_wr: /usr/share/lilypond/2.10.13/python/lilylib.pyc
unlink: /usr/share/lilypond/2.10.13/python/lilylib.pyc
open_wr: /usr/share/lilypond/2.10.13/python/lilylib.pyc
unlink: /usr/share/lilypond/2.10.13/python/convertrules.pyc
open_wr: /usr/share/lilypond/2.10.13/python/convertrules.pyc
unlink: /usr/share/lilypond/2.10.13/python/fontextract.pyc
open_wr: /usr/share/lilypond/2.10.13/python/fontextract.pyc
unlink: /usr/share/lilypond/2.10.13/python/lilylib.pyc
open_wr: /usr/share/lilypond/2.10.13/python/lilylib.pyc
unlink: /usr/share/lilypond/2.10.13/python/lilylib.pyc
open_wr: /usr/share/lilypond/2.10.13/python/lilylib.pyc
unlink: /usr/share/lilypond/2.10.13/python/lilylib.pyc
open_wr: /usr/share/lilypond/2.10.13/python/lilylib.pyc
unlink: /usr/share/lilypond/2.10.13/python/musicxml.pyc
open_wr: /usr/share/lilypond/2.10.13/python/musicxml.pyc
unlink: /usr/share/lilypond/2.10.13/python/rational.pyc
open_wr: /usr/share/lilypond/2.10.13/python/rational.pyc
unlink: /usr/share/lilypond/2.10.13/python/lilylib.pyc
open_wr: /usr/share/lilypond/2.10.13/python/lilylib.pyc
unlink: /usr/share/lilypond/2.10.13/python/musicexp.pyc
open_wr: /usr/share/lilypond/2.10.13/python/musicexp.pyc
unlink: /usr/share/lilypond/2.10.13/python/lilylib.pyc
open_wr: /usr/share/lilypond/2.10.13/python/lilylib.pyc
unlink: /usr/share/lilypond/2.10.13/python/lilylib.pyc
open_wr: /usr/share/lilypond/2.10.13/python/lilylib.pyc
unlink: /usr/share/lilypond/2.10.13/python/musicxml.pyc
open_wr: /usr/share/lilypond/2.10.13/python/musicxml.pyc
unlink: /usr/share/lilypond/2.10.13/python/rational.pyc
open_wr: /usr/share/lilypond/2.10.13/python/rational.pyc
unlink: /usr/share/lilypond/2.10.13/python/musicexp.pyc
open_wr: /usr/share/lilypond/2.10.13/python/musicexp.pyc
unlink: /usr/share/lilypond/2.10.13/python/fontextract.pyc
open_wr: /usr/share/lilypond/2.10.13/python/fontextract.pyc
unlink: /usr/share/lilypond/2.10.13/python/fontextract.pyc
open_wr: /usr/share/lilypond/2.10.13/python/fontextract.pyc
-
--------------------------------------------------------------------------------
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.1 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFFuLZTp/VmCx0OL2wRAnSMAJ4n8KHKumfjeCkyy5qJXKSKJ6e1iACffoN0
+UGdp+AaRo2GqSgcB3wE28w=
=v+v1
-----END PGP SIGNATURE-----