diff options
Diffstat (limited to 'gnu/packages/golang.scm')
-rw-r--r-- | gnu/packages/golang.scm | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index 754724aa11..d97267b939 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -2,7 +2,7 @@ ;;; Copyright © 2016, 2017, 2018, 2019, 2020, 2021 Efraim Flashner <efraim@flashner.co.il> ;;; Copyright © 2016 Matthew Jordan <matthewjordandevops@yandex.com> ;;; Copyright © 2016 Andy Wingo <wingo@igalia.com> -;;; Copyright © 2016, 2019 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2016, 2019, 2021 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2016, 2017 Petter <petter@mykolab.ch> ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Leo Famulari <leo@famulari.name> ;;; Copyright © 2017 Sergei Trofimovich <slyfox@inbox.ru> @@ -309,6 +309,11 @@ in the style of communicating sequential processes (@dfn{CSP}).") (("/bin/pwd") (which "pwd")) (("/bin/sh") (which "sh"))) + ;; Backport fix for go-1.14 with GCC 9+ + ;; https://github.com/golang/go/issues/39157 + (substitute* "cmd/go/note_test.go" + (("cannot find 'ld'") "cannot find [‘']ld[’']")) + ;; Add libgcc to runpath (substitute* "cmd/link/internal/ld/lib.go" (("!rpath.set") "true")) @@ -789,7 +794,13 @@ in the style of communicating sequential processes (@dfn{CSP}).") (install-file file (string-append out "/share/doc/go"))) '("AUTHORS" "CONTRIBUTORS" "CONTRIBUTING.md" "PATENTS" "README.md" "SECURITY.md")))))))) - (inputs (alist-delete "gcc:lib" (package-inputs go-1.16))))) + (inputs (alist-delete "gcc:lib" (package-inputs go-1.16))) + (native-inputs + `(,@(if (not (member (%current-system) (package-supported-systems go-1.4))) + ;; gccgo-10.4, 11.3 and lower has a bug which causes bootstrapping + ;; to fail. Use go-1.16 until we have a newer version available. + (alist-replace "go" (list go-1.16) (package-native-inputs go-1.16)) + (package-native-inputs go-1.16)))))) (define-public go go-1.14) |