guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

01/03: gnu: cmake: Update to 3.19.0.


From: guix-commits
Subject: 01/03: gnu: cmake: Update to 3.19.0.
Date: Tue, 24 Nov 2020 02:21:15 -0500 (EST)

apteryx pushed a commit to branch master
in repository guix.

commit 5458648302ca3ae4a60cde3ac3f94691d3afa039
Author: Maxim Cournoyer <maxim.cournoyer@gmail.com>
AuthorDate: Mon Nov 23 21:14:00 2020 -0500

    gnu: cmake: Update to 3.19.0.
    
    * gnu/packages/cmake.scm (cmake): Update to 3.19.0.
    [source]: Modify inherited source to adjust the hash as well as the snippet 
so
    that the "Utilities/cm3p" sub-directory is preserved.
    [phases]{patch-bin-sh, check}: Temporarily overrides until the next rebuild
    cycle.
---
 gnu/packages/cmake.scm | 71 +++++++++++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 70 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/cmake.scm b/gnu/packages/cmake.scm
index bfbedfd..f4b138e 100644
--- a/gnu/packages/cmake.scm
+++ b/gnu/packages/cmake.scm
@@ -8,7 +8,7 @@
 ;;; Copyright © 2017, 2018, 2020 Marius Bakke <mbakke@fastmail.com>
 ;;; Copyright © 2018 Arun Isaac <arunisaac@systemreboot.net>
 ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
-;;; Copyright © 2019 Maxim Cournoyer <maxim.cournoyer@gmail.com>
+;;; Copyright © 2019, 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com>
 ;;; Copyright © 2019 Pierre-Moana Levesque <pierre.moana.levesque@gmail.com>
 ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
 ;;;
@@ -297,6 +297,39 @@ and workspaces that can be used in the compiler 
environment of your choice.")
   (package
     (inherit cmake-minimal)
     (name "cmake")
+    (version "3.19.0")
+    ;; TODO: Move the following source field to the cmake-bootstrap package in
+    ;; the next rebuild cycle.
+    (source (origin
+              (inherit (package-source cmake-bootstrap))
+              (uri (string-append "https://cmake.org/files/v";
+                                  (version-major+minor version)
+                                  "/cmake-" version ".tar.gz"))
+              (sha256
+               (base32
+                "14zlrb7awiazxc5wlvgah9rw1dm4ziczbxiyqsvp4zmaan0ninpx"))
+              (snippet
+               (match (origin-snippet (package-source cmake-bootstrap))
+                 ((_ _ exp ...)
+                  ;; Now we can delete the remaining software bundles.
+                  (append `(begin
+                             (define preserved-files
+                               '(,@%preserved-third-party-files
+                                 ;; TODO: Move this file to the
+                                 ;; %preserved-third-party-files variable in
+                                 ;; the next rebuild cycle.
+                                 "Utilities/cm3p" ;CMake header wrappers
+                                 ;; Use the bundled JsonCpp during bootstrap
+                                 ;; to work around a circular dependency.
+                                 ;; TODO: JsonCpp can be built with Meson
+                                 ;; instead of CMake, but meson-build-system
+                                 ;; currently does not support
+                                 ;; cross-compilation.
+                                 "Utilities/cmjsoncpp"
+                                 ;; LibUV is required to bootstrap the initial
+                                 ;; build system.
+                                 "Utilities/cmlibuv")))
+                          exp))))))
     (arguments
      (substitute-keyword-arguments (package-arguments cmake-minimal)
        ;; Use cmake-minimal this time.
@@ -318,6 +351,42 @@ and workspaces that can be used in the compiler 
environment of your choice.")
                  ,flags))
        ((#:phases phases)
         `(modify-phases ,phases
+           ;; TODO: Remove this override in the next rebuild cycle and adjust
+           ;; the %common-build-phases variable instead: the
+           ;; Utilities/Release/release_cmake.cmake file no longer exists in
+           ;; version 3.19.0.
+           (replace 'patch-bin-sh
+             (lambda _
+               ;; Replace "/bin/sh" by the right path in... a lot of
+               ;; files.
+               (substitute*
+                   '("Modules/CompilerId/Xcode-3.pbxproj.in"
+                     "Modules/Internal/CPack/CPack.RuntimeScript.in"
+                     "Source/cmGlobalXCodeGenerator.cxx"
+                     "Source/cmLocalUnixMakefileGenerator3.cxx"
+                     "Source/cmExecProgramCommand.cxx"
+                     "Tests/CMakeLists.txt"
+                     "Tests/RunCMake/File_Generate/RunCMakeTest.cmake")
+                 (("/bin/sh") (which "sh")))
+               #t))
+           ;; TODO: Remove this override in the next rebuild cycle and adjust
+           ;; the %common-disabled-tests variable instead.
+           (replace 'check
+             (lambda* (#:key tests? parallel-tests? #:allow-other-keys)
+               (let ((skipped-tests (list ,@%common-disabled-tests
+                                          ;; This test fails for unknown 
reason.
+                                          
"RunCMake.file-GET_RUNTIME_DEPENDENCIES"
+                                          ;; This test requires the bundled 
libuv.
+                                          "BootstrapTest")))
+                 (if tests?
+                     (begin
+                       (invoke "ctest" "-j" (if parallel-tests?
+                                                (number->string 
(parallel-job-count))
+                                                "1")
+                               "--exclude-regex"
+                               (string-append "^(" (string-join skipped-tests 
"|") ")$")))
+                     (format #t "test suite not run~%"))
+                 #t)))
            (add-after 'install 'move-html-doc
              (lambda* (#:key outputs #:allow-other-keys)
                (let ((out (assoc-ref outputs "out"))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]