diff options
| author | Ivan Maidanski <ivmai@mail.ru> | 2016-11-22 04:48:41 +0300 |
|---|---|---|
| committer | Ivan Maidanski <ivmai@mail.ru> | 2016-11-22 04:48:41 +0300 |
| commit | 58ce63e1ff80cf0464d56c76818bef1b05407113 (patch) | |
| tree | 2b369a0064da795e254719e404ab802e50b8c402 /configure.ac | |
| parent | 96a8fd9b3b0ce90c6bed6cb94cd2904cb7a12d2c (diff) | |
| download | libatomic_ops-58ce63e1ff80cf0464d56c76818bef1b05407113.tar.gz | |
Fix GCC -Wpedantic checking in configure
(fix commit 96a8fd9)
* configure.ac [GCC] (ac_cv_cc_pedantic): Compile code that contains
"extern int quiet" (since the translation unit cannot be empty).
Diffstat (limited to 'configure.ac')
| -rw-r--r-- | configure.ac | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac index 055167a..796dccd 100644 --- a/configure.ac +++ b/configure.ac @@ -57,7 +57,9 @@ if test "$GCC" = yes; then AS_IF([test "$ac_cv_cc_wextra" = yes], [WEXTRA="-Wextra"], [WEXTRA="-W"]) AC_MSG_CHECKING(for gcc -Wpedantic) CFLAGS="-Wpedantic -Wno-long-long $CFLAGS" - AC_TRY_COMPILE([],[], [ac_cv_cc_pedantic=yes], [ac_cv_cc_pedantic=no]) + AC_TRY_COMPILE([],[ +extern int quiet; + ], [ac_cv_cc_pedantic=yes], [ac_cv_cc_pedantic=no]) CFLAGS="$old_CFLAGS" AC_MSG_RESULT($ac_cv_cc_pedantic) WPEDANTIC= |
