summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGreg Hogan <code@greghogan.com>2025-04-22 19:41:02 +0000
committerGreg Hogan <code@greghogan.com>2025-05-02 16:28:18 +0000
commit0b83a27b67ae92e988795322ae988518ec3e6972 (patch)
tree3ba43bc4ac3faca24fd2003699a69a246c0ba091
parent79efb94290663007ffeda48031f91ede1396ba90 (diff)
gnu: spdlog: Unbundle dependency.
* gnu/packages/logging.scm (spdlog-1.15, spdlog-1.13, spdlog-1.10) [source]: Remove bundled fmt ... [propagated-inputs]: ... and add corresponding fmt. [arguments]<#:configure-flags>: Use system fmt. [license]: Remove fmt license. (spdlog): Pin to spdlog-1.13. * gnu/packages/xdisorg.scm (j4-dmenu-desktop)[inputs]: Replace spdlog with spdlog-1.15 and remove fmt-11. Change-Id: I8bea1e6a0cb375eaaeb8fdf0843a62d86d9fc4fd
-rw-r--r--gnu/packages/logging.scm28
-rw-r--r--gnu/packages/pretty-print.scm2
-rw-r--r--gnu/packages/xdisorg.scm2
3 files changed, 23 insertions, 9 deletions
diff --git a/gnu/packages/logging.scm b/gnu/packages/logging.scm
index 802cb7735d..7891ccce5f 100644
--- a/gnu/packages/logging.scm
+++ b/gnu/packages/logging.scm
@@ -52,6 +52,7 @@
#:use-module (gnu packages networking)
#:use-module (gnu packages perl)
#:use-module (gnu packages pkg-config)
+ #:use-module (gnu packages pretty-print)
#:use-module (gnu packages python)
#:use-module (gnu packages python-build)
#:use-module (gnu packages python-check)
@@ -248,13 +249,16 @@ output in multiple windows in a terminal.")
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
- (base32 "0n6i8d5aycvp9n2zz2rz67s1y19cw9m5j3pk4719d3a5czh4267m"))))
+ (base32 "0n6i8d5aycvp9n2zz2rz67s1y19cw9m5j3pk4719d3a5czh4267m"))
+ (modules '((guix build utils)))
+ (snippet #~(delete-file-recursively "include/spdlog/fmt/bundled"))))
(build-system cmake-build-system)
(outputs '("out" "bin"))
(arguments
(list #:configure-flags
#~(list "-DSPDLOG_BUILD_BENCH=ON"
"-DSPDLOG_BUILD_SHARED=ON"
+ "-DSPDLOG_FMT_EXTERNAL=ON"
#$@(if (%current-target-system)
'()
'("-DSPDLOG_BUILD_TESTS=ON")))
@@ -273,13 +277,12 @@ output in multiple windows in a terminal.")
")\n"))))))))
(native-inputs (list catch2-3))
(inputs (list googlebenchmark))
+ (propagated-inputs (list fmt-11))
(home-page "https://github.com/gabime/spdlog")
(synopsis "Fast C++ logging library")
(description "Spdlog is a very fast header-only/compiled C++ logging
library.")
- ;; spdlog is under Expat license, but the bundled fmt library in
- ;; "include/spdlog/fmt/bundled" is under BSD 2 clause license.
- (license (list license:expat license:bsd-2))))
+ (license license:expat)))
(define-public spdlog-1.13
(package/inherit spdlog-1.15
@@ -292,7 +295,12 @@ library.")
(commit (string-append "v" version))))
(file-name (git-file-name (package-name spdlog-1.15) version))
(sha256
- (base32 "0zgdmdgnp2y36jrlk85d4fiyjkjd6anly8pambyc3f3v6sg02zyy"))))))
+ (base32 "0zgdmdgnp2y36jrlk85d4fiyjkjd6anly8pambyc3f3v6sg02zyy"))
+ (modules '((guix build utils)))
+ (snippet #~(delete-file-recursively "include/spdlog/fmt/bundled"))))
+ (propagated-inputs
+ (modify-inputs (package-propagated-inputs spdlog-1.15)
+ (replace "fmt" fmt-9)))))
(define-public spdlog-1.10
(package
@@ -306,9 +314,15 @@ library.")
(commit (string-append "v" version))))
(file-name (git-file-name "spdlog" version))
(sha256
- (base32 "02xz017ba9fssm1rp1fcfld7h79awbr6fqai9dxaqp02akp3davk"))))))
+ (base32 "02xz017ba9fssm1rp1fcfld7h79awbr6fqai9dxaqp02akp3davk"))
+ (modules '((guix build utils)))
+ (snippet #~(delete-file-recursively "include/spdlog/fmt/bundled"))))
+ (propagated-inputs
+ (modify-inputs (package-propagated-inputs spdlog-1.15)
+ (replace "fmt" fmt-8)))))
-(define-public spdlog spdlog-1.15)
+;; Update when changing the pinned version of fmt.
+(define-public spdlog spdlog-1.13)
(define-public rsyslog
(package
diff --git a/gnu/packages/pretty-print.scm b/gnu/packages/pretty-print.scm
index fb676539b2..cd42582dc9 100644
--- a/gnu/packages/pretty-print.scm
+++ b/gnu/packages/pretty-print.scm
@@ -299,7 +299,7 @@ a fast alternative to @code{IOStreams}.")
("clang" ,clang-6)))))
;; Note: Updating fmt causes some 1000s of rebuilds, so let's have a pinned
-;; version.
+;; version. When changing also update the pinned version of spdlog.
(define-public fmt fmt-9)
(define-public source-highlight
diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm
index 2f52e2ab99..4ee3ae3f60 100644
--- a/gnu/packages/xdisorg.scm
+++ b/gnu/packages/xdisorg.scm
@@ -3538,7 +3538,7 @@ create layout indicator widgets.")
(build-system meson-build-system)
(native-inputs
(list catch2-3 pkg-config))
- (inputs (list spdlog fmt-11))
+ (inputs (list spdlog-1.15))
(arguments
(list
#:configure-flags