aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBruce Mitchener <bruce.mitchener@gmail.com>2013-08-28 11:59:13 +0700
committerAlon Zakai <alonzakai@gmail.com>2013-09-13 10:07:02 -0700
commitc1553c6058d63d81872682c09696f1133ffce851 (patch)
tree0bbf4ec98fb58b4237446df274f72e11cd9dcc98
parente06db6956491cfdb30cb74fdb92c740b3bcdd5dd (diff)
Fix fpclassify with musl libc headers.
musl defines __fpclassify, __fpclassifyf, __fpclassifyl while the old headers used __fpclassifyd for double rather than __fpclassify.
-rw-r--r--src/library.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/library.js b/src/library.js
index a8bd6d8f..411853ef 100644
--- a/src/library.js
+++ b/src/library.js
@@ -5036,14 +5036,15 @@ LibraryManager.library = {
return divt;
},
- __fpclassifyf: function(x) {
+ __fpclassify: function(x) {
if (isNaN(x)) return {{{ cDefine('FP_NAN') }}};
if (!isFinite(x)) return {{{ cDefine('FP_INFINITE') }}};
if (x == 0) return {{{ cDefine('FP_ZERO') }}};
// FP_SUBNORMAL..?
return {{{ cDefine('FP_NORMAL') }}};
},
- __fpclassifyd: '__fpclassifyf',
+ __fpclassifyd: '__fpclassify', // Needed by tests/python/python.le32.bc
+ __fpclassifyf: '__fpclassify',
// ==========================================================================
// sys/utsname.h