All of lore.kernel.org
 help / color / mirror / Atom feed
* [Powertop] [PATCH] Checking whether librt is needed for clock_gettime().
@ 2016-08-02  3:29 eSyr
  0 siblings, 0 replies; 2+ messages in thread
From: eSyr @ 2016-08-02  3:29 UTC (permalink / raw)
  To: powertop

[-- Attachment #1: Type: text/plain, Size: 898 bytes --]

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])
-- 
1.7.10.4


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [Powertop] [PATCH] Checking whether librt is needed for clock_gettime().
@ 2016-08-03 15:31 Joe Konno
  0 siblings, 0 replies; 2+ messages in thread
From: Joe Konno @ 2016-08-03 15:31 UTC (permalink / raw)
  To: powertop

[-- Attachment #1: Type: text/plain, Size: 1848 bytes --]

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>

[-- Attachment #2: attachment.sig --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-08-03 15:31 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-02  3:29 [Powertop] [PATCH] Checking whether librt is needed for clock_gettime() eSyr
2016-08-03 15:31 Joe Konno

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.