diff mbox

guix: python-build-system: Honor configure-flags also when building

Message ID 20160929135710.6f3b7076@scratchpost.org
State New
Headers show

Commit Message

Danny Milosavljevic Sept. 29, 2016, 11:57 a.m. UTC
(Hmm, maybe this patch was not seen because it's so far down in the thread 
"Stuck on KiCad dependency wxPython". So I'm resending it to the top.)

While there was already a #:configure-flags for the "install" target,
it was not used when building. Use it.

* guix/build/python-build-system.scm (build): Modified.
---
 guix/build/python-build-system.scm | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Hartmut Goebel Sept. 30, 2016, 8:36 a.m. UTC | #1
Am 29.09.2016 um 13:57 schrieb Danny Milosavljevic:
> While there was already a #:configure-flags for the "install" target,
> it was not used when building. Use it.

First I thought, this is a good idea. But unfortunately this will not
work as expected. The setuptools's sub-commands "build" and "install" do
not accept the same options. So if one adds "build" options to
#:configure-flags, the install will fail and vice-a-versa.

Maybe we should change "#:configure-flags" into "#:install-flags" and
add "#:build-flags".
diff mbox

Patch

diff --git a/guix/build/python-build-system.scm b/guix/build/python-build-system.scm
index 9109fb4..65824a3 100644
--- a/guix/build/python-build-system.scm
+++ b/guix/build/python-build-system.scm
@@ -44,9 +44,9 @@ 
          (zero? (apply system* "python" "setup.py" command params)))
       (error "no setup.py found")))
 
-(define* (build #:rest empty)
+(define* (build #:key (configure-flags '()) #:allow-other-keys)
   "Build a given Python package."
-  (call-setuppy "build" '()))
+  (call-setuppy "build" configure-flags))
 
 (define* (check #:key tests? test-target #:allow-other-keys)
   "Run the test suite of a given Python package."