lilypond-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Distributions upgrading to Python 3


From: Graham Percival
Subject: Re: Distributions upgrading to Python 3
Date: Sun, 24 Oct 2010 04:06:03 +0100
User-agent: Mutt/1.5.20 (2009-06-14)

On Fri, Oct 22, 2010 at 10:21:58PM +0200, Matthias Kilian wrote:
> On Tue, Oct 19, 2010 at 12:07:29AM +0100, Graham Percival wrote:
> > Anything that's used to build the website (as opposed to the html
> > version of the docs) cannot rely on configure.  This affects
> > scripts/build/ create-*.py website_post.py bib2texi.py
> > 
> > ... admittedly, those are getting called with
> >     python scripts/build/foo.py
> > , probably precisely to avoid this problem.  So I guess that's not a 
> > concern.
> 
> Oh, it would still be better to use something like
> 
> PYTHON?=python
> ...
> WEB_POST=${PYTHON} $(script-dir)/website_post.py
> 
> in files like make/website.make (but probably only of people using
> this part start to complain about annoyances).

I don't completely follow... but AFAIK, I'm the only person to run
"make website" (both on my local machine for testing, and in a
cronjob on lilypond.org).  It works fine for me, so I'd rather not
change anything.

> > > #!/usr/bin/env YOUR_FAVORITE_INTERPRETER
> > 
> > Why not?  IIRC, we had to add this to work around some problem in OSX.
> >  The discussion is in the email archives... hopefully somebody can dig
> > it out for us.
> 
> I didn't dig it yet,

I think that would be a good idea -- I'm now starting to doubt
whether it was OSX and instead it was something to do with ubuntu
or arch linux or something like that.

> but for OSX (and every system where people
> have to rely on binary installers provided by lilypond.org) it may
> be that different OSX versions have python installed in different
> locations. If my guess is correct, it would be nice if someone could
> hack on the OSX binary to do some post-install patching on the
> installed python scripts.

Changing the OSX binary is harder than it sounds; if this change
is to lilypad, then you need to find the tarball (it's not in any
kind of source repository!) and change it there.  If this is
something that can be done in the build phase, then it "only"
requires a change to GUB.

Hmm... now I'm wondering if this was a hack for osx 10.4, which
shipped python 2.3.5 instead of 2.4 (which we required), and we
wanted to make it stop calling /usr/bin/python and use our bundled
python instead.
That said, this workaround may have been rendered useless by later
changes to our osx build stuff.

> > If there's a good reason not to do this, and a better way of solving
> > whatever problem we solved with /usr/bin/env python, I welcome a
> > change.
> 
> The good reason is: whatever you install system-wide with a
> #!/usr/bin/env line is out of your control. It immediately depends
> on the users PATH. Ignoring security issues for now,

Hmm, yes, that could be serious.  Fortunately, on linux I don't
see any "env python" lines in lilypond's installed files.  I can't
check the other OSes, though.

Cheers,
- Graham



reply via email to

[Prev in Thread] Current Thread [Next in Thread]