All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] syslog-ng: Link against librt
@ 2015-10-26  0:02 Chris Packham
  2015-10-26  3:54 ` Thomas Petazzoni
  2015-10-26  5:14 ` Thomas Petazzoni
  0 siblings, 2 replies; 6+ messages in thread
From: Chris Packham @ 2015-10-26  0:02 UTC (permalink / raw)
  To: buildroot

Some of the rabbit-mq tools need to link against librt, specify
LIBS=-lrt when configuring.

Fixes:
http://autobuild.buildroot.net/results/a3d/a3dfdebd76d47df11a8e26a215bb88fbce8dc6f7
http://autobuild.buildroot.net/results/7d2/7d26e8efe67bf958162a309acb20800e669543e4
http://autobuild.buildroot.net/results/7b5/7b5370d12a2ff8937cba3a201d4edce3dcd12a6e
http://autobuild.buildroot.net/results/bab/babbb089ce1a7750495323248f21402960fb6c80

Helped-by: Waldemar Brodkorb <wbx@openadk.org>
Signed-off-by: Chris Packham <judge.packham@gmail.com>
---
 package/syslog-ng/syslog-ng.mk | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/package/syslog-ng/syslog-ng.mk b/package/syslog-ng/syslog-ng.mk
index 1ade7cf..3441751 100644
--- a/package/syslog-ng/syslog-ng.mk
+++ b/package/syslog-ng/syslog-ng.mk
@@ -11,6 +11,8 @@ SYSLOG_NG_LICENSE = LGPLv2.1+ (syslog-ng core), GPLv2+ (modules)
 SYSLOG_NG_LICENSE_FILES = COPYING
 SYSLOG_NG_DEPENDENCIES = host-bison host-flex host-pkgconf \
 	eventlog libglib2 openssl pcre
+# rabbit-mq needs -lrt
+SYSLOG_NG_CONF_ENV = LIBS=-lrt
 SYSLOG_NG_CONF_OPTS = --disable-manpages
 SYSLOG_NG_PATCH = \
 	https://github.com/dnsjts/syslog-ng/commit/7b2b673ae2640ce9ad396f538fc25acb6e4405ec.patch \
-- 
2.5.3

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

* [Buildroot] [PATCH] syslog-ng: Link against librt
  2015-10-26  0:02 [Buildroot] [PATCH] syslog-ng: Link against librt Chris Packham
@ 2015-10-26  3:54 ` Thomas Petazzoni
  2015-10-26  6:53   ` Chris Packham
  2015-10-26  5:14 ` Thomas Petazzoni
  1 sibling, 1 reply; 6+ messages in thread
From: Thomas Petazzoni @ 2015-10-26  3:54 UTC (permalink / raw)
  To: buildroot

Dear Chris Packham,

On Mon, 26 Oct 2015 13:02:13 +1300, Chris Packham wrote:

> +# rabbit-mq needs -lrt
> +SYSLOG_NG_CONF_ENV = LIBS=-lrt

While this works, I believe a better solution is to fix the
configure.ac. It already checks if nanosleep is in librt, and if so,
links against librt.

It should the same for those functions, if the rabbitmq support is
enabled.

Thanks!

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

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

* [Buildroot] [PATCH] syslog-ng: Link against librt
  2015-10-26  0:02 [Buildroot] [PATCH] syslog-ng: Link against librt Chris Packham
  2015-10-26  3:54 ` Thomas Petazzoni
