summaryrefslogtreecommitdiff
path: root/gnu/packages/debug.scm
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/packages/debug.scm')
-rw-r--r--gnu/packages/debug.scm17
1 files changed, 15 insertions, 2 deletions
diff --git a/gnu/packages/debug.scm b/gnu/packages/debug.scm
index 3e86564e18..d454bceb40 100644
--- a/gnu/packages/debug.scm
+++ b/gnu/packages/debug.scm
@@ -1,6 +1,6 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2014, 2015, 2016, 2017, 2019-2022 Eric Bavier <bavier@posteo.net>
-;;; Copyright © 2016, 2017, 2018, 2020, 2021 Efraim Flashner <efraim@flashner.co.il>
+;;; Copyright © 2016-2018, 2020, 2021, 2025 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2018, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
;;; Copyright © 2018, 2019 Rutger Helling <rhelling@mykolab.com>
;;; Copyright © 2019 Pkill -9 <pkill9@runbox.com>
@@ -220,7 +220,20 @@ tools that process C/C++ code.")
;; Only one of the following three can be enabled at the same time
;; "-DCPPDAP_USE_EXTERNAL_RAPIDJSON_PACKAGE=ON"
;; "-DCPPDAP_USE_EXTERNAL_JSONCPP_PACKAGE=ON"
- "-DCPPDAP_USE_EXTERNAL_NLOHMANN_JSON_PACKAGE=ON")))
+ "-DCPPDAP_USE_EXTERNAL_NLOHMANN_JSON_PACKAGE=ON")
+ #:phases
+ (if (target-riscv64?)
+ #~(modify-phases %standard-phases
+ ;; We need to unconditionally link with libatomic on some
+ ;; architectures to successfully build cmake.
+ (add-after 'unpack 'link-with-libatomic
+ (lambda _
+ (substitute* "CMakeLists.txt"
+ (("cppdap_set_target_options\\(cppdap\\)" all)
+ (string-append
+ all "\n\n"
+ "target_link_libraries(cppdap PRIVATE atomic)"))))))
+ #~%standard-phases)))
(native-inputs
(list googletest))
;; see lib/cmake/cppdap/cppdapConfig.cmake