From: Richard Levitte Date: Mon, 9 Mar 2009 18:20:41 +0000 (+0000) Subject: Check that yubikey-core/ykcore.h declares yk_usb_strerror X-Git-Tag: yubikey-personalisation_1.3.5-1~4^2~187 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cacb4a6da6d84187b59fcfd9f9c8d33d37e44957;p=yubikey-personalization.old Check that yubikey-core/ykcore.h declares yk_usb_strerror --- diff --git a/configure.ac b/configure.ac index 081388b..8aa3ec9 100644 --- a/configure.ac +++ b/configure.ac @@ -44,7 +44,7 @@ AC_LIBTOOL_WIN32_DLL AC_PROG_LIBTOOL # This really checks a directory -AC_CHECK_FILE(yubikey-core/configure.ac,,AC_MSG_FAILURE(yubikey-core directory not found. +AC_CHECK_FILES([yubikey-core/configure.ac yubikey-core/ykcore.h],,AC_MSG_FAILURE(yubikey-core directory not found. ************************************ Please provide by checking out http://yubikey-core.googlecode.com/svn/trunk @@ -53,6 +53,15 @@ with svn and creating a symbolic link `yubikey-core' to that checkout )) #AC_SEARCH_LIBS([yubikey_parse],[yubikey],,AC_MSG_FAILURE(libyubikey not found)) +# Check that the yubikey-core we try to use is modern enough +AC_MSG_CHECKING(if yubikey-core/ykcore.h declares yk_usb_strerror) +AC_EGREP_CPP([yk_usb_strerror], + [#include "yubikey-core/ykcore.h"], + AC_MSG_RESULT(yes), + AC_MSG_RESULT(no) + AC_MSG_FAILURE(yubikey-core/ykcore.h does not declare yk_usb_strerror. +You probably need to update yubikey-core)) + if test "$with_usb" != "yes"; then if test "$with_usb" != ""; then CFLAGS="$CFLAGS -I$with_usb/include"