[yocto] How to use PREEMPT-RT Header in Yocto

Baumann, Michael Michael.Baumann at vector.com
Mon Dec 7 06:57:48 PST 2015


Hello everbody,

I am trying to use the PREEMPT-RT patch, therefore I bitbake an image with the linux-yocto-rt 4.1.8 kernel. 
The linux-yocto-rt kernel is built and runs in qemux86. 
Now I try to build an application which uses the sched_setattr to set scheduling policy SCHED_DEADLINE from <sched.h>. 
My Bitbake fails to build this application because of wrong header files e.g. 

error: storage size of 'scheduling_attribut' isn't known
    struct sched_attr scheduling_attribut;
and
warning: implicit declaration of function 'sched_setattr'

in my created SDK (bitbake <image> -c populate_sdk) I have this /usr/include/sched.h file:  http://pastebin.com/gaXejv6j
I would have expect to find this file http://git.yoctoproject.org/cgit/cgit.cgi/linux-yocto-4.1/tree/include/linux/sched.h

How do I use the correct header files from PREEMPT-RT patch in my yocto build environment?

Regards,
Michael



More information about the yocto mailing list