Lilypond and default python

Ryan Schmidt ryandesign at macports.org
Fri Mar 1 20:30:57 PST 2013


On Feb 28, 2013, at 11:24, Jeremy Lavergne wrote:

> What would be the best way to set configure.{env,python} to any python2.7 rather than just MacPorts'?
> 
> Aljaž (g5pw) was kind enough to send me a patch to set lilypond's configure.env and configure.python to MacPorts' python2.7. Since lilypond only needs an operable python2.7 which ships with most OS X, I've been using a depends_run-append  bin:python2.7:python27.

I guess it depends on the port, and what gymnastics it requires you to perform to tell it what python you'd like it to use.

For glib2, which requires python 2.5 or later, I found that only Tiger's python is too old, so I just added the python27 dependency (and changed configure.python) in a platform darwin 8 block. I did once get a bug report from a user on newer OS X who had somehow replaced his Apple python with an older version, but I'm not going to change the port to accommodate such user errors.

For graphite2, whose test phase runs "python" and needs python 2.6 or later, I used a pre-test block to test the actual version of python installed, and let the user deal with it if it's too old (i.e. a user on Leopard would need to run "sudo port select python python27" (or "...python26") to run the graphite2 tests. I felt that requiring manual intervention here was not awful, because it only applies to the minority of OS X users on old versions of OS X, and only applies when users deliberately run the tests. I'll revisit this once we have a "depends_test" option (#38208).



More information about the macports-dev mailing list