[pkg-opensc-commit] [opensc] 18/23: autoconf: option to disable -Werror=declaration-after-statement

Eric Dorland eric at moszumanska.debian.org
Tue Jul 5 06:01:20 UTC 2016


This is an automated email from the git hooks/post-receive script.

eric pushed a commit to branch master
in repository opensc.

commit a2a17186c282d670a41da8cdf38ccf0fb1222a4e
Author: Viktor Tarasov <viktor.tarasov at gmail.com>
Date:   Fri Jun 3 11:06:14 2016 +0200

    autoconf: option to disable -Werror=declaration-after-statement
    
    old GCCs (distributed with RedHat 5) do not understand this option
---
 configure.ac | 12 +++++++++++-
 1 file changed, 11 insertions(+), 1 deletion(-)

diff --git a/configure.ac b/configure.ac
index 80f51cb..1ae5454 100644
--- a/configure.ac
+++ b/configure.ac
@@ -224,6 +224,13 @@ AC_ARG_ENABLE(
 	[enable_dnie_ui="no"]
 )
 
+AC_ARG_ENABLE(
+	[werror-declaration-after-statement],
+	[AS_HELP_STRING([--disable-werror-declaration-after-statement],[disable -Werror 'declaration-after-statement' @<:@enabled@:>@])],
+	,
+	[werror_declaration_after_statement="yes"]
+)
+
 AC_ARG_WITH(
 	[xsl-stylesheetsdir],
 	[AS_HELP_STRING([--with-xsl-stylesheetsdir=PATH],[docbook xsl-stylesheets for svn build @<:@detect@:>@])],
@@ -244,6 +251,7 @@ AC_ARG_WITH(
 	,
 	[with_pkcs11_provider="detect"]
 )
+
 dnl ./configure check
 reader_count=""
 for rdriver in "${enable_pcsc}" "${enable_openct}" "${enable_ctapi}"; do
@@ -775,7 +783,9 @@ if test "$GCC" = "yes"; then
 	CFLAGS="-fno-strict-aliasing ${CFLAGS}"
 fi
 
-CFLAGS="${CFLAGS} -Werror=declaration-after-statement"
+if test "${werror_declaration_after_statement}" = "yes"; then
+	CFLAGS="${CFLAGS} -Werror=declaration-after-statement"
+fi
 
 AC_CONFIG_FILES([
 	Makefile

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-opensc/opensc.git



More information about the pkg-opensc-commit mailing list