diff options
Diffstat (limited to 'gnu/packages/cmake.scm')
-rw-r--r-- | gnu/packages/cmake.scm | 86 |
1 files changed, 41 insertions, 45 deletions
diff --git a/gnu/packages/cmake.scm b/gnu/packages/cmake.scm index 2d2827ffee..cf542f12e4 100644 --- a/gnu/packages/cmake.scm +++ b/gnu/packages/cmake.scm @@ -5,10 +5,11 @@ ;;; Copyright © 2014 Ian Denhardt <ian@zenhack.net> ;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com> ;;; Copyright © 2016 Efraim Flashner <efraim@flashner.co.il> -;;; Copyright © 2017, 2018 Marius Bakke <mbakke@fastmail.com> +;;; 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 Pierre-Moana Levesque <pierre.moana.levesque@gmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -51,7 +52,7 @@ (define-public cmake-minimal (package (name "cmake-minimal") - (version "3.15.1") + (version "3.16.3") (source (origin (method url-fetch) (uri (string-append "https://www.cmake.org/files/v" @@ -59,7 +60,7 @@ "/cmake-" version ".tar.gz")) (sha256 (base32 - "1xyprly3sf4wi0n1x79k4n22yxm6pb7fv70gqr9lvc7qv14cbphq")) + "0s06wrp0jnw2l4yq94skj53hwnz7lqrmhh96sq7w7njkkggickz5")) (modules '((guix build utils))) (snippet '(begin @@ -75,7 +76,8 @@ "cmliblzma" ;; "cmlibuv" "cmzlib")) - #t))))) + #t))) + (patches (search-patches "cmake-curl-certificates.patch")))) (build-system gnu-build-system) (arguments `(#:test-target "test" @@ -100,6 +102,8 @@ (let ((skipped-tests (list "BundleUtilities" ; This test fails on Guix. "CTestTestSubdir" ; This test fails to build 2 of the 3 tests. + ;; This test requires 'ldconfig' which is not available in Guix. + "RunCMake.install" ;; These tests requires network access. "CTestCoverageCollectGCOV" "CTestTestUpload"))) @@ -124,7 +128,7 @@ ;; files. (substitute* '("Modules/CompilerId/Xcode-3.pbxproj.in" - "Modules/CPack.RuntimeScript.in" + "Modules/Internal/CPack/CPack.RuntimeScript.in" "Source/cmGlobalXCodeGenerator.cxx" "Source/cmLocalUnixMakefileGenerator3.cxx" "Source/cmExecProgramCommand.cxx" @@ -146,20 +150,32 @@ (replace 'configure (lambda* (#:key (configure-flags '()) #:allow-other-keys) (apply invoke "./configure" configure-flags)))))) - (inputs + (native-inputs `(("bzip2" ,bzip2) ("curl" ,curl) ("expat" ,expat) ("file" ,file) ("libarchive" ,libarchive) ("libuv" ,libuv) - ("ncurses" ,ncurses) ; required for ccmake ("rhash" ,rhash) ("zlib" ,zlib))) + (inputs + `(("ncurses" ,ncurses))) ; required for ccmake (native-search-paths (list (search-path-specification (variable "CMAKE_PREFIX_PATH") - (files '(""))))) + (files '(""))) + ;; "cmake-curl-certificates.patch" changes CMake to honor 'SSL_CERT_DIR' + ;; and 'SSL_CERT_FILE', hence these search path entries. + (search-path-specification + (variable "SSL_CERT_DIR") + (separator #f) ;single entry + (files '("etc/ssl/certs"))) + (search-path-specification + (variable "SSL_CERT_FILE") + (file-type 'regular) + (separator #f) ;single entry + (files '("etc/ssl/certs/ca-certificates.crt"))))) (home-page "https://cmake.org/") (synopsis "Cross-platform build system") (description @@ -208,45 +224,25 @@ and workspaces that can be used in the compiler environment of your choice.") (outputs '("out" "doc")) (properties (alist-delete 'hidden? (package-properties cmake-minimal))))) -(define-public cmake-3.15.5 - ;; CMake 3.15.5 fixes some issues, but declare another version to - ;; avoid triggering the rebuild of all CMake-based packages. - ;; See <https://issues.guix.gnu.org/issue/38060>. - ;; - ;; Furthermore, this variant fixes X.509 certificate lookup: - ;; <https://issues.guix.gnu.org/issue/37371>. +(define-public cmake-minimal-cross (package - (inherit cmake) - (version "3.15.5") - (source (origin - (inherit (package-source cmake)) - (uri (string-append "https://www.cmake.org/files/v" - (version-major+minor version) - "/cmake-" version ".tar.gz")) - (sha256 - (base32 - "1d5y8d92axcc6rfqlsxamayfs3fc1vdby91hn5mx1kn02ppprpgv")) - (patches - (append (search-patches "cmake-curl-certificates.patch") - (origin-patches (package-source cmake)))))) - - (native-search-paths - ;; "cmake-curl-certificates.patch" changes CMake to honor 'SSL_CERT_DIR' - ;; and 'SSL_CERT_FILE', hence these search path entries. - (append (list (search-path-specification - (variable "SSL_CERT_DIR") - (separator #f) ;single entry - (files '("etc/ssl/certs"))) - (search-path-specification - (variable "SSL_CERT_FILE") - (file-type 'regular) - (separator #f) ;single entry - (files '("etc/ssl/certs/ca-certificates.crt")))) - (package-native-search-paths cmake))))) + (inherit cmake-minimal) + (name "cmake-minimal-cross") + (native-search-paths '()) + (search-paths + (package-native-search-paths cmake-minimal)))) -;; This was cmake@3.15.1 plus "cmake-curl-certificates.patch". -(define-deprecated cmake/fixed cmake-3.15.5) -(export cmake/fixed) +;; The purpose of this package is to solve a circular dependency between +;; packages that use cmake-build-system and CMakes own dependencies. +(define-public cmake-minimal-bootstrap + (package + (inherit cmake-minimal) + (name "cmake-minimal-bootstrap") + (native-inputs + `(;; cURL depends on ghostscript (via groff and OpenLDAP), which depends on + ;; 'cmake-build-system' through libtiff and ultimately libjpeg-turbo. + ("curl" ,curl-minimal) + ,@(alist-delete "curl" (package-native-inputs cmake-minimal)))))) (define-public emacs-cmake-mode (package |