diff options
| author | Ludovic Courtès <ludo@gnu.org> | 2021-09-28 23:41:10 +0200 |
|---|---|---|
| committer | Ludovic Courtès <ludo@gnu.org> | 2021-09-28 23:45:00 +0200 |
| commit | 7d30e6e5c21f5e0b79f73428414fef2dbf75e7a6 (patch) | |
| tree | 5d2b6522c9dc5c8e7721aa1522c4f101e131db65 /gnu/packages/make-bootstrap.scm | |
| parent | 3f7893527548a9459a0bd88fed2a4dea1a34aeda (diff) | |
gnu: make-bootstrap: Allow compilation of the statically-link gawk.
Previously, linking would fail due to the '-fno-common' default in GCC 10:
ld: /gnu/store/…-glibc-2.33-static/lib/libc.a(getopt.o): in function `_getopt_internal_r':
(.text+0x6e0): multiple definition of `_getopt_internal_r'; support/libsupport.a(getopt.o):/tmp/guix-build-gawk-5.1.0.drv-0/gawk-5.1.0/support/getopt.c:404: first defined here
ld: /gnu/store/…-glibc-2.33-static/lib/libc.a(getopt.o): in function `_getopt_internal':
Reported by Thiago Jung Bauermann <bauermann@kolabnow.com>.
* gnu/packages/make-bootstrap.scm (%static-inputs) <gawk>: Remove
getopt.o from libsupport.a.
Diffstat (limited to 'gnu/packages/make-bootstrap.scm')
| -rw-r--r-- | gnu/packages/make-bootstrap.scm | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/gnu/packages/make-bootstrap.scm b/gnu/packages/make-bootstrap.scm index 2d7a97488d8..40c1f822308 100644 --- a/gnu/packages/make-bootstrap.scm +++ b/gnu/packages/make-bootstrap.scm | |||
| @@ -206,8 +206,17 @@ for `sh' in $PATH, and without nscd, and with static NSS modules." | |||
| 206 | (("^xz_LDADD =") | 206 | (("^xz_LDADD =") |
| 207 | "xz_LDADD = -all-static")) | 207 | "xz_LDADD = -all-static")) |
| 208 | #t))))))) | 208 | #t))))))) |
| 209 | (gawk (package (inherit gawk) | 209 | (gawk (package |
| 210 | (source (origin (inherit (package-source gawk)) | 210 | (inherit gawk) |
| 211 | (source (origin | ||
| 212 | (inherit (package-source gawk)) | ||
| 213 | (modules '((guix build utils))) | ||
| 214 | (snippet | ||
| 215 | ;; Do not build 'getopt.c' since that leads to a | ||
| 216 | ;; link failure due to duplicate symbols with | ||
| 217 | ;; 'libc.a'. | ||
| 218 | '(substitute* "support/Makefile.in" | ||
| 219 | (("getopt\\.\\$\\(OBJEXT\\)") ""))) | ||
| 211 | (patches (cons (search-patch "gawk-shell.patch") | 220 | (patches (cons (search-patch "gawk-shell.patch") |
| 212 | (origin-patches | 221 | (origin-patches |
| 213 | (package-source gawk)))))) | 222 | (package-source gawk)))))) |
