diff options
author | Zdenek Kabelac <zkabelac@redhat.com> | 2015-05-13 21:30:20 +0200 |
---|---|---|
committer | Zdenek Kabelac <zkabelac@redhat.com> | 2015-05-14 00:19:33 +0200 |
commit | 3fa66d103652df217059e2629da816adb9599e7c (patch) | |
tree | 24344692850b0304d6e266ca594051e602b855c6 /configure.in | |
parent | f207a6d353c895c6078f8345340228a2a790a659 (diff) | |
download | lvm2-3fa66d103652df217059e2629da816adb9599e7c.tar.gz |
configure: set optimize flags when CFLAGS is unset
If we are given CFLAGS - preserve user's request and avoid placing
just -O2 there.
Diffstat (limited to 'configure.in')
-rw-r--r-- | configure.in | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/configure.in b/configure.in index 59337637e..161f832e4 100644 --- a/configure.in +++ b/configure.in @@ -26,10 +26,9 @@ AC_CONFIG_AUX_DIR(autoconf) dnl -- Get system type AC_CANONICAL_TARGET([]) +AS_IF([test -z "$CFLAGS"], [COPTIMISE_FLAG="-O2"]) case "$host_os" in linux*) - CFLAGS="$CFLAGS" - COPTIMISE_FLAG="-O2" CLDFLAGS="$CLDFLAGS -Wl,--version-script,.export.sym" ELDFLAGS="-Wl,--export-dynamic" # FIXME Generate list and use --dynamic-list=.dlopen.sym @@ -49,7 +48,6 @@ case "$host_os" in ;; darwin*) CFLAGS="$CFLAGS -no-cpp-precomp -fno-common" - COPTIMISE_FLAG="-O2" CLDFLAGS="$CLDFLAGS" ELDFLAGS= CLDWHOLEARCHIVE="-all_load" |