third_party/tensorflow/core: Use macro __linux__ instead of __linux
Some Linux gcc installations, with some flags, do not set __linux,
but all tested so far seem to set __linux__.
An example if gcc on linux on ppc64. If the compiler is invoked with a flag
the defines a particular standard (such as -std=c++11 or -std=c++0x or -std=c89
or -std=c99) then "linux" and "__linux" are not defined. The macro "__linux__"
is always set regardless of these options.
This led to Linux-specific implementations of certain things being avoided on
ppc64.
The web page
https://sourceforge.net/p/predef/wiki/OperatingSystems/
says that the macros
linux __linux
are obsoltete and __linux__ is preferred, though it's unclear how definititve
that page is.
Change: 130152575
Loading
Please sign in to comment