From e6dab3d7c429a2d30d31f188c4554e870011e051 Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Fri, 30 Dec 2005 12:05:47 +0000 Subject: [PATCH] Fix the AC_TRY_RUN for sys/linker.h which had no hope due to lacking a main() to instead use a nice AC_CHECK_HEADERS that works. Also, fix the nearby SYSV IPC check which was lacking an argument and giving bogus results (it's "AC_TRY_LINK(includes, main, yes, no)"). --- ChangeLog | 8 ++++++++ configure.ac | 11 ++++------- 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/ChangeLog b/ChangeLog index 4c9806830..12e39210f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2005-12-30 Eric Anholt + + * configure.ac: + Fix the AC_TRY_RUN for sys/linker.h which had no hope due to lacking a + main() to instead use a nice AC_CHECK_HEADERS that works. Also, fix + the nearby SYSV IPC check which was lacking an argument and giving + bogus results (it's "AC_TRY_LINK(includes, main, yes, no)"). + 2005-12-29 Eric Anholt * include/dix-config.h.in: diff --git a/configure.ac b/configure.ac index 74fd41a86..babba40fe 100644 --- a/configure.ac +++ b/configure.ac @@ -132,20 +132,17 @@ if test "x$ac_cv_mtrr_h" = xyes; then fi dnl FreeBSD kldload support (sys/linker.h) -AC_CACHE_CHECK([for sys/linker.h], - ac_cv_sys_linker_h, - [AC_TRY_RUN([ -#include -#include -], +AC_CHECK_HEADERS([sys/linker.h], [ac_cv_sys_linker_h=yes], - [ac_cv_sys_linker_h=no])]) + [ac_cv_sys_linker_h=no], + [#include ]) AM_CONDITIONAL(FREEBSD_KLDLOAD, [test "x$ac_cv_sys_linker_h" = xyes]) AC_CACHE_CHECK([for SYSV IPC], ac_cv_sysv_ipc, [AC_TRY_LINK([ #include +],[ int main () { int id; id = shmget(IPC_PRIVATE, 512, SHM_W | SHM_R);