[uClinux-dev] usleep in uClibc/uClinux

Drasko DRASKOVIC drasko.draskovic at gmail.com
Tue Mar 8 22:59:48 UTC 2011


On Tue, Mar 8, 2011 at 7:13 PM, Mike Frysinger <vapier at gentoo.org> wrote:
>> So, usleep() is defined only if __USE_BSD.
>
> you ignored a pretty large part of the code:
>> #if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
>
> BSD *or* the xopen extended spec
>
>> 1) Why so ?
>>
>> 2) What if I do not use BSD system, but uClinux ?
>
> that isnt what it means.  please read the feature_test_macros man page.
> -mike

Thanks Mike.

I still do not get who is to define __USE_XOPEN_EXTENDED macro ?
My compiler does not do it, neider my uClinux Makefile.

Would that say that I have to define it explicitly by changing uClinux
Makefile and passing the defines to copiler line options ?
Similar when I compile apps, I always have to explicitly add -D_XOPEN_SOURCE ?

BR,
Drasko


More information about the uClibc mailing list