mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-01-30 19:43:13 +01:00
Add isnan for __APPLE__ and darwin version ident for OSX.
This commit is contained in:
@@ -25,6 +25,12 @@ extern "C" char * __cdecl __locale_decpoint;
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef __APPLE__
|
||||
#ifndef isnan
|
||||
int isnan(double);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#if IN_GCC
|
||||
// Issues with using -include total.h (defines integer_t) and then complex.h fails...
|
||||
#undef integer_t
|
||||
|
||||
@@ -314,6 +314,8 @@ int main(int argc, char *argv[])
|
||||
global.params.os = OSWindows;
|
||||
#elif linux
|
||||
global.params.os = OSLinux;
|
||||
#elif __APPLY__
|
||||
global.params.os = OSMacOSX;
|
||||
#else
|
||||
#error
|
||||
#endif /* linux */
|
||||
@@ -749,12 +751,16 @@ int main(int argc, char *argv[])
|
||||
global.params.tt_os = "-pc-mingw32";
|
||||
break;
|
||||
|
||||
case OSLinux:
|
||||
case OSLinux:
|
||||
VersionCondition::addPredefinedGlobalIdent("linux");
|
||||
VersionCondition::addPredefinedGlobalIdent("Posix");
|
||||
global.params.tt_os = "-pc-linux-gnu";
|
||||
break;
|
||||
|
||||
case OSMacOSX:
|
||||
VersionCondition::addPredefinedGlobalIdent("darwin");
|
||||
global.params.tt_os = "-pc-darwin-gnu";
|
||||
|
||||
default:
|
||||
assert(false && "Target OS not supported");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user