This is the mail archive of the
ecos-discuss@sourceware.org
mailing list for the eCos project.
RE: How to tell if a file is being compiled as part of eC os?
- From: Jay Foster <jay at systech dot com>
- To: 'Grant Edwards' <grante at visi dot com>, ecos-discuss at sources dot redhat dot com
- Date: Thu, 31 Jul 2008 09:11:11 -0700
- Subject: RE: [ECOS] How to tell if a file is being compiled as part of eC os?
I've seen many eCos packages use "__ECOS" (or sometimes "__ECOS__") for this
purpose. __ECOS is usually defined by the associated package CDL file in a
...CFLAGS_ADD option. You can grep for __ECOS in the sources and find
examples.
Jay
-----Original Message-----
From: Grant Edwards [mailto:grante@visi.com]
Sent: Thursday, July 31, 2008 8:52 AM
To: ecos-discuss@sources.redhat.com
Subject: [ECOS] How to tell if a file is being compiled as part of eCos?
I have a file that contains portable code. Since eCos doesn't
support C99 features like stdint.h, the file needs to know if
it's being compiled as part of eCos or not.
I can't seem to find any pre-processor symbols that tell me the
file is being built as part of eCos (the way that __linux__
tells me a file is being built to run under linux).
Any ideas?
--
Grant Edwards grante Yow! My mind is making
at ashtrays in Dayton ...
visi.com
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss