diff options
author | Marius Bakke <mbakke@fastmail.com> | 2019-11-28 15:10:30 +0100 |
---|---|---|
committer | Marius Bakke <mbakke@fastmail.com> | 2019-11-28 15:17:07 +0100 |
commit | ee9eafc1df043e6aacfdace1da046a86773dac67 (patch) | |
tree | 9c75863141e78014ad86218b6d598ddf560d7ae0 /gnu/packages/games.scm | |
parent | a54980253360d9d266980ef249f4a92836225a02 (diff) | |
download | guix-ee9eafc1df043e6aacfdace1da046a86773dac67.tar.gz |
gnu: openclonk: Adjust for GCC 7.
* gnu/packages/games.scm (openclonk)[arguments]: Add phase 'adjust-backward-cpp-includes'.
Diffstat (limited to 'gnu/packages/games.scm')
-rw-r--r-- | gnu/packages/games.scm | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm index dcb8aaf9d2..8955b597e6 100644 --- a/gnu/packages/games.scm +++ b/gnu/packages/games.scm @@ -27,7 +27,7 @@ ;;; Copyright © 2017, 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2017, 2019 nee <nee-git@hidamari.blue> ;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org> -;;; Copyright © 2017 Marius Bakke <mbakke@fastmail.com> +;;; Copyright © 2017, 2019 Marius Bakke <mbakke@fastmail.com> ;;; Copyright © 2017, 2018 Rutger Helling <rhelling@mykolab.com> ;;; Copyright © 2017 Roel Janssen <roel@gnu.org> ;;; Copyright © 2017, 2018, 2019 Nicolas Goaziou <mail@nicolasgoaziou.fr> @@ -6888,6 +6888,22 @@ a fortress beyond the forbidden swamp.") (("PATH_SUFFIXES \"src\" \"gtest\"") "PATH_SUFFIXES \"src\"")) #t)) + (add-after 'unpack 'adjust-backward-cpp-includes + (lambda _ + ;; XXX: The bundled backward-cpp exports a CMake "interface" + ;; that includes external libraries such as libdl from glibc. + ;; By default, CMake interface includes are treated as "system + ;; headers", and GCC behaves poorly when glibc is passed as a + ;; system header (causing #include_next failures). + + ;; Here we prevent targets that consume the Backward::Backward + ;; interface from treating it as "system includes". + (substitute* "CMakeLists.txt" + (("target_link_libraries\\((.+) Backward::Backward\\)" all target) + (string-append "set_property(TARGET " target " PROPERTY " + "NO_SYSTEM_FROM_IMPORTED true)\n" + all))) + #t)) (add-after 'unpack 'add-libiberty ;; Build fails upon linking executables without this. (lambda _ |