summaryrefslogtreecommitdiff
path: root/security/libfprint/patches/patch-aa
blob: 7a96cacfec80c4d76b79f4cd092627edf4a8f5ae (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
$NetBSD: patch-aa,v 1.1 2009/05/10 18:25:34 hasso Exp $

--- configure.ac.orig	2009-05-10 19:25:36 +0300
+++ configure.ac	2009-05-10 19:36:05 +0300
@@ -89,9 +89,15 @@ if test "x$debug_log_enabled" != "xno"; 
 	AC_DEFINE([ENABLE_DEBUG_LOGGING], 1, [Debug message logging])
 fi
 
+# Restore gnu89 inline semantics on gcc 4.3 and newer
+saved_cflags="$CFLAGS"
+CFLAGS="$CFLAGS -fgnu89-inline"
+AC_COMPILE_IFELSE(AC_LANG_PROGRAM([]), inline_cflags="-fgnu89-inline", inline_cflags="")
+CFLAGS="$saved_cflags"
+
 
 AC_DEFINE([API_EXPORTED], [__attribute__((visibility("default")))], [Default visibility])
-AM_CFLAGS="-std=gnu99 -fgnu89-inline -Wall -Wundef -Wunused -Wstrict-prototypes -Werror-implicit-function-declaration -Wno-pointer-sign -Wshadow"
+AM_CFLAGS="-std=gnu99 $inline_cflags -Wall -Wundef -Wunused -Wstrict-prototypes -Werror-implicit-function-declaration -Wno-pointer-sign -Wshadow"
 AC_SUBST(AM_CFLAGS)
 
 AC_CONFIG_FILES([libfprint.pc] [Makefile] [libfprint/Makefile] [examples/Makefile] [doc/Makefile])