* [Xenomai-help] [ask] error undefined reference while trying to compile
@ 2011-02-22 19:18 Ramon Rusli
2011-02-22 19:31 ` Gilles Chanteperdrix
0 siblings, 1 reply; 3+ messages in thread
From: Ramon Rusli @ 2011-02-22 19:18 UTC (permalink / raw)
To: xenomai; +Cc: Ramon Rusli
[-- Attachment #1: Type: text/plain, Size: 1327 bytes --]
Dear,
I am using gcc to compile and make executable file with xenomai, but it getting error, so I want to ask how to get it compiled. I am using the code that I got from http://www.cs.ru.nl/lab/xenomai/exercises/ex01/Exercise-1.html
I am using the hello world example, and I write it in the file named helloworldRT.c
this is how I make it compiled
[root@domain.hid Desktop]# gcc -c -I /usr/xenomai/include/ helloworldRT.c
<it seems works>
[root@domain.hid Desktop]# gcc -o helloworldrt helloworldRT.o
helloworldRT.o: In function `demo':
helloworldRT.c:(.text+0xe): undefined reference to `rt_printf'
helloworldRT.c:(.text+0x13): undefined reference to `rt_task_self'
helloworldRT.c:(.text+0x28): undefined reference to `rt_task_inquire'
helloworldRT.c:(.text+0x3e): undefined reference to `rt_printf'
helloworldRT.o: In function `main':
helloworldRT.c:(.text+0x55): undefined reference to `rt_print_auto_init'
helloworldRT.c:(.text+0x6d): undefined reference to `rt_printf'
helloworldRT.c:(.text+0xb6): undefined reference to `rt_task_create'
helloworldRT.c:(.text+0xd2): undefined reference to `rt_task_start'
collect2: ld returned 1 exit status
<this is the error I got>
can somebody tell me how to compile it well? it seems I miss something in the way I compile. Can somebody tell me the right command?
Thanks
[-- Attachment #2: Type: text/html, Size: 1534 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread[parent not found: <497156.82404.qm@domain.hid>]
end of thread, other threads:[~2011-02-22 19:36 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-02-22 19:18 [Xenomai-help] [ask] error undefined reference while trying to compile Ramon Rusli
2011-02-22 19:31 ` Gilles Chanteperdrix
[not found] <497156.82404.qm@domain.hid>
2011-02-22 19:36 ` Gilles Chanteperdrix
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.