Re: Checking if code is compiled for Zephyr


Marcus Shawcroft <marcus.shawcroft@...>
 

On 7 March 2017 at 14:35, Paul Sokolovsky <paul.sokolovsky@...> wrote:
Hello,

I'm trying to #ifdef a part of cross-platform code for Zephyr, and I
didn't find a clear, self-describing way to do so. Am I missing
something? Can we have something like __ZEPHYR__, _ZEPHYR of whatever
preprocessor macro to check for?
The toplevel Makefile hardwires:

-D__ZEPHYR__=1

I don't know if that symbol is documented somewhere, but it would be
nice if it was.


Cheers
/Marcus

Join {devel@lists.zephyrproject.org to automatically receive all group messages.