From 86399b53ffefd607fc759e4f4630b64788a33cf4 Mon Sep 17 00:00:00 2001 From: Ivan Maidanski Date: Sun, 8 Jun 2014 17:24:17 +0400 Subject: [PATCH] Fix CFLAGS in configure regarding -O flag passing to SunCC compiler * configure.ac (CFLAGS): Add -O flag if Solaris SunCC (i.e., not GCC) regardless of threads support (i.e., even in case it is off). --- configure.ac | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index 5edd11bc..9539f0de 100644 --- a/configure.ac +++ b/configure.ac @@ -310,9 +310,8 @@ case "$THREADS" in ;; esac case "$host" in - sparc*-*-solaris*) + sparc*-*-solaris*) if test "$GCC" != yes; then - CFLAGS="-O $CFLAGS" need_atomic_ops_asm=true fi ;; @@ -382,6 +381,12 @@ case "$host" in powerpc-*-darwin*) powerpc_darwin=true ;; + *-*-solaris*) + if test "$GCC" != yes; then + # Solaris SunCC + CFLAGS="-O $CFLAGS" + fi + ;; *-*-wince*) if test "$enable_gc_debug" != "no"; then AC_DEFINE([GC_READ_ENV_FILE], 1, -- 2.40.0