[sheepdog] [PATCH] configure.ac: fix building failed in jenkins

Liu Yuan namei.unix at gmail.com
Fri Jul 18 08:48:58 CEST 2014


On Fri, Jul 18, 2014 at 11:41:07AM +0800, Ruoyu wrote:
> Because clock_gettime was introduced, we should check it first.
> Otherwise, compilation may be failed in some Linux distribution.
> 
> Signed-off-by: Ruoyu <liangry at ucweb.com>
> ---
>  configure.ac | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/configure.ac b/configure.ac
> index 7e6691f..6a9e552 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -88,6 +88,7 @@ AM_MISSING_PROG(AUTOM4TE, autom4te, $missing_dir)
>  
>  # Checks for libraries.
>  AC_CHECK_LIB([socket], [socket])
> +AC_CHECK_LIB([rt], [clock_gettime], , AC_MSG_ERROR(librt not found))
>  
>  # Checks for header files.
>  AC_FUNC_ALLOCA
> @@ -334,8 +335,6 @@ if test "x${enable_trace}" = xyes; then
>  		AC_MSG_ERROR(requires binutils-dev))
>  	AC_CHECK_HEADERS([bfd.h],,
>  		AC_MSG_ERROR(requires binutils-dev))
> -	AC_CHECK_LIB([rt], [clock_gettime],,
> -		AC_MSG_ERROR(librt not found))
>  	AC_DEFINE_UNQUOTED([HAVE_TRACE], 1, [have trace])
>  	PACKAGE_FEATURES="$PACKAGE_FEATURES trace"
>  fi
> -- 

Applied thanks

Yuan



More information about the sheepdog mailing list