On 5 Jun 2008, Jeff Dike uttered the following:

> On Thu, Jun 05, 2008 at 07:14:30PM +0100, Nix wrote:
>> It comes with glibc, and even ls uses it (for clock_gettime(), to
>> determine what format to use for date display).
>> 
>> I'd say using it is about as safe as can be.
>
> Without adding -lrt to the link line here (F7), I get

Yes, you'll definitely *need* -lrt for clock_*().

> arch/um/os-Linux/built-in.o: In function `nsecs':
> /home/jdike/linux/2.6/linux-2.6.22/arch/um/os-Linux/time.c:84: undefined 
> reference to `clock_gettime'
> collect2: ld returned 1 exit status
>
> A little odd for a system call...

I think it's in there because it's part of the POSIX realtime
extensions, so you should have to, as it were, assent to using something
that's not as portable as just using libc. It makes more sense than
libm, anyway.

(It's completely moot for UML of course :) )

-- 
`If you are having a "ua luea luea le ua le" kind of day, I can only
 assume that you are doing no work due [to] incapacitating nausea caused 
 by numerous lazy demons.' --- Frossie

-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
User-mode-linux-devel mailing list
User-mode-linux-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel

Reply via email to