GNU bug report logs - #70031
[core-updates PATCH 00/19] Use CMake in build-system/cmake.

Previous Next

Package: guix-patches;

Reported by: Greg Hogan <code <at> greghogan.com>

Date: Wed, 27 Mar 2024 14:50:01 UTC

Severity: normal

Tags: patch

To reply to this bug, email your comments to 70031 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:50:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Greg Hogan <code <at> greghogan.com>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Wed, 27 Mar 2024 14:50:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: guix-patches <at> gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 00/19] Use CMake in build-system/cmake.
Date: Wed, 27 Mar 2024 14:49:03 +0000
Following up on this discussion from 2+ years ago:
  https://lists.gnu.org/archive/html/guix-devel/2021-10/msg00055.html

The current cmake-build-system defers to gnu-build-system to build and
check packages. This patch adapts the cmake-build-system to use CMake
commands. The benefits include:

1) Tests can run in parallel. Make (from the gnu-build-system) treats
ctest as a single target so cannot parallelize tests. By directly
running ctest the tests are run with optional parallelism.

2) Alternative generators, namely Ninja. When configured with an
alternative generator the CMake build, check, and install commands will
use that generator and the package need not replace each phase.

The simplification can be seen in the included patch for astroid. Ninja
must still be included (both the module and native input) and the
generator specified:

  (use-modules
   (gnu packages ninja))

  (arguments
   (list #:generator "Ninja"))

  (native-inputs (list ninja))

This compares with the current requirement to override flags and phases:

  (arguments
   (list
    #:configure-flags #~(list "-GNinja")
    #:phases
    #~(modify-phases %standard-phases
        (replace 'build
          (lambda _
            (invoke "ninja" "-j" (number->string (parallel-job-count)))))
        (replace 'check
          (lambda* (#:key tests? #:allow-other-keys)
            (when tests?
              (setenv "CTEST_OUTPUT_ON_FAILURE" "1")
              (invoke "ctest" "."))))
        (replace 'install
          (lambda _
            (invoke "ninja" "install"))))))

It would be nice to include the ninja module and ninja as a native input
by default when using the cmake-build-system, but I do not think this is
possible due to circular dependencies with Python and CMake, the two
supported build methods for Ninja.

Greg Hogan (19):
  build-system/cmake: Parallelize tests using ctest.
  build-system/cmake: Parameterize build system generator.
  build-system/cmake: Add build.
  build-system/cmake: Add install.
  gnu: libmedfile: Disable parallel tests.
  gnu: srt: Disable parallel tests.
  gnu: fish: Fix tests.
  gnu: vulkan-loader: Disable parallel tests.
  gnu: igraph: Move test target to check phase.
  gnu: inkscape: Move test target to check phase.
  gnu: vigra: Move test target to check phase.
  gnu: cpp-httplib: Disable parallel tests.
  gnu: libical: Disable parallel tests.
  gnu: astroid: Remove custom phases.
  gnu: websocketpp: Disable parallel tests.
  gnu: mbedtls-lts: Disable parallel tests.
  gnu: scotch: Disable parallel tests.
  gnu: evolution-data-server: Disable parallel tests.
  gnu: aws-c-common: Disable parallel tests.

 doc/guix.texi                     |  4 +++
 gnu/packages/c.scm                |  3 +-
 gnu/packages/calendar.scm         |  1 +
 gnu/packages/cpp.scm              |  3 +-
 gnu/packages/engineering.scm      |  3 +-
 gnu/packages/gnome.scm            |  1 +
 gnu/packages/graph.scm            |  5 +++-
 gnu/packages/image.scm            |  9 ++++--
 gnu/packages/inkscape.scm         |  8 ++++--
 gnu/packages/mail.scm             | 16 ++---------
 gnu/packages/maths.scm            |  3 +-
 gnu/packages/networking.scm       |  3 +-
 gnu/packages/shells.scm           |  5 ++++
 gnu/packages/tls.scm              |  3 +-
 gnu/packages/vulkan.scm           |  1 +
 gnu/packages/web.scm              |  3 +-
 guix/build-system/cmake.scm       |  4 +++
 guix/build/cmake-build-system.scm | 46 +++++++++++++++++++++++++------
 18 files changed, 85 insertions(+), 36 deletions(-)


base-commit: 656baadf83f2812c0ff79f4f2f0b5f1e927ed8a5
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:02 GMT) Full text and rfc822 format available.

Message #8 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 01/19] build-system/cmake: Parallelize tests
 using ctest.
Date: Wed, 27 Mar 2024 14:52:26 +0000
* guix/build/cmake-build-system.scm (check): Replace call to gnu-build's
non-parallelizable check with an implementation using cmake's ctest.
---
 guix/build/cmake-build-system.scm | 24 +++++++++++++++++++-----
 1 file changed, 19 insertions(+), 5 deletions(-)

diff --git a/guix/build/cmake-build-system.scm b/guix/build/cmake-build-system.scm
index d1ff5071be5..ea342ff2ac9 100644
--- a/guix/build/cmake-build-system.scm
+++ b/guix/build/cmake-build-system.scm
@@ -23,6 +23,7 @@ (define-module (guix build cmake-build-system)
   #:use-module ((guix build gnu-build-system) #:prefix gnu:)
   #:use-module (guix build utils)
   #:use-module (ice-9 match)
+  #:use-module (srfi srfi-34)
   #:export (%standard-phases
             cmake-build))
 
