This is the mail archive of the newlib@sourceware.org mailing list for the newlib project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: About endianess defination


daniel tian wrote:

> The problem is I don't know where the macro __RICE__ should be defined. I
> checked the CRX processor, and I don't find where it defined.

  It should be a default predefine in the compiler; adding -D options to
CPP_SPEC is the usual way to define these macros that identify OS, CPU, etc.;
for example here's how the cygwin compiler does it - note how it uses specs to
set different build environment #defines based on command-line switches.

> #undef CPP_SPEC
> #define CPP_SPEC "%(cpp_cpu) %{posix:-D_POSIX_SOURCE} \
>   %{mno-win32:%{mno-cygwin: %emno-cygwin and mno-win32 are not compatible}} \
>   %{mno-cygwin:-D__MSVCRT__ -D__MINGW32__ %{!ansi:%{mthreads:-D_MT}}}\
>   %{!mno-cygwin:-D__CYGWIN32__ -D__CYGWIN__ %{!ansi:-Dunix} -D__unix__ -D__unix }\
>   %{mwin32|mno-cygwin:-DWIN32 -D_WIN32 -D__WIN32 -D__WIN32__ %{!ansi:-DWINNT}}\
>   %{!nostdinc:%{!mno-win32|mno-cygwin:-idirafter ../include/w32api%s -idirafter ../../include/w32api%s}}\
> "

    cheers,
      DaveK


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]