Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [mosquitto-dev] why is librt needed?

Hi Greg,

I've looked through everything and can't find anything else - I think
Frank nailed it on the head that it was clock_gettime(). I'll remove
the references.

Regards,

Roger

On Tue, 22 Jul 2025 at 23:23, Greg Troxel via mosquitto-dev
<mosquitto-dev@xxxxxxxxxxx> wrote:
>
> Frank Pagliughi <fpagliughi@xxxxxxxxxxxxxx> writes:
>
> > Apologies for the delay on the follow-up. Ran out of town for a few days...
>
> absolutely fine!  many others have the same sorts of feelings.
>
> >> Thanks.  So you are saying that the only thing mosquitto needs that
> >> might be related to "POSIX realtime" is clock_gettime and friends.
> >
> > I didn't do an extensive search, but did a quick grep of the mosquitto
> > sources for some arcane stuff, like POSIX message queues (mq_*) and
> > semaphores, came up empty.  But clock_gettime() was in there.
> >
> > On my Linux distro (Mint 22) the /librt.a /archive is just an empty
> > stub of a library. There's nothing in it. I assume they left it in
> > there to appease all the build systems that still include it.
>
> I think we've arrived at
>
>   there is no longer any reason to include -lrt on any platform
>
>   having code to add it just adds chaos, and therefore we should remove
>   it
>
>   if there's some specific platform that turns out to need it, we
>   can add it *just for that platform* so we keep the general case
>   leaner.
>
>
> Does anybody disagree?
> _______________________________________________
> mosquitto-dev mailing list
> mosquitto-dev@xxxxxxxxxxx
> To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/mosquitto-dev


Back to the top