@@ -77,12 +78,25 @@ (define* (configure #:key outputs (configure-flags '()) (out-of-source? #t)
       (format #t "running 'cmake' with arguments ~s~%" args)
       (apply invoke "cmake" args))))
 
-(define* (check #:key (tests? #t) (parallel-tests? #t) (test-target "test")
+(define %test-suite-log-regexp
+  ;; Name of test suite log files as commonly found in CMake.
+  "^LastTestFailed\\.log$")
+
+(define* (check #:key (tests? #t) (parallel-tests? #t)
+                (test-suite-log-regexp %test-suite-log-regexp)
                 #:allow-other-keys)
-  (let ((gnu-check (assoc-ref gnu:%standard-phases 'check)))
-    (setenv "CTEST_OUTPUT_ON_FAILURE" "1")
-    (gnu-check #:tests? tests? #:test-target test-target
-              #:parallel-tests? parallel-tests?)))
+  (if tests?
+      (guard (c ((invoke-error? c)
+                 ;; Dump the test suite log to facilitate debugging.
+                 (display "\nTest suite failed, dumping logs.\n"
+                          (current-error-port))
+                 (gnu:dump-file-contents "." test-suite-log-regexp)
+                 (raise c)))
+        (apply invoke "ctest" "--output-on-failure"
+               `(,@(if parallel-tests?
+                       `("-j" ,(number->string (parallel-job-count)))
+                       '()))))
+      (format #t "test suite not run~%")))
 
 (define %standard-phases
   ;; Everything is as with the GNU Build System except for the `configure'
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:02 GMT) Full text and rfc822 format available.

Message #11 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 03/19] build-system/cmake: Add build.
Date: Wed, 27 Mar 2024 14:52:28 +0000
* guix/build/cmake-build-system.scm (build): New function to replace
the make build with the cmake build command.
---
 guix/build/cmake-build-system.scm | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/guix/build/cmake-build-system.scm b/guix/build/cmake-build-system.scm
index 1775f7a7509..8f1c80aeb64 100644
--- a/guix/build/cmake-build-system.scm
+++ b/guix/build/cmake-build-system.scm
@@ -81,6 +81,14 @@ (define* (configure #:key outputs (configure-flags '()) (out-of-source? #t)
       (format #t "running 'cmake' with arguments ~s~%" args)
       (apply invoke "cmake" args))))
 
+(define* (build #:key (parallel-build? #t) #:allow-other-keys)
+  (apply invoke "cmake"
+         `("--build"
+           "."
+           ,@(if parallel-build?
+                 `("-j" ,(number->string (parallel-job-count)))
+                 '()))))
+
 (define %test-suite-log-regexp
   ;; Name of test suite log files as commonly found in CMake.
   "^LastTestFailed\\.log$")
@@ -102,10 +110,9 @@ (define* (check #:key (tests? #t) (parallel-tests? #t)
       (format #t "test suite not run~%")))
 
 (define %standard-phases
-  ;; Everything is as with the GNU Build System except for the `configure'
-  ;; and 'check' phases.
   (modify-phases gnu:%standard-phases
     (delete 'bootstrap)
+    (replace 'build build)
     (replace 'check check)
     (replace 'configure configure)))
 
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:03 GMT) Full text and rfc822 format available.

Message #14 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 02/19] build-system/cmake: Parameterize build
 system generator.
Date: Wed, 27 Mar 2024 14:52:27 +0000
* guix/build-system/cmake.scm (cmake-build): Add generator parameter
defaulted to the default CMake build system generator.
* guix/build/cmake-build-system.scm (configure): Add and use generator
parameter to configure the build system.
* doc/guix.texi (Build Systems): Document #:generator for
cmake-build-system.
---
 doc/guix.texi                     | 4 ++++
 guix/build-system/cmake.scm       | 4 ++++
 guix/build/cmake-build-system.scm | 5 ++++-
 3 files changed, 12 insertions(+), 1 deletion(-)

diff --git a/doc/guix.texi b/doc/guix.texi
index ddd98a5fd46..782893b4f23 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -9623,6 +9623,10 @@ Build Systems
 it defaults to @code{"RelWithDebInfo"} (short for ``release mode with
 debugging information''), which roughly means that code is compiled with
 @code{-O2 -g}, as is the case for Autoconf-based packages by default.
+The @code{#:generator} parameter configures the native build system; it
+defaults to @code{"Unix Makefiles"} and can be changed to an alternative
+such as @code{Ninja} (the alternative generator must be available as
+both a module and native input).
 @end defvar
 
 @defvar composer-build-system
diff --git a/guix/build-system/cmake.scm b/guix/build-system/cmake.scm
index aa187c9844b..a4d69276748 100644
--- a/guix/build-system/cmake.scm
+++ b/guix/build-system/cmake.scm
@@ -101,6 +101,7 @@ (define* (cmake-build name inputs
                       (search-paths '())
                       (make-flags ''())
                       (out-of-source? #t)
+                      (generator "Unix Makefiles")
                       (build-type "RelWithDebInfo")
                       (tests? #t)
                       (test-target "test")
@@ -140,6 +141,7 @@ (define* (cmake-build name inputs
                                                      configure-flags)
                              #:make-flags #$make-flags
                              #:out-of-source? #$out-of-source?
+                             #:generator #$generator
                              #:build-type #$build-type
                              #:tests? #$tests?
                              #:test-target #$test-target
@@ -177,6 +179,7 @@ (define* (cmake-cross-build name
                             (native-search-paths '())
                             (make-flags ''())
                             (out-of-source? #t)
+                            (generator "Unix Makefiles")
                             (build-type "RelWithDebInfo")
                             (tests? #f) ; nothing can be done
                             (test-target "test")
@@ -231,6 +234,7 @@ (define* (cmake-cross-build name
                        #:configure-flags #$configure-flags
                        #:make-flags #$make-flags
                        #:out-of-source? #$out-of-source?
+                       #:generator #$generator
                        #:build-type #$build-type
                        #:tests? #$tests?
                        #:test-target #$test-target
diff --git a/guix/build/cmake-build-system.scm b/guix/build/cmake-build-system.scm
index ea342ff2ac9..1775f7a7509 100644
--- a/guix/build/cmake-build-system.scm
+++ b/guix/build/cmake-build-system.scm
@@ -34,7 +34,7 @@ (define-module (guix build cmake-build-system)
 ;; Code:
 
 (define* (configure #:key outputs (configure-flags '()) (out-of-source? #t)
-                    build-type target
+                    build-type target generator
                     #:allow-other-keys)
   "Configure the given package."
   (let* ((out        (assoc-ref outputs "out"))
@@ -50,6 +50,9 @@ (define* (configure #:key outputs (configure-flags '()) (out-of-source? #t)
     (format #t "build directory: ~s~%" (getcwd))
 
     (let ((args `(,srcdir
+                  ,@(if generator
+                        (list (string-append "-G" generator))
+                        '())
                   ,@(if build-type
                         (list (string-append "-DCMAKE_BUILD_TYPE="
                                              build-type))
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:03 GMT) Full text and rfc822 format available.

Message #17 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 04/19] build-system/cmake: Add install.
Date: Wed, 27 Mar 2024 14:52:29 +0000
* guix/build/cmake-build-system.scm (build): New function to replace
make install with the cmake install command.
---
 guix/build/cmake-build-system.scm | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/guix/build/cmake-build-system.scm b/guix/build/cmake-build-system.scm
index 8f1c80aeb64..c3e095425f9 100644
--- a/guix/build/cmake-build-system.scm
+++ b/guix/build/cmake-build-system.scm
@@ -109,12 +109,16 @@ (define* (check #:key (tests? #t) (parallel-tests? #t)
                        '()))))
       (format #t "test suite not run~%")))
 
+(define* (install #:rest args)
+  (invoke "cmake" "--install" "."))
+
 (define %standard-phases
   (modify-phases gnu:%standard-phases
     (delete 'bootstrap)
     (replace 'build build)
     (replace 'check check)
-    (replace 'configure configure)))
+    (replace 'configure configure)
+    (replace 'install install)))
 
 (define* (cmake-build #:key inputs (phases %standard-phases)
                       #:allow-other-keys #:rest args)
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:04 GMT) Full text and rfc822 format available.

Message #20 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 05/19] gnu: libmedfile: Disable parallel tests.
Date: Wed, 27 Mar 2024 14:52:30 +0000
* gnu/packages/engineering.scm (libmedfile): Disable parallel tests.
---
 gnu/packages/engineering.scm | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/engineering.scm b/gnu/packages/engineering.scm
index 6af0c75eb2b..802f45f5cf6 100644
--- a/gnu/packages/engineering.scm
+++ b/gnu/packages/engineering.scm
@@ -2941,7 +2941,8 @@ (define-public libmedfile
     (build-system cmake-build-system)
     (inputs (list hdf5-1.10))
     (arguments
-     `(#:phases
+     `(#:parallel-tests? #f
+       #:phases
        (modify-phases %standard-phases
          (add-after 'install 'remove-test-output
            (lambda* (#:key outputs #:allow-other-keys)
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:04 GMT) Full text and rfc822 format available.

Message #23 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 06/19] gnu: srt: Disable parallel tests.
Date: Wed, 27 Mar 2024 14:52:31 +0000
* gnu/packages/networking.scm (srt): Disable parallel tests.
---
 gnu/packages/networking.scm | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/networking.scm b/gnu/packages/networking.scm
index 3a743730a63..de89ba91e7e 100644
--- a/gnu/packages/networking.scm
+++ b/gnu/packages/networking.scm
@@ -642,7 +642,8 @@ (define-public srt
         (base32 "1zr1l9zkai7rpw9cn5j9h4zrv08hgpfmwscwyscf2j4cgwf0rxrr"))))
     (build-system cmake-build-system)
     (arguments
-     `(#:configure-flags
+     `(#:parallel-tests? #f
+       #:configure-flags
        (list
         (string-append "-DCMAKE_INSTALL_BINDIR="
                        (assoc-ref %outputs "out") "/bin")
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:05 GMT) Full text and rfc822 format available.

Message #26 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 07/19] gnu: fish: Fix tests.
Date: Wed, 27 Mar 2024 14:52:32 +0000
* gnu/packages/shells.scm (fish)[arguments]: Replace 'check phase to
properly build and run tests.

Change-Id: I1f5d82d7b4e817be3863ae7aff4798774b15cc2f
---
 gnu/packages/shells.scm | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/gnu/packages/shells.scm b/gnu/packages/shells.scm
index ae4e73956e6..e4856d94c8a 100644
--- a/gnu/packages/shells.scm
+++ b/gnu/packages/shells.scm
@@ -243,6 +243,11 @@ (define-public fish
                 port)
                (close-port port))
              #t))
+         (replace 'check
+           (lambda* (#:key tests? #:allow-other-keys)
+             (when tests?
+               ;; Test artifacts and actions are built with the 'test' target.
+               (invoke "make" "test"))))
          ;; Use fish-foreign-env to source /etc/profile.
          (add-before 'install 'source-etc-profile
            (lambda* (#:key inputs #:allow-other-keys)
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:05 GMT) Full text and rfc822 format available.

Message #29 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 08/19] gnu: vulkan-loader: Disable parallel tests.
Date: Wed, 27 Mar 2024 14:52:33 +0000
* gnu/packages/vulkan.scm (vulkan-loader): Disable parallel tests.
---
 gnu/packages/vulkan.scm | 1 +
 1 file changed, 1 insertion(+)

diff --git a/gnu/packages/vulkan.scm b/gnu/packages/vulkan.scm
index 285d6be7f59..ce7bbef02a8 100644
--- a/gnu/packages/vulkan.scm
+++ b/gnu/packages/vulkan.scm
@@ -266,6 +266,7 @@ (define-public vulkan-loader
       ;; Limit the tests to those architectures tested upstream.
       #:tests? (and (%current-system)
                     (target-x86?))
+      #:parallel-tests? #f
       #:configure-flags
       #~(list (string-append "-DVULKAN_HEADERS_INSTALL_DIR="
                              (dirname (dirname
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:05 GMT) Full text and rfc822 format available.

Message #32 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 09/19] gnu: igraph: Move test target to check
 phase.
Date: Wed, 27 Mar 2024 14:52:34 +0000
* gnu/packages/graph.scm (igraph)[arguments]: Replace 'check phase to
replace the old cmake-build-system test target.

Change-Id: Idf5a8913e22f30b1aa02fdad12212bf690ddc0c4
---
 gnu/packages/graph.scm | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/graph.scm b/gnu/packages/graph.scm
index a3607689a3e..30dd1a59cfa 100644
--- a/gnu/packages/graph.scm
+++ b/gnu/packages/graph.scm
@@ -142,7 +142,6 @@ (define-public igraph
               ;; Use the same integer width as suitesparse-cxsparse, which
               ;; uses int64_t in SuiteSparse v6.0.0 and later.
               "-DIGRAPH_INTEGER_SIZE=64")
-      #:test-target "check"
       #:phases
       #~(modify-phases %standard-phases
           (add-after 'unpack 'version-file
@@ -174,6 +173,10 @@ (define-public igraph
           (add-after 'build 'build-doc
             (lambda _
               (invoke "cmake" "--build" "." "--target" "html")))
+          (replace 'check
+            (lambda* (#:key tests? #:allow-other-keys)
+              (when tests?
+                (invoke "make" "check"))))
           (add-after 'install 'install-doc
             (lambda _
               (copy-recursively
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:06 GMT) Full text and rfc822 format available.

Message #35 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 10/19] gnu: inkscape: Move test target to check
 phase.
Date: Wed, 27 Mar 2024 14:52:35 +0000
* gnu/packages/inkscape.scm (inkscape)[arguments]: Replace 'check phase to
replace the old cmake-build-system test target.

Change-Id: I2d7046baaaa5bfcd6909d0d9dc3e6e6c4eb3e1e3
---
 gnu/packages/inkscape.scm | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/gnu/packages/inkscape.scm b/gnu/packages/inkscape.scm
index aa2c6419a09..9ce9f81cfda 100644
--- a/gnu/packages/inkscape.scm
+++ b/gnu/packages/inkscape.scm
@@ -156,8 +156,7 @@ (define-public inkscape/stable
               ((".*find_package\\(DoubleConversion.*") ""))))))
      (build-system cmake-build-system)
      (arguments
-      `(#:test-target "check"         ;otherwise some test binaries are missing
-        #:imported-modules (,@%cmake-build-system-modules
+      `(#:imported-modules (,@%cmake-build-system-modules
                             (guix build glib-or-gtk-build-system))
         #:modules ((guix build cmake-build-system)
                    ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:)
@@ -220,7 +219,10 @@ (define-public inkscape/stable
           ;; as the "share/inkscape/ui/units.xml" file.
           (delete 'check)
           (add-after 'install 'check
-            (assoc-ref %standard-phases 'check))
+            (lambda* (#:key tests? #:allow-other-keys)
+              (when tests?
+                ;; Test artifacts and actions are built with the 'test' target.
+                (invoke "make" "check"))))
           (add-after 'install 'glib-or-gtk-compile-schemas
             (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-compile-schemas))
           (add-after 'glib-or-gtk-compile-schemas 'glib-or-gtk-wrap
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:06 GMT) Full text and rfc822 format available.

Message #38 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 11/19] gnu: vigra: Move test target to check
 phase.
Date: Wed, 27 Mar 2024 14:52:36 +0000
* gnu/packages/image.scm (vigra)[arguments]: Replace 'check phase to
replace the old cmake-build-system test target.

Change-Id: I6465caaff8c249373537652d001b22a4d9eafe09
---
 gnu/packages/image.scm | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/gnu/packages/image.scm b/gnu/packages/image.scm
index 6accf68ef09..45ded6af04b 100644
--- a/gnu/packages/image.scm
+++ b/gnu/packages/image.scm
@@ -1370,8 +1370,7 @@ (define-public vigra
         ("python-nose" ,python-nose)
         ("sphinx" ,python-sphinx)))
      (arguments
-      `(#:test-target "check"
-        #:phases
+      `(#:phases
         (modify-phases %standard-phases
           (add-after 'unpack 'disable-broken-tests
             (lambda _
@@ -1382,7 +1381,11 @@ (define-public vigra
               ;; <https://github.com/ukoethe/vigra/issues/436>.
               (substitute* "vigranumpy/test/CMakeLists.txt"
                 (("test1\\.py") ""))
-              #t)))
+              #t))
+          (replace 'check
+            (lambda* (#:key tests? #:allow-other-keys)
+              (when tests?
+                (invoke "make" "check")))))
         #:configure-flags
           (list "-Wno-dev" ; suppress developer mode with lots of warnings
                 (string-append "-DVIGRANUMPY_INSTALL_DIR="
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:07 GMT) Full text and rfc822 format available.

Message #41 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 12/19] gnu: cpp-httplib: Disable parallel tests.
Date: Wed, 27 Mar 2024 14:52:37 +0000
* gnu/packages/cpp.scm (cpp-httplib): Disable parallel tests.
---
 gnu/packages/cpp.scm | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/cpp.scm b/gnu/packages/cpp.scm
index acbe3e4836b..1f9f4db2712 100644
--- a/gnu/packages/cpp.scm
+++ b/gnu/packages/cpp.scm
@@ -981,7 +981,8 @@ (define-public cpp-httplib
        (file-name (git-file-name name version))))
     (build-system cmake-build-system)
     (arguments
-     `(#:configure-flags
+     `(#:parallel-tests? #f
+       #:configure-flags
        '("-DBUILD_SHARED_LIBS=ON"
          "-DHTTPLIB_TEST=ON"
          "-DHTTPLIB_COMPILE=ON"
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:07 GMT) Full text and rfc822 format available.

Message #44 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 13/19] gnu: libical: Disable parallel tests.
Date: Wed, 27 Mar 2024 14:52:38 +0000
* gnu/packages/calendar.scm (libical): Disable parallel tests.
---
 gnu/packages/calendar.scm | 1 +
 1 file changed, 1 insertion(+)

diff --git a/gnu/packages/calendar.scm b/gnu/packages/calendar.scm
index 7c75b225871..1dd068603bb 100644
--- a/gnu/packages/calendar.scm
+++ b/gnu/packages/calendar.scm
@@ -135,6 +135,7 @@ (define-public libical
     (build-system cmake-build-system)
     (arguments
      (list
+      #:parallel-tests? #f
       #:configure-flags #~(list "-DSHARED_ONLY=true"
                                 ;; required by evolution-data-server
                                 "-DGOBJECT_INTROSPECTION=true"
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:07 GMT) Full text and rfc822 format available.

Message #47 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 14/19] gnu: astroid: Remove custom phases.
Date: Wed, 27 Mar 2024 14:52:39 +0000
* gnu/packages/mail.scm (astroid)[arguments]:
Disable parallel tests.
Add generator.
Remove custom 'build, 'check, and 'install phases.
---
 gnu/packages/mail.scm | 16 +++-------------
 1 file changed, 3 insertions(+), 13 deletions(-)

diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm
index 23c78a6db5b..e99736752f0 100644
--- a/gnu/packages/mail.scm
+++ b/gnu/packages/mail.scm
@@ -903,13 +903,14 @@ (define-public astroid
              (("\\\\n\\.\\.\\.") "\\n...\\n"))))))
     (build-system cmake-build-system)
     (arguments
-     `(#:modules ((guix build cmake-build-system)
+     `(#:parallel-tests? #f
+       #:modules ((guix build cmake-build-system)
                   ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:)
                   (guix build utils)
                   (ice-9 match))
        #:imported-modules ((guix build glib-or-gtk-build-system)
                            ,@%cmake-build-system-modules)
-       #:configure-flags (list "-GNinja")
+       #:generator "Ninja"
        #:phases
        (modify-phases %standard-phases
          (add-after 'unpack 'skip-markdown-test
@@ -920,23 +921,12 @@ (define-public astroid
            (lambda _
              (substitute* "tests/CMakeLists.txt"
                ((".*markdown.*") ""))))
-         (replace 'build
-           (lambda _
-             (invoke "ninja" "-j" (number->string (parallel-job-count)))))
          (add-before 'check 'start-xserver
            (lambda* (#:key inputs #:allow-other-keys)
              (let ((xorg-server (assoc-ref inputs "xorg-server")))
                (setenv "HOME" (getcwd))
                (system (format #f "~a/bin/Xvfb :1 &" xorg-server))
                (setenv "DISPLAY" ":1"))))
-         (replace 'check
-           (lambda* (#:key tests? #:allow-other-keys)
-             (when tests?
-               (setenv "CTEST_OUTPUT_ON_FAILURE" "1")
-               (invoke "ctest" "."))))
-         (replace 'install
-           (lambda _
-             (invoke "ninja" "install")))
          (add-after 'install 'wrap-with-GI_TYPELIB_PATH
            (lambda* (#:key inputs outputs #:allow-other-keys)
              (let ((out (assoc-ref outputs "out"))
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:08 GMT) Full text and rfc822 format available.

Message #50 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 15/19] gnu: websocketpp: Disable parallel tests.
Date: Wed, 27 Mar 2024 14:52:40 +0000
* gnu/packages/web.scm (websocketpp): Disable parallel tests.

Change-Id: I9fd6247cf59b26a1d8c08398b2408884fd0f4848
---
 gnu/packages/web.scm | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
index aab3ae18390..6a4f647e704 100644
--- a/gnu/packages/web.scm
+++ b/gnu/packages/web.scm
@@ -1802,7 +1802,8 @@ (define-public websocketpp
        (patches (search-patches "websocketpp-fix-for-cmake-3.15.patch"))))
     (build-system cmake-build-system)
     (inputs (list boost openssl))
-    (arguments '(#:configure-flags '("-DBUILD_TESTS=ON")
+    (arguments '(#:parallel-tests? #f
+                 #:configure-flags '("-DBUILD_TESTS=ON")
                  #:phases
                  (modify-phases %standard-phases
                    (add-after 'install 'remove-tests
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:08 GMT) Full text and rfc822 format available.

Message #53 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 16/19] gnu: mbedtls-lts: Disable parallel tests.
Date: Wed, 27 Mar 2024 14:52:41 +0000
* gnu/packages/tls.scm (mbedtls-lts): Disable parallel tests.

Change-Id: Ibaa4af6d12c9e8db931c0038b2bba9fbf1959592
---
 gnu/packages/tls.scm | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/tls.scm b/gnu/packages/tls.scm
index 2f212e9f90f..99830f5e10d 100644
--- a/gnu/packages/tls.scm
+++ b/gnu/packages/tls.scm
@@ -988,7 +988,8 @@ (define-public mbedtls-lts
         (base32 "070i5pxciw04swfqk1rmdprhsafn4cias3dlmkm467pqpjnhb394"))))
     (build-system cmake-build-system)
     (arguments
-     (list #:configure-flags
+     (list #:parallel-tests? #f
+           #:configure-flags
            #~(list "-DUSE_SHARED_MBEDTLS_LIBRARY=ON"
                    "-DUSE_STATIC_MBEDTLS_LIBRARY=OFF")
            #:phases
-- 
2.44.0





Information forwarded to andreas <at> enge.fr, bavier <at> posteo.net, sharlatanus <at> gmail.com, guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:08 GMT) Full text and rfc822 format available.

Message #56 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 17/19] gnu: scotch: Disable parallel tests.
Date: Wed, 27 Mar 2024 14:52:42 +0000
* gnu/packages/maths.scm (scotch): Disable parallel tests.

Change-Id: Ic1368158890b64fe485b197749e2f44b621733f8
---
 gnu/packages/maths.scm | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index 1b4d3256493..7765a703e32 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -4509,7 +4509,8 @@ (define-public scotch
      (list flex bison gfortran))
     (outputs '("out" "metis"))
     (arguments
-     `(#:configure-flags '("-DBUILD_SHARED_LIBS=YES" "-DINTSIZE=64"
+     `(#:parallel-tests? #f
+       #:configure-flags '("-DBUILD_SHARED_LIBS=YES" "-DINTSIZE=64"
                            "-DBUILD_PTSCOTCH=OFF")
        #:phases
        (modify-phases %standard-phases
-- 
2.44.0





Information forwarded to liliana.prikler <at> gmail.com, maxim.cournoyer <at> gmail.com, rg <at> raghavgururajan.name, vivien <at> planete-kraus.eu, guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:10 GMT) Full text and rfc822 format available.

Message #59 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 18/19] gnu: evolution-data-server: Disable
 parallel tests.
Date: Wed, 27 Mar 2024 14:52:43 +0000
* gnu/packages/gnome.scm (evolution-data-server): Disable parallel
tests.

Change-Id: Ib56a2b25aa331763f72d2fd5ad034aee9b8f2d83
---
 gnu/packages/gnome.scm | 1 +
 1 file changed, 1 insertion(+)

diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm
index 06256066bc1..13387cb3b6e 100644
--- a/gnu/packages/gnome.scm
+++ b/gnu/packages/gnome.scm
@@ -8141,6 +8141,7 @@ (define-public evolution-data-server
     (build-system cmake-build-system)
     (arguments
      (list
+      #:parallel-tests? #f
       #:configure-flags
       #~(let* ((lib (string-append #$output "/lib"))
                (runpaths (map (lambda (s)
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Wed, 27 Mar 2024 14:54:10 GMT) Full text and rfc822 format available.

Message #62 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: 70031 <at> debbugs.gnu.org
Cc: Greg Hogan <code <at> greghogan.com>
Subject: [core-updates PATCH 19/19] gnu: aws-c-common: Disable parallel tests.
Date: Wed, 27 Mar 2024 14:52:44 +0000
* gnu/packages/c.scm (aws-c-common): Disable parallel tests.

Change-Id: I7b8fb481e21ca6c61417ab3664f796998fe971ae
---
 gnu/packages/c.scm | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/c.scm b/gnu/packages/c.scm
index c004aade73d..0e9662eea55 100644
--- a/gnu/packages/c.scm
+++ b/gnu/packages/c.scm
@@ -866,7 +866,8 @@ (define-public aws-c-common
                 "089grcj58n4xs41kmnpaqpwsalcisjbqqb5yqahxxyfx2lf1j9c9"))))
     (build-system cmake-build-system)
     (arguments
-     '(#:configure-flags
+     '(#:parallel-tests? #f
+       #:configure-flags
        '("-DBUILD_SHARED_LIBS=ON")))
     (synopsis "Amazon Web Services core C library")
     (supported-systems '("i686-linux" "x86_64-linux"))
-- 
2.44.0





Information forwarded to guix-patches <at> gnu.org:
bug#70031; Package guix-patches. (Sun, 31 Mar 2024 00:38:01 GMT) Full text and rfc822 format available.

Message #65 received at 70031 <at> debbugs.gnu.org (full text, mbox):

From: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
To: Greg Hogan <code <at> greghogan.com>
Cc: Raghav Gururajan <rg <at> raghavgururajan.name>,
 Vivien Kraus <vivien <at> planete-kraus.eu>, 70031 <at> debbugs.gnu.org,
 Liliana Marie Prikler <liliana.prikler <at> gmail.com>
Subject: Re: [bug#70031] [core-updates PATCH 18/19] gnu:
 evolution-data-server: Disable parallel tests.
Date: Sat, 30 Mar 2024 20:36:51 -0400
Hi Greg,

Greg Hogan <code <at> greghogan.com> writes:

> * gnu/packages/gnome.scm (evolution-data-server): Disable parallel
> tests.
>
> Change-Id: Ib56a2b25aa331763f72d2fd5ad034aee9b8f2d83
> ---
>  gnu/packages/gnome.scm | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm
> index 06256066bc1..13387cb3b6e 100644
> --- a/gnu/packages/gnome.scm
> +++ b/gnu/packages/gnome.scm
> @@ -8141,6 +8141,7 @@ (define-public evolution-data-server
>      (build-system cmake-build-system)
>      (arguments
>       (list
> +      #:parallel-tests? #f
>        #:configure-flags
>        #~(let* ((lib (string-append #$output "/lib"))
>                 (runpaths (map (lambda (s)

A comment/upstream issue link would be nice.

-- 
Thanks,
Maxim




This bug report was last modified 34 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.