diff options
author | Greg Steuck <greg@nest.cx> | 2021-11-22 21:06:39 -0800 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2021-11-25 01:08:18 -0500 |
commit | 8961d632f34cffd90594406c697712d9dde4a626 (patch) | |
tree | bf7d8bf8a7c3d110cf9253137f4f1fb7d8cf5bca | |
parent | 4d34bf15e3bebb9f31467278e609f64a3e5b255d (diff) | |
download | haskell-8961d632f34cffd90594406c697712d9dde4a626.tar.gz |
Disable warnings for unused goto labels
Clang on OpenBSD aborts compilation with this diagnostics:
```
% "inplace/bin/ghc-stage1" -optc-Wno-error=unused-label -optc-Wall -optc-Werror -optc-Wall -optc-Wextra -optc-Wstrict-prototypes -optc-Wmissing-prototypes -optc-Wmissing-declarations -optc-Winline -optc-Wpointer-arith -optc-Wmissing-noreturn -optc-Wnested-externs -optc-Wredundant-decls -optc-Wno-aggregate-return -optc-fno-strict-aliasing -optc-fno-common -optc-Irts/dist-install/build/./autogen -optc-Irts/include/../dist-install/build/include -optc-Irts/include/. -optc-Irts/. -optc-DCOMPILING_RTS -optc-DFS_NAMESPACE=rts -optc-Wno-unknown-pragmas -optc-O2 -optc-fomit-frame-pointer -optc-g -optc-DRtsWay=\"rts_v\" -static -O0 -H64m -Wall -fllvm-fill-undef-with-garbage -Werror -this-unit-id rts -dcmm-lint -package-env - -i -irts -irts/dist-install/build -Irts/dist-install/build -irts/dist-install/build/./autogen -Irts/dist-install/build/./autogen -Irts/include/../dist-install/build/include -Irts/include/. -Irts/. -optP-DCOMPILING_RTS -optP-DFS_NAMESPACE=rts -O2 -Wcpp-undef -Wnoncanonical-monad-instances -c rts/linker/Elf.c -o rts/dist-install/build/linker/Elf.o
rts/linker/Elf.c:2169:1: error:
error: unused label 'dl_iterate_phdr_fail' [-Werror,-Wunused-label]
|
2169 | dl_iterate_phdr_fail:
| ^
dl_iterate_phdr_fail:
^~~~~~~~~~~~~~~~~~~~~
rts/linker/Elf.c:2172:1: error:
error: unused label 'dlinfo_fail' [-Werror,-Wunused-label]
|
2172 | dlinfo_fail:
| ^
dlinfo_fail:
^~~~~~~~~~~~
2 errors generated.
```
-rw-r--r-- | rts/ghc.mk | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/rts/ghc.mk b/rts/ghc.mk index 949107a7db..6d6ff4bb90 100644 --- a/rts/ghc.mk +++ b/rts/ghc.mk @@ -362,6 +362,7 @@ WARNING_OPTS += -Wnested-externs WARNING_OPTS += -Wredundant-decls # Some gccs annoyingly enable this archaic specimen by default WARNING_OPTS += -Wno-aggregate-return +WARNING_OPTS += -Wno-unused-label # These ones are hard to avoid: #WARNING_OPTS += -Wconversion |