remove double code (ALL HAIL CVS), and check lockdev before ttylock (new AC_CHECK_HEADER semantics since autoconf 2.56)
git-svn-id: https://svn.code.sf.net/p/gphoto/code/trunk/libgphoto2@7979 67ed7778-7388-44ab-90cf-0a291f65f57c
This commit is contained in:
@@ -128,16 +128,6 @@ AC_CHECK_HEADERS(stdlib.h unistd.h stdio.h fcntl.h errno.h sys/time.h \
|
||||
fcntl.h sgtty.h sys/ioctl.h sys/time.h termio.h unistd.h \
|
||||
endian.h byteswap.h asm/io.h)
|
||||
|
||||
dnl FIXME: Provide regex.h with the corresponding object code for
|
||||
dnl platforms which do not have it.
|
||||
AC_CHECK_HEADER([regex.h],
|
||||
[AC_DEFINE([HAVE_REGEX],1,[whether we have regex.h])],
|
||||
[AC_MSG_ERROR([
|
||||
*** We need regex.h and its object code to compile
|
||||
*** But we could not find it.
|
||||
])
|
||||
])
|
||||
|
||||
dnl FIXME: Provide regex.h with the corresponding object code for
|
||||
dnl platforms which do not have it, e.g. Windows.
|
||||
AC_CHECK_HEADER([regex.h],
|
||||
@@ -245,7 +235,8 @@ GP_CONFIG_MSG([baudboy locking],[${baudboy_msg}])
|
||||
|
||||
ttylock_msg=no
|
||||
if $try_ttylock; then
|
||||
AC_CHECK_HEADER(ttylock.h,[
|
||||
AC_CHECK_HEADER([lockdev.h])
|
||||
AC_CHECK_HEADER([ttylock.h],[
|
||||
lockdev_result="no"
|
||||
AC_TRY_LINK([#include <ttylock.h>],[ttylocked ("/dev/foo");],[
|
||||
lockdev_result="no"
|
||||
@@ -263,6 +254,9 @@ if $try_ttylock; then
|
||||
])
|
||||
AC_MSG_CHECKING([if ttylock needs lockdev])
|
||||
AC_MSG_RESULT([${lockdev_result}])
|
||||
],[],[#ifdef HAVE_LOCKDEV_H
|
||||
# include <lockdev.h>
|
||||
#endif
|
||||
])
|
||||
fi
|
||||
GP_CONFIG_MSG([ttylock locking],[${ttylock_msg}])
|
||||
|
||||
Reference in New Issue
Block a user