Skip to content

Commit 2410cb6

Browse files
committed
Switch to AC_CHECK_DECL
1 parent cc5d3e3 commit 2410cb6

File tree

2 files changed

+138
-168
lines changed

2 files changed

+138
-168
lines changed

configure

Lines changed: 132 additions & 154 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

configure.ac

Lines changed: 6 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3022,22 +3022,14 @@ AC_HEADER_DIRENT
30223022
AC_HEADER_MAJOR
30233023

30243024
# On Linux, stropts.h may be empty
3025-
AC_MSG_CHECKING([for stropts.h])
3026-
AC_COMPILE_IFELSE([
3027-
AC_LANG_PROGRAM([[
3025+
AC_CHECK_DECL([I_PUSH], [
3026+
AC_DEFINE([HAVE_STROPTS_H], [1], [Define to 1 if you have the <stropts.h> header file.])
3027+
], [], [
3028+
#ifdef HAVE_SYS_TYPES_H
30283029
#include <sys/types.h>
3029-
#include <stropts.h>
3030-
]], [[
3031-
#if !defined(I_PUSH)
3032-
#error I_PUSH
30333030
#endif
3034-
]]
3035-
)],
3036-
[
3037-
AC_MSG_RESULT([yes])
3038-
AC_DEFINE([HAVE_STROPTS_H], [1], [Define to 1 if you have the <stropts.h> header file.])
3039-
],
3040-
[AC_MSG_RESULT([no])])
3031+
#include <stropts.h>
3032+
])
30413033

30423034
# bluetooth/bluetooth.h has been known to not compile with -std=c99.
30433035
# http://permalink.gmane.org/gmane.linux.bluez.kernel/22294

0 commit comments

Comments
 (0)