So the next module python-dateutil works. But again, python setup.py install complains that the path it wishes to install to, /nix/store/q637nhgrixha1f8cfl32l6gvviha737g-python2-dateutil-1.5/lib/python2.7/site-packages does not exist and is not in PYTHONPATH.
So I added the following: `(#:phases (alist-replace 'install (lambda* (#:key outputs #:allow-other-keys #:rest args) (let* ((install (assoc-ref %standard-phases 'install)) (out (assoc-ref outputs "out")) (python (assoc-ref %build-inputs "python")) (python-version (string-take (string-take-right python 5) 3)) (path (string-append out "/lib/python" python-version "/site-packages/"))) (mkdir-p path) (setenv "PYTHONPATH" (string-append (getenv "PYTHONPATH") ":" path)) (apply install args))) %standard-phases))) which is (a refined version of) the expression for python-setuptools. We need to factor this out. I suggest to do the following: In the install phase, before running setup.py, we create the directory and add it to the python path. But this would only be needed for programs creating modules, and I suppose not for programs that only create executables. I see two solutions: - We create the directory anyway, and try to remove it after installation with "rmdir -p". - Or more cleanly, we can add a variable #:module? (default: #f) and create the directory only if this variable is set to #t. What do you think? Andreas