[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
07/09: gnu: libjpeg-turbo: Build with a minimal variant of CMake.
From: |
guix-commits |
Subject: |
07/09: gnu: libjpeg-turbo: Build with a minimal variant of CMake. |
Date: |
Wed, 22 Jan 2020 16:14:52 -0500 (EST) |
mbakke pushed a commit to branch core-updates
in repository guix.
commit ff5733d186839f32d1558a9e1f049d218613fa1a
Author: Marius Bakke <address@hidden>
AuthorDate: Fri Jan 17 19:18:04 2020 +0100
gnu: libjpeg-turbo: Build with a minimal variant of CMake.
This is necessary to avoid a circular dependency in the next commit.
* gnu/packages/curl.scm (curl-minimal): New public variable.
* gnu/packages/cmake.scm (cmake-minimal-bootstrap): New public variable.
* gnu/packages/image.scm (libjpeg-turbo)[arguments]: Add #:cmake.
---
gnu/packages/cmake.scm | 14 +++++++++++++-
gnu/packages/curl.scm | 12 +++++++++++-
gnu/packages/image.scm | 10 ++++++++--
3 files changed, 32 insertions(+), 4 deletions(-)
diff --git a/gnu/packages/cmake.scm b/gnu/packages/cmake.scm
index 21f11ac..cf542f1 100644
--- a/gnu/packages/cmake.scm
+++ b/gnu/packages/cmake.scm
@@ -5,7 +5,7 @@
;;; Copyright © 2014 Ian Denhardt <address@hidden>
;;; Copyright © 2015 Sou Bunnbu <address@hidden>
;;; Copyright © 2016 Efraim Flashner <address@hidden>
-;;; Copyright © 2017, 2018 Marius Bakke <address@hidden>
+;;; Copyright © 2017, 2018, 2020 Marius Bakke <address@hidden>
;;; Copyright © 2018 Arun Isaac <address@hidden>
;;; Copyright © 2018 Tobias Geerinckx-Rice <address@hidden>
;;; Copyright © 2019 Maxim Cournoyer <address@hidden>
@@ -232,6 +232,18 @@ and workspaces that can be used in the compiler
environment of your choice.")
(search-paths
(package-native-search-paths cmake-minimal))))
+;; 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
(inherit cmake)
diff --git a/gnu/packages/curl.scm b/gnu/packages/curl.scm
index b06d01c..9289e2f 100644
--- a/gnu/packages/curl.scm
+++ b/gnu/packages/curl.scm
@@ -46,7 +46,8 @@
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages python)
#:use-module (gnu packages tls)
- #:use-module (gnu packages web))
+ #:use-module (gnu packages web)
+ #:use-module (srfi srfi-1))
(define-public curl
(package
@@ -159,6 +160,15 @@ tunneling, and so on.")
"See COPYING in the distribution."))
(home-page "https://curl.haxx.se/")))
+;; This package exists mainly to bootstrap CMake. It must not depend on
+;; anything that uses cmake-build-system.
+(define-public curl-minimal
+ (hidden-package
+ (package/inherit
+ curl
+ (name "curl-minimal")
+ (inputs (alist-delete "openldap" (package-inputs curl))))))
+
(define-public kurly
(package
(name "kurly")
diff --git a/gnu/packages/image.scm b/gnu/packages/image.scm
index 709599f..4fef6fe 100644
--- a/gnu/packages/image.scm
+++ b/gnu/packages/image.scm
@@ -46,6 +46,7 @@
#:use-module (gnu packages autotools)
#:use-module (gnu packages boost)
#:use-module (gnu packages check)
+ #:use-module (gnu packages cmake)
#:use-module (gnu packages curl)
#:use-module (gnu packages compression)
#:use-module (gnu packages documentation)
@@ -1504,8 +1505,13 @@ is hereby granted."))))
(native-inputs
`(("nasm" ,nasm)))
(arguments
- '(#:configure-flags '("-DCMAKE_INSTALL_LIBDIR:PATH=lib"
- "-DENABLE_STATIC=0")))
+ `(#:configure-flags '("-DCMAKE_INSTALL_LIBDIR:PATH=lib"
+ "-DENABLE_STATIC=0")
+ ,@(if (%current-target-system)
+ '()
+ ;; Use a special "bootstrap" CMake for the native build to work
+ ;; around a circular dependency between CMake and this package.
+ `(#:cmake ,cmake-minimal-bootstrap))))
(home-page "https://libjpeg-turbo.org/")
(synopsis "SIMD-accelerated JPEG image handling library")
(description "libjpeg-turbo is a JPEG image codec that accelerates baseline
- branch core-updates updated (c2d837b -> a1552f5), guix-commits, 2020/01/22
- 02/09: gnu: Add deprecation notice for 'boost-with-python3'., guix-commits, 2020/01/22
- 01/09: gnu: cmake: Update to 3.16.3., guix-commits, 2020/01/22
- 06/09: gnu: RHash: Download tarball from SourceForge instead of a git checkout., guix-commits, 2020/01/22
- 03/09: gnu: Add deprecation notice for 'sqlite-with-column-metadata'., guix-commits, 2020/01/22
- 04/09: gnu: curl: Remove unused input., guix-commits, 2020/01/22
- 05/09: gnu: curl: Remove unnecessary reference to the "doc" output., guix-commits, 2020/01/22
- 07/09: gnu: libjpeg-turbo: Build with a minimal variant of CMake.,
guix-commits <=
- 09/09: gnu: Deprecate the 'libjpeg' variable., guix-commits, 2020/01/22
- 08/09: gnu: Replace uses of 'libjpeg' with 'libjpeg-turbo'., guix-commits, 2020/01/22