linux is defined for linux kernel.
gnu_linux is defined for linux os.
linux will be present in android also making SANITIZER_LINUX true for android.
So, I suggest we use gnu_linux instead of linux.
Differential D17880
[Compiler-rt] Use __gnu_linux__ instead of __linux__ to detect Linux OS mohit.bhakkad on Mar 4 2016, 2:26 AM. Authored by
Details
linux is defined for linux kernel. linux will be present in android also making SANITIZER_LINUX true for android.
Diff Detail
Event TimelineComment Actions
Isn't this intended? In (few) places where libsanitizer needs to distinguish between Linux and Android it explicitly checks for #if (SANITIZER_LINUX && !SANITIZER_ANDROID) |