/ usr / include目录/ RTLinux的/未找到

时间:2019-02-02 18:28:17

标签: raspberry-pi2 rtos preempt-rt

按照本教程 https://lemariva.com/blog/2018/07/raspberry-pi-preempt-rt-patching-tutorial-for-kernel-4-14-y

,我终于在 raspberrypi 2B 上安装了 rtlinux
  

uname -r show 4.14.91-rt49-v7 +

但是当我尝试编译hello word程序时:

#include <rtl.h>
#include <time.h>
#include <pthread.h>

pthread_t thread;
void * start_routine(void *arg) {
    struct sched_param p;
    p.sched_priority = 1;
    pthread_setschedparam (pthread_self(), SCHED_FIFO, &p);
    pthread_make_periodic_np (pthread_self(), gethrtime(), 500000000);

    while (1) {
          pthread_wait_np();
          rtl_printf("I’m here; my arg is %x\n", (unsigned) arg);
    }
    return 0;
}

int init_module(void) {
    return pthread_create (&thread, NULL, start_routine, 0);
}

void cleanup_module(void) {
    pthread_cancel (thread);
    pthread_join (thread, NULL);
}

的问题是,我无法找到rtl.h和rtl.mk文件。 我看着在/ usr / include中/我没有找到RTLinux的文件夹

  

我已经从克隆了代码源   github和所使用的RPI-4.14.y-RT分支

0 个答案:

没有答案
相关问题