aboutsummaryrefslogtreecommitdiff
path: root/gnu
diff options
context:
space:
mode:
authorMaxim Cournoyer <maxim.cournoyer@gmail.com>2023-08-17 17:29:08 -0400
committerMaxim Cournoyer <maxim.cournoyer@gmail.com>2024-01-09 22:10:12 -0500
commitedb03ceb60d2f44162332878b1d1a1a34b5fd6a3 (patch)
tree4744ae37671ca06fcc2fbe16b220bcbd7883fc4d /gnu
parent504b46cd87dae437fec1949aeed2394951a92f77 (diff)
downloadguix-edb03ceb60d2f44162332878b1d1a1a34b5fd6a3.tar.gz
guix-edb03ceb60d2f44162332878b1d1a1a34b5fd6a3.zip
gnu: msgpack: Deprecate with msgpack-c.
* gnu/packages/serialization.scm (msgpack-c): New variable. (msgpack-cxx): New variable. (msgpack): Rename to... (msgpack-3): ... this, and inherit from msgpack-c. * gnu/packages/vim.scm (eovim) [arguments]: Add help-cmake-find-msgpack-c phase. [inputs]: Replace msgpack with msgpack-c. * gnu/packages/terminals.scm (tmate) [inputs]: Replace msgpack with msgpack-3. * gnu/packages/networking.scm (opendht) [propagated-inputs]: Replace msgpack with msgpack-cxx. * gnu/packages/chemistry.scm (mmtf-cpp) [propagated-inputs]: Likewise.
Diffstat (limited to 'gnu')
-rw-r--r--gnu/packages/chemistry.scm2
-rw-r--r--gnu/packages/networking.scm2
-rw-r--r--gnu/packages/serialization.scm71
-rw-r--r--gnu/packages/terminals.scm6
-rw-r--r--gnu/packages/vim.scm14
5 files changed, 71 insertions, 24 deletions
diff --git a/gnu/packages/chemistry.scm b/gnu/packages/chemistry.scm
index e177b27e9d..df96a2f5c1 100644
--- a/gnu/packages/chemistry.scm
+++ b/gnu/packages/chemistry.scm
@@ -263,7 +263,7 @@ molecules.")
(arguments '(#:tests? #f))
;; There is no support for modern msgpack versions yet (see:
;; https://github.com/rcsb/mmtf-cpp/issues/44).
- (propagated-inputs (list msgpack)) ;included by mmtf/structure_data.hpp
+ (propagated-inputs (list msgpack-3)) ;included by mmtf/structure_data.hpp
(home-page "https://mmtf.rcsb.org/")
(synopsis "C++ API for the Macromolecular Transmission Format")
(description "This package is a library for the
diff --git a/gnu/packages/networking.scm b/gnu/packages/networking.scm
index cc9b8e46ae..3d5cf598c9 100644
--- a/gnu/packages/networking.scm
+++ b/gnu/packages/networking.scm
@@ -3888,7 +3888,7 @@ and targeted primarily for asynchronous processing of HTTP-requests.")
fmt
readline))
(propagated-inputs
- (list msgpack ;included in several installed headers
+ (list msgpack-cxx ;included in several installed headers
restinio-0.6 ;included in opendht/http.h
;; The following are listed in the 'Requires.private' field of
;; opendht.pc:
diff --git a/gnu/packages/serialization.scm b/gnu/packages/serialization.scm
index e836b4f8b3..3ff3b57cb2 100644
--- a/gnu/packages/serialization.scm
+++ b/gnu/packages/serialization.scm
@@ -15,6 +15,7 @@
;;; Copyright © 2023 Alexey Abramov <levenson@mmer.org>
;;; Copyright © 2023 Sharlatan Hellseher <sharlatanus@gmail.com>
;;; Copyright © 2023 Vinicius Monego <monego@posteo.net>
+;;; Copyright © 2023 Maxim Cournoyer <maxim.cournoyer@gmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -219,8 +220,60 @@ such as compact binary encodings, XML, or JSON.")
(list doxygen gcc-10
(package-source cereal)))))
+(define-public msgpack-c
+ (package
+ (name "msgpack-c")
+ (version "6.0.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri
+ (string-append
+ "https://github.com/msgpack/msgpack-c/releases/download/"
+ "c-" version "/" name "-" version ".tar.gz"))
+ (sha256
+ (base32 "1fmf08babfsjq5qkgw034wk2nw6mayxp1qlkm7h55p2jqvigam1n"))
+ (snippet
+ '(let ((p (open-file "msgpack-c.pc.in" "a")))
+ (display "Requires: zlib\n" p)
+ (close-output-port p)))))
+ (build-system cmake-build-system)
+ (arguments (list #:configure-flags #~(list "-DMSGPACK_BUILD_TESTS=ON")))
+ (native-inputs (list googletest))
+ (propagated-inputs (list zlib)) ;zbuffer.h includes zlib.h
+ (home-page "https://www.msgpack.org")
+ (synopsis "Binary serialization library")
+ (description "Msgpack is a library for C that implements binary
+serialization.")
+ (license license:boost1.0)))
+
+(define-public msgpack-cxx
+ (package
+ (inherit msgpack-c)
+ (name "msgpack-cxx")
+ (version "6.1.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri
+ (string-append
+ "https://github.com/msgpack/msgpack-c/releases/download/"
+ "cpp-" version "/" name "-" version ".tar.gz"))
+ (sha256
+ (base32 "1rrrf3nskcv994z3pbq6a5z2021piz118rccmm1y7zlf7klygv93"))))
+ (build-system cmake-build-system)
+ (propagated-inputs (list boost zlib)) ;included in headers
+ (description "Msgpack is a library for C++ that implements binary
+serialization.")))
+
+;;; The msgpack package was split into msgpack-c and msgpack-cxx starting from
+;;; version 4.0.0.
(define-public msgpack
+ (deprecated-package "msgpack" msgpack-c))
+
+(define-public msgpack-3
(package
+ (inherit msgpack-c)
(name "msgpack")
(version "3.3.0")
(source
@@ -234,23 +287,13 @@ such as compact binary encodings, XML, or JSON.")
'(let ((p (open-file "msgpack.pc.in" "a")))
(display
(string-append "Requires: " "zlib" "\n") p)
- (close-output-port p)
- #t))
+ (close-output-port p)))
(sha256
(base32 "0yzhq50ijvwrfkr97knhvn54lj3f4hr3zy39yq8wpf6xll94s4bf"))))
- (build-system cmake-build-system)
- (native-inputs
- (list googletest-1.8 pkg-config))
- (propagated-inputs
- (list zlib)) ;; Msgpack installs two headers (zbuffer.h,
- ;; zbuffer.hpp) which #include <zlib.h>. However, 'guix gc --references'
- ;; does not detect a store reference to zlib since these headers are not
- ;; compiled.
- (home-page "https://www.msgpack.org")
- (synopsis "Binary serialization library")
+ (native-inputs (list googletest-1.8))
(description "Msgpack is a library for C/C++ that implements binary
-serialization.")
- (license license:boost1.0)))
+serialization. This is the legacy version that predates the split into C and
+C++ specific packages.")))
(define-public libmpack
(package
diff --git a/gnu/packages/terminals.scm b/gnu/packages/terminals.scm
index 53f67a80e5..f609de8eff 100644
--- a/gnu/packages/terminals.scm
+++ b/gnu/packages/terminals.scm
@@ -1289,10 +1289,8 @@ that can be displayed terminal.")
(base32
"0x5c31yq7ansmiy20a0qf59wagba9v3pq97mlkxrqxn4n1gcc6vi"))))
(build-system gnu-build-system)
- (inputs
- (list libevent libssh msgpack ncurses))
- (native-inputs
- (list autoconf automake pkg-config))
+ (inputs (list libevent libssh msgpack-3 ncurses))
+ (native-inputs (list autoconf automake pkg-config))
(home-page "https://tmate.io/")
(synopsis "Terminal sharing application")
(description "tmate is a terminal sharing application that allows you to
diff --git a/gnu/packages/vim.scm b/gnu/packages/vim.scm
index 1f7a005cb1..e301088394 100644
--- a/gnu/packages/vim.scm
+++ b/gnu/packages/vim.scm
@@ -884,6 +884,14 @@ refactor Vim in order to:
'(#:tests? #false ;no tests
#:phases
(modify-phases %standard-phases
+ (add-after 'unpack 'help-cmake-find-msgpack-c
+ (lambda _
+ ;; Patch the build system so that it can find the modern
+ ;; 'msgpack-c' named pkg-config file (see:
+ ;; https://github.com/jeanguyomarch/eovim/issues/73).
+ (substitute* "cmake/Modules/FindMsgPack.cmake"
+ (("MSGPACK QUIET msgpack")
+ "MSGPACK QUIET msgpack-c msgpack"))))
(add-after 'configure 'reference-nvim
(lambda* (#:key inputs #:allow-other-keys)
(let ((nvim (search-input-file inputs "/bin/nvim")))
@@ -894,10 +902,8 @@ refactor Vim in order to:
(string-append start nvim))))))
(add-before 'build 'set-home
(lambda _ (setenv "HOME" "/tmp"))))))
- (native-inputs
- (list pkg-config))
- (inputs
- (list efl msgpack neovim))
+ (native-inputs (list pkg-config))
+ (inputs (list efl msgpack-c neovim))
(home-page "https://github.com/jeanguyomarch/eovim/")
(synopsis "EFL GUI for Neovim")
(description "Graphical Neovim interface based on the @acronym{EFL, Enlightenment