[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
380/416: gnu: go-1.18: Adjust patch-gcclib phase.
From: |
guix-commits |
Subject: |
380/416: gnu: go-1.18: Adjust patch-gcclib phase. |
Date: |
Fri, 14 Apr 2023 15:26:29 -0400 (EDT) |
apteryx pushed a commit to branch master
in repository guix.
commit 8a17609dd02ff1d54bb32a158cead6bcba06a145
Author: Efraim Flashner <efraim@flashner.co.il>
AuthorDate: Wed Apr 5 15:36:21 2023 +0300
gnu: go-1.18: Adjust patch-gcclib phase.
* gnu/packages/golang.scm (go-1.18)[arguments]: Adjust the custom
'patch-gcc:lib phase for changes in the source code.
---
gnu/packages/golang.scm | 44 +++++++++++++++++++++-----------------------
1 file changed, 21 insertions(+), 23 deletions(-)
diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm
index 24dae34e20..2b75730dcd 100644
--- a/gnu/packages/golang.scm
+++ b/gnu/packages/golang.scm
@@ -864,29 +864,27 @@ in the style of communicating sequential processes
(@dfn{CSP}).")
(substitute-keyword-arguments (package-arguments go-1.17)
((#:phases phases)
`(modify-phases ,phases
- (delete 'adjust-test-suite)
- ,@(if (or (target-arm?) (target-ppc64le?))
- '((replace 'patch-gcc:lib
- (lambda* (#:key inputs #:allow-other-keys)
- (let* ((gcclib (string-append (assoc-ref inputs
"gcc:lib") "/lib")))
- ;; Add libgcc to runpath
- (substitute* "src/cmd/link/internal/ld/lib.go"
- (("!rpath.set") "true"))
- (substitute* "src/cmd/go/internal/work/gccgo.go"
- (("cgoldflags := \\[\\]string\\{\\}")
- (string-append "cgoldflags := []string{"
- "\"-Wl,-rpath=" gcclib "\""
- "}"))
- (("\"-lgcc_s\", ")
- (string-append
- "\"-Wl,-rpath=" gcclib "\", \"-lgcc_s\", ")))
- (substitute* "src/cmd/go/internal/work/gc.go"
- (("ldflags, err := setextld\\(ldflags, compiler\\)")
- (string-append
- "ldflags, err := setextld(ldflags, compiler)\n"
- "ldflags = append(ldflags, \"-r\")\n"
- "ldflags = append(ldflags, \"" gcclib "\")\n")))))))
- '())))))))
+ ;; See the platforms using this phase in go-1.17.
+ (replace 'patch-gcc:lib
+ (lambda* (#:key inputs #:allow-other-keys)
+ (let* ((gcclib (string-append (assoc-ref inputs "gcc:lib")
"/lib")))
+ ;; Add libgcc to runpath
+ (substitute* "src/cmd/link/internal/ld/lib.go"
+ (("!rpath.set") "true"))
+ (substitute* "src/cmd/go/internal/work/gccgo.go"
+ (("cgoldflags := \\[\\]string\\{\\}")
+ (string-append "cgoldflags := []string{"
+ "\"-Wl,-rpath=" gcclib "\""
+ "}"))
+ (("\"-lgcc_s\", ")
+ (string-append
+ "\"-Wl,-rpath=" gcclib "\", \"-lgcc_s\", ")))
+ (substitute* "src/cmd/go/internal/work/gc.go"
+ (("ldflags, err := setextld\\(ldflags, compiler\\)")
+ (string-append
+ "ldflags, err := setextld(ldflags, compiler)\n"
+ "ldflags = append(ldflags, \"-r\")\n"
+ "ldflags = append(ldflags, \"" gcclib "\")\n"))))))))))))
(define-public go-1.19
(package
- 402/416: gnu: python-statmake: Update to 0.6.0., (continued)
- 402/416: gnu: python-statmake: Update to 0.6.0., guix-commits, 2023/04/14
- 395/416: gnu: heimdal: Apply patch to fix CVE-2022-45142., guix-commits, 2023/04/14
- 345/416: gnu: Add rust-base64-0.21., guix-commits, 2023/04/14
- 344/416: gnu: rust-futures-sink-0.3: Update to 0.3.26., guix-commits, 2023/04/14
- 367/416: gnu: python-gst: Update to 1.22.2., guix-commits, 2023/04/14
- 358/416: gnu: python-trio-typing: Switch to pyproject-build-system., guix-commits, 2023/04/14
- 331/416: gnu: rust-macrotest-1: Update to 1.0.9., guix-commits, 2023/04/14
- 355/416: gnu: python-pyopenssl: Update to 23.1.1., guix-commits, 2023/04/14
- 370/416: gnu: Add mecab-ipadic., guix-commits, 2023/04/14
- 384/416: news: Add 'de' translation., guix-commits, 2023/04/14
- 380/416: gnu: go-1.18: Adjust patch-gcclib phase.,
guix-commits <=
- 389/416: gnu: gerbil: Update to 0.17.0., guix-commits, 2023/04/14
- 383/416: news: Add entry for 'guix shell --container --nesting'., guix-commits, 2023/04/14
- 392/416: gnu: opendht: Update to 2.5.2., guix-commits, 2023/04/14
- 381/416: gnu: go-1.17: Fix test suite on powerpc64le-linux., guix-commits, 2023/04/14
- 412/416: gnu: xsettingsd: Use cmake-build-system., guix-commits, 2023/04/14
- 408/416: gnu: psautohint: Disable a failing test., guix-commits, 2023/04/14