mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-08-21 18:29:46 +00:00
Put Darwin-specific code inside an __APPLE__ ifdef.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137137 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
c6fbe5636d
commit
0dc8b42987
@ -29,10 +29,12 @@ using namespace llvm;
|
||||
static std::string getOSVersion() {
|
||||
struct utsname info;
|
||||
|
||||
#ifdef __APPLE__
|
||||
// Recognize UNAME_RELEASE environment variable to match Darwin uname.
|
||||
const char *UnameOverride = ::getenv("UNAME_RELEASE");
|
||||
if (UnameOverride && UnameOverride[0] != '\0')
|
||||
return UnameOverride;
|
||||
#endif // __APPLE__
|
||||
|
||||
if (uname(&info))
|
||||
return "";
|
||||
|
Loading…
Reference in New Issue
Block a user