aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Göttsche <cgzones@googlemail.com>2023-02-01 11:55:08 +0100
committerJason Zaman <jason@perfinion.com>2023-02-10 22:18:46 -0800
commitf9df9487adeec9356611830a8f1ba373f65a034f (patch)
treea288e296de181376c7654b20d67f3618a9d0126b
parentd8eb8b309f7a3e11bdcf86505ed24c1d50007213 (diff)
downloadselinux-f9df9487adeec9356611830a8f1ba373f65a034f.tar.gz
libselinux: drop obsolete optimization flag
The optimization flag -funit-at-a-time is enabled by default in GCC[1] and not supported by Clang: clang: error: optimization flag '-funit-at-a-time' is not supported [-Werror,-Wignored-optimization-argument] [1]: https://gcc.gnu.org/onlinedocs/gcc/Optimize-Options.html Signed-off-by: Christian Göttsche <cgzones@googlemail.com> Acked-by: Jason Zaman <jason@perfinion.com>
-rw-r--r--libselinux/src/Makefile2
-rw-r--r--libselinux/utils/Makefile2
2 files changed, 2 insertions, 2 deletions
diff --git a/libselinux/src/Makefile b/libselinux/src/Makefile
index 70ba063a..36d57122 100644
--- a/libselinux/src/Makefile
+++ b/libselinux/src/Makefile
@@ -86,7 +86,7 @@ CFLAGS ?= -O -Wall -W -Wundef -Wformat-y2k -Wformat-security -Winit-self -Wmissi
-Wno-missing-field-initializers -Wno-sign-compare \
-Wno-format-nonliteral -Wframe-larger-than=$(MAX_STACK_SIZE) \
-fstack-protector-all --param=ssp-buffer-size=4 -fexceptions \
- -fasynchronous-unwind-tables -fdiagnostics-show-option -funit-at-a-time \
+ -fasynchronous-unwind-tables -fdiagnostics-show-option \
-Werror -Wno-aggregate-return -Wno-redundant-decls \
$(EXTRA_CFLAGS)
diff --git a/libselinux/utils/Makefile b/libselinux/utils/Makefile
index 801066cb..f3cedc11 100644
--- a/libselinux/utils/Makefile
+++ b/libselinux/utils/Makefile
@@ -32,7 +32,7 @@ CFLAGS ?= -O -Wall -W -Wundef -Wformat-y2k -Wformat-security -Winit-self -Wmissi
-Wno-missing-field-initializers -Wno-sign-compare \
-Wno-format-nonliteral -Wframe-larger-than=$(MAX_STACK_SIZE) -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 \
-fstack-protector-all --param=ssp-buffer-size=4 -fexceptions \
- -fasynchronous-unwind-tables -fdiagnostics-show-option -funit-at-a-time \
+ -fasynchronous-unwind-tables -fdiagnostics-show-option \
-Werror -Wno-aggregate-return -Wno-redundant-decls -Wstrict-overflow=5 \
$(EXTRA_CFLAGS)