unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: ludo@gnu.org (Ludovic Courtès)
To: Andreas Enge <andreas@enge.fr>
Cc: guix-devel@gnu.org
Subject: Re: Improving the Python build system.
Date: Mon, 02 Sep 2013 21:46:29 +0200	[thread overview]
Message-ID: <87mwnv57my.fsf@gnu.org> (raw)
In-Reply-To: <20130901132726.GB1699@debian> (Andreas Enge's message of "Sun, 1 Sep 2013 15:27:26 +0200")

(Somehow this one had remained unanswered.)

Andreas Enge <andreas@enge.fr> skribis:

> Probably (once the python changes dust settles), it will be enough to simply
> add setuptools as an input to the packages.
>
> I would like to suggest a few modifications to the python build system
> resulting from discussions with Brandon Invergo at the GHM. If I understood
> correctly, then "setup.py check" only makes some basic checks on the package
> and can be safely dropped. This is corroborated by
>    python setup.py --help-commands | grep check
> on pytz, for instance, which displays
>    check             perform some checks on the package
>
> However, "python setup.py --help-commands | grep test":
>    test              run unit tests after in-place build
> I think this it what we would like to do in the check phase.
>
> Then it is possible to also separate the build and install phases:
>    build             build everything needed to install
>
> I think we would like to add such a phase.

You mean a ‘build’ phase, right?  And also change the ‘check’ phase to
run ‘python setup.py test’ (what does ‘python setup.py check’ do
concretely?)

Sounds like both are good ideas.

> Stylistically, they should probably be obtained by a call to one function
> returning a procedure calling setup.py with "build", "test" and "install",
> respectively, instead of copy-pasting three times the same code.

Agreed.

For reference, here’s Nixpkgs’ Python builder, which I had originally
contributed (as crazy as it may seem):

  https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/python-modules/generic/default.nix

It actually uses ‘easy_install’, which appears to be, well, easy.  And
presumably it does more things (like building a zipped .egg file).
Perhaps it’d be even better?

What do the pythoneers think?

Ludo’.

  reply	other threads:[~2013-09-02 19:51 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-25 23:29 Improving the Python build system Cyril Roelandt
2013-09-01 13:27 ` Andreas Enge
2013-09-02 19:46   ` Ludovic Courtès [this message]
2013-09-02 20:51     ` Andreas Enge

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87mwnv57my.fsf@gnu.org \
    --to=ludo@gnu.org \
    --cc=andreas@enge.fr \
    --cc=guix-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).