@ 2015-10-26  5:14 ` Thomas Petazzoni
  1 sibling, 0 replies; 6+ messages in thread
From: Thomas Petazzoni @ 2015-10-26  5:14 UTC (permalink / raw)
  To: buildroot

Dear Chris Packham,

On Mon, 26 Oct 2015 13:02:13 +1300, Chris Packham wrote:
> Some of the rabbit-mq tools need to link against librt, specify
> LIBS=-lrt when configuring.
> 
> Fixes:
> http://autobuild.buildroot.net/results/a3d/a3dfdebd76d47df11a8e26a215bb88fbce8dc6f7
> http://autobuild.buildroot.net/results/7d2/7d26e8efe67bf958162a309acb20800e669543e4
> http://autobuild.buildroot.net/results/7b5/7b5370d12a2ff8937cba3a201d4edce3dcd12a6e
> http://autobuild.buildroot.net/results/bab/babbb089ce1a7750495323248f21402960fb6c80
> 
> Helped-by: Waldemar Brodkorb <wbx@openadk.org>
> Signed-off-by: Chris Packham <judge.packham@gmail.com>
> ---
>  package/syslog-ng/syslog-ng.mk | 2 ++
>  1 file changed, 2 insertions(+)

Applied, thanks. I still think a better fix would be to change
configure.ac, and submit the change upstream.

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

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

* [Buildroot] [PATCH] syslog-ng: Link against librt
  2015-10-26  3:54 ` Thomas Petazzoni
@ 2015-10-26  6:53   ` Chris Packham
  2015-10-26  7:08     ` Chris Packham
  0 siblings, 1 reply; 6+ messages in thread
From: Chris Packham @ 2015-10-26  6:53 UTC (permalink / raw)
  To: buildroot

Hi Thomas,

On Mon, Oct 26, 2015 at 4:54 PM, Thomas Petazzoni
<thomas.petazzoni@free-electrons.com> wrote:
> Dear Chris Packham,
>
> On Mon, 26 Oct 2015 13:02:13 +1300, Chris Packham wrote:
>
>> +# rabbit-mq needs -lrt
>> +SYSLOG_NG_CONF_ENV = LIBS=-lrt
>
> While this works, I believe a better solution is to fix the
> configure.ac. It already checks if nanosleep is in librt, and if so,
> links against librt.
>
> It should the same for those functions, if the rabbitmq support is
> enabled.

Hmm. Syslog-ng distributes rabbitmq-c as a sub package. The looking at
included rabbitmq-c sources and the upstream package[1] it is checking
for clock_gettime which it thinks it should find in librt. But looking
at the config.log[2] for rabbitmq-c it has decided that no library is
required. Is there something unexpected about clock_gettime with
uclibc?

[1] - https://github.com/alanxz/rabbitmq-c/blob/master/configure.ac#L104
[2] - http://autobuild.buildroot.net/results/a3d/a3dfdebd76d47df11a8e26a215bb88fbce8dc6f7/syslog-ng-3.7.1/modules/afamqp/rabbitmq-c/config.log


>
> Thanks!
>
> Thomas
> --
> Thomas Petazzoni, CTO, Free Electrons
> Embedded Linux, Kernel and Android engineering
> http://free-electrons.com

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

* [Buildroot] [PATCH] syslog-ng: Link against librt
  2015-10-26  6:53   ` Chris Packham
@ 2015-10-26  7:08     ` Chris Packham
  2015-10-26 20:08       ` Chris Packham
  0 siblings, 1 reply; 6+ messages in thread
From: Chris Packham @ 2015-10-26  7:08 UTC (permalink / raw)
  To: buildroot

On Mon, Oct 26, 2015 at 7:53 PM, Chris Packham <judge.packham@gmail.com> wrote:
> Hi Thomas,
>
> On Mon, Oct 26, 2015 at 4:54 PM, Thomas Petazzoni
> <thomas.petazzoni@free-electrons.com> wrote:
>> Dear Chris Packham,
>>
>> On Mon, 26 Oct 2015 13:02:13 +1300, Chris Packham wrote:
>>
>>> +# rabbit-mq needs -lrt
>>> +SYSLOG_NG_CONF_ENV = LIBS=-lrt
>>
>> While this works, I believe a better solution is to fix the
>> configure.ac. It already checks if nanosleep is in librt, and if so,
>> links against librt.
>>
>> It should the same for those functions, if the rabbitmq support is
>> enabled.
>
> Hmm. Syslog-ng distributes rabbitmq-c as a sub package. The looking at
> included rabbitmq-c sources and the upstream package[1] it is checking
> for clock_gettime which it thinks it should find in librt. But looking
> at the config.log[2] for rabbitmq-c it has decided that no library is
> required. Is there something unexpected about clock_gettime with
> uclibc?
>
> [1] - https://github.com/alanxz/rabbitmq-c/blob/master/configure.ac#L104
> [2] - http://autobuild.buildroot.net/results/a3d/a3dfdebd76d47df11a8e26a215bb88fbce8dc6f7/syslog-ng-3.7.1/modules/afamqp/rabbitmq-c/config.log
>

Digging a bit deeper it looks like clock_gettime is in both libc and
librt. According to the (glibc) man page -lrt was needed prior to
glibc 2.17 so I'm guessing this is some kind of backwards
compatibility check that would happen to satisfy the posix_spawn
requirements. I'll see about an upstream patch to rabbitmq-c.

>>
>> Thanks!
>>
>> Thomas
>> --
>> Thomas Petazzoni, CTO, Free Electrons
>> Embedded Linux, Kernel and Android engineering
>> http://free-electrons.com

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

* [Buildroot] [PATCH] syslog-ng: Link against librt
  2015-10-26  7:08     ` Chris Packham
