Merge pull request #192903 from sg2002/fix/spidermonkey-i686

spidermonkey: fix i686 build

authored by

superherointj and committed by
GitHub
2b5856b4 0905d910

+19
+3
pkgs/development/interpreters/spidermonkey/common.nix
··· 75 75 url = "https://hg.mozilla.org/releases/mozilla-esr102/raw-rev/1fa20fb474f5d149cc32d98df169dee5e6e6861b"; 76 76 sha256 = "sha256-eCisKjNxy9SLr9KoEE2UB26BflUknnR7PIvnpezsZeA="; 77 77 }) 78 + ] ++ lib.optionals (lib.versionAtLeast version "91" && stdenv.hostPlatform.system == "i686-linux") [ 79 + # Fixes i686 build, https://bugzilla.mozilla.org/show_bug.cgi?id=1729459 80 + ./fix-float-i686.patch 78 81 ]; 79 82 80 83 nativeBuildInputs = [
+16
pkgs/development/interpreters/spidermonkey/fix-float-i686.patch
··· 1 + diff --git a/modules/fdlibm/src/math_private.h b/modules/fdlibm/src/math_private.h 2 + index 51d79f9c2ec59..fafd7d6fc1e0d 100644 3 + --- a/modules/fdlibm/src/math_private.h 4 + +++ b/modules/fdlibm/src/math_private.h 5 + @@ -30,5 +30,9 @@ 6 + * Adapted from https://github.com/freebsd/freebsd-src/search?q=__double_t 7 + */ 8 + 9 + +#if defined __FLT_EVAL_METHOD__ && (__FLT_EVAL_METHOD__ == 2) 10 + +typedef long double __double_t; 11 + +#else 12 + typedef double __double_t; 13 + +#endif 14 + typedef __double_t double_t; 15 + 16 + /*