From 6149fdfb5e97e3598e08b6516a96d647a14f03a6 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Tue, 2 Jan 2018 23:44:20 +0200 Subject: gnu: gcc@6: Fix building with glibc@2.26. * gnu/packages/gcc.scm (gcc@6)[source]: Add snippet to adjust linux-unwind.h to changes in glibc@2.26. Add patch. * gnu/packages/patches/gcc-libsanitizer-fix.patch: New file. * gnu/local.mk (dist_patch_DATA): Register it. --- gnu/packages/gcc.scm | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) (limited to 'gnu/packages/gcc.scm') diff --git a/gnu/packages/gcc.scm b/gnu/packages/gcc.scm index 020d2a7138..350a9bd3fb 100644 --- a/gnu/packages/gcc.scm +++ b/gnu/packages/gcc.scm @@ -444,10 +444,23 @@ Go. It also includes runtime support libraries for these languages.") (sha256 (base32 "1m0lr7938lw5d773dkvwld90hjlcq2282517d1gwvrfzmwgg42w5")) - (patches (search-patches "gcc-strmov-store-file-names.patch" + (patches (search-patches "gcc-libsanitizer-fix.patch" + "gcc-strmov-store-file-names.patch" "gcc-6-source-date-epoch-1.patch" "gcc-6-source-date-epoch-2.patch" - "gcc-5.0-libvtv-runpath.patch")))) + "gcc-5.0-libvtv-runpath.patch")) + (modules '((guix build utils))) + ;; This is required for building with glibc-2.26. + ;; This can be removed when gcc-6.5.0 is released. + ;; https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81712 + (snippet + '(for-each + (lambda (dir) + (substitute* (string-append "libgcc/config/" + dir "/linux-unwind.h") + (("struct ucontext") "ucontext_t"))) + '("aarch64" "alpha" "bfin" "i386" "m68k" "nios2" + "pa" "sh" "tilepro" "xtensa"))))) (inputs `(("isl" ,isl) ,@(package-inputs gcc-4.7))))) -- cgit 1.4.1