@ 2015-10-26 20:08       ` Chris Packham
  0 siblings, 0 replies; 6+ messages in thread
From: Chris Packham @ 2015-10-26 20:08 UTC (permalink / raw)
  To: buildroot

On Mon, Oct 26, 2015 at 8:08 PM, Chris Packham <judge.packham@gmail.com> wrote:
> On Mon, Oct 26, 2015 at 7:53 PM, Chris Packham <judge.packham@gmail.com> wrote:
>> Hi Thomas,
>>
>> On Mon, Oct 26, 2015 at 4:54 PM, Thomas Petazzoni
>> <thomas.petazzoni@free-electrons.com> wrote:
>>> Dear Chris Packham,
>>>
>>> On Mon, 26 Oct 2015 13:02:13 +1300, Chris Packham wrote:
>>>
>>>> +# rabbit-mq needs -lrt
>>>> +SYSLOG_NG_CONF_ENV = LIBS=-lrt
>>>
>>> While this works, I believe a better solution is to fix the
>>> configure.ac. It already checks if nanosleep is in librt, and if so,
>>> links against librt.
>>>
>>> It should the same for those functions, if the rabbitmq support is
>>> enabled.
>>
>> Hmm. Syslog-ng distributes rabbitmq-c as a sub package. The looking at
>> included rabbitmq-c sources and the upstream package[1] it is checking
>> for clock_gettime which it thinks it should find in librt. But looking
>> at the config.log[2] for rabbitmq-c it has decided that no library is
>> required. Is there something unexpected about clock_gettime with
>> uclibc?
>>
>> [1] - https://github.com/alanxz/rabbitmq-c/blob/master/configure.ac#L104
>> [2] - http://autobuild.buildroot.net/results/a3d/a3dfdebd76d47df11a8e26a215bb88fbce8dc6f7/syslog-ng-3.7.1/modules/afamqp/rabbitmq-c/config.log
>>
>
> Digging a bit deeper it looks like clock_gettime is in both libc and
> librt. According to the (glibc) man page -lrt was needed prior to
> glibc 2.17 so I'm guessing this is some kind of backwards
> compatibility check that would happen to satisfy the posix_spawn
> requirements. I'll see about an upstream patch to rabbitmq-c.
>

And here's a link to the pull request
https://github.com/alanxz/rabbitmq-c/pull/322

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

end of thread, other threads:[~2015-10-26 20:08 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-10-26  0:02 [Buildroot] [PATCH] syslog-ng: Link against librt Chris Packham
2015-10-26  3:54 ` Thomas Petazzoni
2015-10-26  6:53   ` Chris Packham
2015-10-26  7:08     ` Chris Packham
2015-10-26 20:08       ` Chris Packham
2015-10-26  5:14 ` Thomas Petazzoni

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.