summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHennadii Stepanov <hebasto@gmail.com>2025-10-12 21:54:31 +0100
committerAndreas Enge <andreas@enge.fr>2025-11-21 18:55:14 +0100
commitcc2b871e5f43b3a00df253f38070e7e049ec1462 (patch)
treeed0f1ad448bb5a6263c81784ee97522ae67ac7a1
parentba7ec6e9127b01fdb265f760da5ffcb7f1ffaa3f (diff)
gnu: capnproto: Improve package.
* gnu/packages/serialization.scm (capnproto)[arguments]: Use gexps. <#:configure-flags>: Add -DCMAKE_POSITION_INDEPENDENT_CODE=ON. <#:phases>: Relocate the 'use-tmp-for-temporary-files phase before the 'check phase. Set TEST_TMPDIR rather than patching the source. Change-Id: I8eb5af1e89af8a8697237432c655df880c29296a Signed-off-by: Andreas Enge <andreas@enge.fr>
-rw-r--r--gnu/packages/serialization.scm21
1 files changed, 12 insertions, 9 deletions
diff --git a/gnu/packages/serialization.scm b/gnu/packages/serialization.scm
index f7bf738d50e..18299d9a701 100644
--- a/gnu/packages/serialization.scm
+++ b/gnu/packages/serialization.scm
@@ -21,6 +21,7 @@
;;; Copyright © 2024 Arun Isaac <arunisaac@systemreboot.net>
;;; Copyright © 2024 Wilko Meyer <w@wmeyer.eu>
;;; Copyright © 2024, 2025 David Elsing <david.elsing@posteo.net>
+;;; Copyright © 2025 Hennadii Stepanov <hebasto@gmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -684,15 +685,17 @@ This package also provides @samp{kdlpp}, a C++20 wrapper around @samp{ckdl}.")
"1vs2zpk4l55hb4lq4kldbwdqcjnwm1jblhcaqxmii9dxrd7f807d"))))
(build-system cmake-build-system)
(arguments
- `(#:phases
- (modify-phases %standard-phases
- (add-after 'unpack 'use-tmp-for-temporary-files
- (lambda _
- ;; Use /tmp for temporary files, as the default /var/tmp directory
- ;; doesn't exist.
- (substitute* "src/kj/filesystem-disk-test.c++"
- (("VAR\\_TMP \"/var/tmp\"")
- "VAR_TMP \"/tmp\"")))))))
+ (list
+ #:configure-flags
+ #~(list "-DCMAKE_POSITION_INDEPENDENT_CODE=ON")
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-before 'check 'use-tmp-for-temporary-files
+ (lambda _
+ ;; Use TMPDIR for temporary files, as the default /var/tmp directory
+ ;; doesn't exist.
+ (setenv "TEST_TMPDIR"
+ (getenv "TMPDIR")))))))
(home-page "https://capnproto.org")
(synopsis "Capability-based RPC and serialization system")
(description