<p>Alexander Traud has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.asterisk.org/7860">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">BuildSystem: Really do not pass unknown-warning options to the compiler.<br><br>When an older GCC version is called with a too new warning option, GCC exited<br>with an error and Asterisk was not built. Therefore, the configure script tests<br>the installed compiler whether it supports that warning option. If not, Asterisk<br>does not pass it to the installed compiler. However, some compilers (like clang)<br>do not exit (error) but give just a warning in such a case. Because the compiler<br>did not exit, Asterisk passed the unknown-warning option.<br><br>ASTERISK-27560<br><br>Change-Id: Ia9b7747f649b27ff5e9f75c3db3fee4fe7a29621<br>---<br>M configure<br>M configure.ac<br>2 files changed, 6 insertions(+), 6 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/60/7860/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">diff --git a/configure b/configure<br>index 2dd0277..c7c0c3a 100755<br>--- a/configure<br>+++ b/configure<br>@@ -18425,7 +18425,7 @@<br> <br> { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Wdeclaration-after-statement support" >&5<br> $as_echo_n "checking for -Wdeclaration-after-statement support... " >&6; }<br>-if $(${CC} -Wdeclaration-after-statement -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then<br>+if $(${CC} -Wdeclaration-after-statement -Werror -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then<br> { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5<br> $as_echo "yes" >&6; }<br> AST_DECLARATION_AFTER_STATEMENT=-Wdeclaration-after-statement<br>@@ -18477,7 +18477,7 @@<br> <br> { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Wno-format-truncation" >&5<br> $as_echo_n "checking for -Wno-format-truncation... " >&6; }<br>-if $(${CC} -O2 -Wno-format-truncation -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then<br>+if $(${CC} -Wno-format-truncation -Werror -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then<br> { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5<br> $as_echo "yes" >&6; }<br> AST_NO_FORMAT_TRUNCATION=-Wno-format-truncation<br>@@ -18490,7 +18490,7 @@<br> <br> { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Wshadow" >&5<br> $as_echo_n "checking for -Wshadow... " >&6; }<br>-if $(${CC} -Wshadow -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then<br>+if $(${CC} -Wshadow -Werror -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then<br> { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5<br> $as_echo "yes" >&6; }<br> AST_SHADOW_WARNINGS=-Wshadow<br>diff --git a/configure.ac b/configure.ac<br>index c617cf0..e333faf 100644<br>--- a/configure.ac<br>+++ b/configure.ac<br>@@ -1196,7 +1196,7 @@<br> AC_SUBST(AST_UNDEFINED_SANITIZER)<br> <br> AC_MSG_CHECKING(for -Wdeclaration-after-statement support)<br>-if $(${CC} -Wdeclaration-after-statement -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then<br>+if $(${CC} -Wdeclaration-after-statement -Werror -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then<br> AC_MSG_RESULT(yes)<br> AST_DECLARATION_AFTER_STATEMENT=-Wdeclaration-after-statement<br> else<br>@@ -1236,7 +1236,7 @@<br> AC_SUBST(AST_NO_STRICT_OVERFLOW)<br> <br> AC_MSG_CHECKING(for -Wno-format-truncation)<br>-if $(${CC} -O2 -Wno-format-truncation -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then<br>+if $(${CC} -Wno-format-truncation -Werror -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then<br> AC_MSG_RESULT(yes)<br> AST_NO_FORMAT_TRUNCATION=-Wno-format-truncation<br> else<br>@@ -1246,7 +1246,7 @@<br> AC_SUBST(AST_NO_FORMAT_TRUNCATION)<br> <br> AC_MSG_CHECKING(for -Wshadow)<br>-if $(${CC} -Wshadow -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then<br>+if $(${CC} -Wshadow -Werror -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then<br> AC_MSG_RESULT(yes)<br> AST_SHADOW_WARNINGS=-Wshadow<br> else<br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/7860">change 7860</a>. To unsubscribe, visit <a href="https://gerrit.asterisk.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.asterisk.org/7860"/><meta itemprop="name" content="View Change"/></div></div>
<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 13 </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>
<div style="display:none"> Gerrit-Change-Id: Ia9b7747f649b27ff5e9f75c3db3fee4fe7a29621 </div>
<div style="display:none"> Gerrit-Change-Number: 7860 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Alexander Traud <pabstraud@compuserve.com> </div>