Hello, and thanks for your comments! I am attaching a new patch. On Sat, Sep 07, 2013 at 02:49:07PM +0200, Ludovic Courtès wrote: > Still it’s better to keep it, as a generic version. Then, we can have: > (define package-with-python-2 > (cut package-with-explicit-python <> python-2)) > and then use that as needed. I modified with two additional parameters, OLD-PREFIX and NEW-PREFIX: When going to python-2, one rewrites the prefix "python-" to "python2-". The current patch would allow to go back to Python 3 by calling (package-with-explicit-python p python "python2-" "python-"). > Sylistic note: never use ‘car’, ‘cdr’, and co; use ‘match’ instead: it > leads to code that is both more readable and more robust (info "(guile) > Pattern Matching"). In that case, you can even use ‘match-lambda’, > which is equivalent to: > (lambda (x) > (match x > ...)) This is rather surprising for a language based on lists... But admittedly, the code becomes more readable. > Second remark: inputs are actually tuples of one of two forms: > (name package) > (name package output) Or a third one, (name-of-patch store-path-of-patch), which was already handled. The current patch should handle all cases. > (map rewrite (package-inputs p)) is enough; if (package-inputs p) is > null?, then that’ll return the empty list too. This is something that I had tested, and strangely, it did not work at the time I made the test. But the error must have lain somewhere else then. Andreas