On Tue, 2 Aug 2016 06:29:53 +0300
eSyr <evgsyr(a)gmail.com> wrote:
Commit ef79e28 introduced usage of clock_gettime() function, which,
unfortunately, breaks build on some systems, namely Debian Wheezy, due
to the fact it should be linked with librt. This commit adds configure
check whether additional library is needed in order to use
aforementioned function.
* configure.ac: using AC_SEARCH_LIBS() for checking whether librt is
needed for clock_gettime().
---
configure.ac | 2 ++
1 file changed, 2 insertions(+)
diff --git a/configure.ac b/configure.ac
index 088d0de..7573d84 100644
--- a/configure.ac
+++ b/configure.ac
@@ -106,6 +106,8 @@ AC_CHECK_FUNCS([ \
strtoull \
])
+AC_SEARCH_LIBS([clock_gettime], [rt])
+
PKG_CHECK_MODULES([NCURSES], [ncursesw ncurses], [LIBS="$LIBS $ncurses_LIBS"],
[
AC_SEARCH_LIBS([delwin], [ncursesw ncurses], [], [
AC_MSG_ERROR([ncurses is required but was not found])
You have my Acked-by. Pushed, and thanks for your contribution!
commit 25558463a185e8c606bd0a341e18d0996ade5f4e
Author: eSyr <evgsyr(a)gmail.com>
AuthorDate: Tue Aug 2 06:29:53 2016 +0300
Commit: Joe Konno <joe.konno(a)intel.com>
CommitDate: Wed Aug 3 08:26:38 2016 -0700
Checking whether librt is needed for clock_gettime().
Commit ef79e28 introduced usage of clock_gettime() function, which,
unfortunately, breaks build on some systems, namely Debian Wheezy, due
to the fact it should be linked with librt. This commit adds configure
check whether additional library is needed in order to use
aforementioned function.
* configure.ac: using AC_SEARCH_LIBS() for checking whether librt is
needed for clock_gettime().
Acked-by: Joe Konno <joe.konno(a)intel.com>