diff mbox series

[bug#39451] gnu: subversion: Support running the tests in parallel.

Message ID 20200206084207.15195-1-mail@cbaines.net
State Accepted
Headers show
Series [bug#39451] gnu: subversion: Support running the tests in parallel. | expand

Checks

Context Check Description
cbaines/comparison success View comparision
cbaines/git branch success View Git branch
cbaines/applying patch success View Laminar job

Commit Message

Christopher Baines Feb. 6, 2020, 8:42 a.m. UTC
This drops the time to build the package on my machine from ~14 minutes to ~5
minutes.

* gnu/packages/version-control.scm (subversion)[arguments]: Add set-PARALLEL
phase to set the PARALLEL environment variable.
---
 gnu/packages/version-control.scm | 4 ++++
 1 file changed, 4 insertions(+)

Comments

Leo Famulari Feb. 7, 2020, 10:57 p.m. UTC | #1
On Thu, Feb 06, 2020 at 08:42:07AM +0000, Christopher Baines wrote:
> This drops the time to build the package on my machine from ~14 minutes to ~5
> minutes.

Awesome. If it seems reliable for you (doesn't crash due to race
conditions) then please push.
diff mbox series

Patch

diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm
index 20db6b4b08..140eccb7ec 100644
--- a/gnu/packages/version-control.scm
+++ b/gnu/packages/version-control.scm
@@ -1434,6 +1434,10 @@  following features:
              (substitute* "subversion/tests/libsvn_repos/repos-test.c"
                (("#!/bin/sh") (string-append "#!" (which "sh"))))
              #t))
+         (add-before 'check 'set-PARALLEL
+           (lambda _
+             (setenv "PARALLEL" (number->string (parallel-job-count)))
+             #t))
          (add-after 'install 'install-perl-bindings
            (lambda* (#:key outputs #:allow-other-keys)
              ;; Follow the instructions from 'subversion/bindings/swig/INSTALL'.