From: Wolfgang Grandegger <wg@domain.hid>
To: Everett Wang <everteq@domain.hid>
Cc: xenomai@xenomai.org, Bruno Rouchouse <brouchouse@domain.hid>
Subject: Re: [Xenomai-help] application make file
Date: Sat, 19 Jun 2010 11:02:14 +0200 [thread overview]
Message-ID: <4C1C8796.1050900@domain.hid> (raw)
In-Reply-To: <AANLkTim91ABqsvWb_GqMhOwnDlIQNfz1qoE-ABWc3KGE@mail.gmail.com>
On 06/19/2010 09:34 AM, Everett Wang wrote:
> On Fri, Jun 18, 2010 at 7:40 PM, Bruno Rouchouse <brouchouse@domain.hid> wrote:
>> Hi,
>> if you haven't found it yet and if I understood correctly your question,
>> xeno-config is probably what you need here ;)
>> "xeno-config
>> is a script that is used to to display the compiler and linker flags that are required for building applications that use Xenomai."
>> Regards,
>> --Bruno
>> Le 17 juin 2010 à 17:39, Everett Wang a écrit :
>>
>> On Thu, Jun 17, 2010 at 7:16 PM, Gilles Chanteperdrix
>> <gilles.chanteperdrix@xenomai.org> wrote:
>>
>> Gilles Chanteperdrix wrote:
>>
>> Everett Wang wrote:
>>
>> Hi All,
>>
>> Now my application based user space xenomai has a few files and I want
>>
>> to construct a Makefile to compile them. I looked at the
>>
>> Makefiles in examples folder. It is not straight forward to modify one
>>
>> for myself. I have c files and header files. It is possible to get
>>
>> a makefile with minor changes so it can automatically find the
>>
>> dependence of c and h files?
>>
>> You can do this quite easily with GNU make.
>>
>> Namely:
>>
>> http://www.gnu.org/software/make/manual/html_node/Automatic-Prerequisites.html#Automatic-Prerequisites
>>
>> --
>>
>> Gilles.
>>
>>
>> Thanks Gilles,
>>
>> I can construct a Makefile for a non realtime application
>> with multiple files. What I don't know are the extra flags
>> for compiling and linking that xenomai requires. My
>> thinking is that after I have a normal (non xenomai) Makefile,
>> I can just add the compile flags when I compile each of the files
>> and add linking flags to produce a real time final program.
>>
>> Everett
>>
>> _______________________________________________
>> Xenomai-help mailing list
>> Xenomai-help@domain.hid
>> https://mail.gna.org/listinfo/xenomai-help
>>
>>
>
> Thanks for the help. I touched cross-link.c then a "make -n" to find out the
> xenomai flags. I added these flags to my normal make file. It compiles
> and runs fine now.
>
> compiler flags:
> CFLAGS_XENO = -I/usr/xenomai/include -D_GNU_SOURCE -D_REENTRANT -Wall
> -pipe -D__XENO__
>
> linker flags:
> LDFLAGS_XENO = -L/usr/xenomai/lib -lxenomai -lpthread -lnative -lrtdm
> -Xlinker -rpath -Xlinker /usr/xenomai/lib
>
> Hopefully it can be useful for new xenomai users.
You should use *xeno-config* in your Makefile to get the proper compiler
and linker flags.
Wolfgang,
next prev parent reply other threads:[~2010-06-19 9:02 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-06-17 8:28 [Xenomai-help] application make file Everett Wang
2010-06-17 9:40 ` Gilles Chanteperdrix
2010-06-17 11:16 ` Gilles Chanteperdrix
2010-06-17 15:39 ` Everett Wang
2010-06-17 15:46 ` Gilles Chanteperdrix
[not found] ` <C159A093-EA69-4903-8114-145C4355A0C0@domain.hid>
2010-06-19 7:34 ` Everett Wang
2010-06-19 9:02 ` Wolfgang Grandegger [this message]
2010-06-19 9:43 ` Gilles Chanteperdrix
[not found] ` <2DD1EFE4-AE92-4F78-9BAF-7441D7D0DB3E@gmail.com>
2010-06-19 10:45 ` Gilles Chanteperdrix
2010-06-19 16:05 ` Piquesel
2010-06-19 18:14 ` Gilles Chanteperdrix
2010-06-19 11:02 ` Gilles Chanteperdrix
2010-06-19 15:00 ` Everett Wang
2010-06-19 18:08 ` Gilles Chanteperdrix
2010-06-19 15:55 ` Piquesel
2010-06-19 18:20 ` Gilles Chanteperdrix
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4C1C8796.1050900@domain.hid \
--to=wg@domain.hid \
--cc=brouchouse@domain.hid \
--cc=everteq@domain.hid \
--cc=xenomai@xenomai.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.