summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2015-03-01 22:46:43 -0500
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2015-03-02 08:24:05 -0500
commit0289f2fb2a64df53b589b771f69c43126b029590 (patch)
treee29e757386a103edf931d80f9697ae9754bdf339 /configure.ac
parent4d1d2f0858bb2fa6c45f0a7b3d427e657c0d4f67 (diff)
build-sys: allow lto and FORTIFY_SOURCE with -O[sz]
https://bugs.freedesktop.org/show_bug.cgi?id=89382
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac4
1 files changed, 2 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac
index 01ee8dc994..419b5d4e8d 100644
--- a/configure.ac
+++ b/configure.ac
@@ -208,13 +208,13 @@ AS_CASE([$CC], [*clang*],
-Wno-gnu-variable-sized-type-not-at-end \
])])
-AS_CASE([$CFLAGS], [*-O[[12345\ ]]*],
+AS_CASE([$CFLAGS], [*-O[[12345sz\ ]]*],
[CC_CHECK_FLAGS_APPEND([with_cflags], [CFLAGS], [\
-flto -ffat-lto-objects])],
[AC_MSG_RESULT([skipping -flto, optimization not enabled])])
AC_SUBST([OUR_CFLAGS], "$with_cflags $sanitizer_cflags")
-AS_CASE([$CFLAGS], [*-O[[12345\ ]]*],
+AS_CASE([$CFLAGS], [*-O[[12345sz\ ]]*],
[CC_CHECK_FLAGS_APPEND([with_cppflags], [CPPFLAGS], [\
-Wp,-D_FORTIFY_SOURCE=2])],
[AC_MSG_RESULT([skipping -D_FORTIFY_SOURCE, optimization not enabled])])