OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2007-2008 the V8 project authors. All rights reserved. | 2 * Copyright 2007-2008 the V8 project authors. All rights reserved. |
3 * Redistribution and use in source and binary forms, with or without | 3 * Redistribution and use in source and binary forms, with or without |
4 * modification, are permitted provided that the following conditions are | 4 * modification, are permitted provided that the following conditions are |
5 * met: | 5 * met: |
6 * | 6 * |
7 * * Redistributions of source code must retain the above copyright | 7 * * Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * * Redistributions in binary form must reproduce the above | 9 * * Redistributions in binary form must reproduce the above |
10 * copyright notice, this list of conditions and the following | 10 * copyright notice, this list of conditions and the following |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
65 /* stdlib.h on Windows adds __declspec(dllimport) to all functions when using | 65 /* stdlib.h on Windows adds __declspec(dllimport) to all functions when using |
66 * the DLL version of the CRT (compiling with /MD or /MDd). If stdlib.h is | 66 * the DLL version of the CRT (compiling with /MD or /MDd). If stdlib.h is |
67 * included after strtod is redefined as gay_strtod, it will add | 67 * included after strtod is redefined as gay_strtod, it will add |
68 * __declspec(dllimport) to gay_strtod, which causes the compilation of | 68 * __declspec(dllimport) to gay_strtod, which causes the compilation of |
69 * gay_strtod in dtoa.c to fail. | 69 * gay_strtod in dtoa.c to fail. |
70 */ | 70 */ |
71 #if defined(WIN32) && defined(_DLL) | 71 #if defined(WIN32) && defined(_DLL) |
72 #include "stdlib.h" | 72 #include "stdlib.h" |
73 #endif | 73 #endif |
74 | 74 |
| 75 /* For MinGW, turn on __NO_ISOCEXT so that its strtod doesn't get added */ |
| 76 #ifdef __MINGW32__ |
| 77 #define __NO_ISOCEXT |
| 78 #endif /* __MINGW32__ */ |
| 79 |
75 /* Make sure we use the David M. Gay version of strtod(). On Linux, we | 80 /* Make sure we use the David M. Gay version of strtod(). On Linux, we |
76 * cannot use the same name (maybe the function does not have weak | 81 * cannot use the same name (maybe the function does not have weak |
77 * linkage?). */ | 82 * linkage?). */ |
78 #define strtod gay_strtod | 83 #define strtod gay_strtod |
79 #include "third_party/dtoa/dtoa.c" | 84 #include "third_party/dtoa/dtoa.c" |
OLD | NEW |