summaryrefslogtreecommitdiff
path: root/firefox-aarch64-double-convertsion.patch
blob: 06320be2de917cc0e1d300b9d06bf7fbbcd05a18 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80

# HG changeset patch
# User Marcin Juszkiewicz <mjuszkiewicz@redhat.com>
# Date 1393440196 18000
# Node ID 6a46f53ad944b44385398822d7bcf7621a785d91
# Parent  0aa56e2a5f816a30da48701f73d03060ee9692b2
Bug 962488 - Update double-conversion for proper AArch64 support. r=froydnj

Fix imported from upstream repository:
https://code.google.com/p/double-conversion/source/detail?r=4e24bb31bcc76d6d218f3056b4c24a109d367561

diff --git a/mfbt/double-conversion/fix-aarch64-macro.patch b/mfbt/double-conversion/fix-aarch64-macro.patch
new file mode 100644
--- /dev/null
+++ b/mfbt/double-conversion/fix-aarch64-macro.patch
@@ -0,0 +1,23 @@
+Backport from upstream.
+
+https://code.google.com/p/double-conversion/source/detail?r=4e24bb31bcc76d6d218f3056b4c24a109d367561
+
+---
+ mfbt/double-conversion/utils.h |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/mfbt/double-conversion/utils.h
++++ b/mfbt/double-conversion/utils.h
+@@ -58,11 +58,11 @@
+     defined(__mips__) || \
+     defined(__powerpc__) || defined(__ppc__) || defined(__ppc64__) || \
+     defined(__sparc__) || defined(__sparc) || defined(__s390__) || \
+     defined(__SH4__) || defined(__alpha__) || \
+     defined(_MIPS_ARCH_MIPS32R2) || \
+-    defined(_AARCH64EL_)
++    defined(__AARCH64EL__)
+ #define DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS 1
+ #elif defined(_M_IX86) || defined(__i386__) || defined(__i386)
+ #if defined(_WIN32)
+ // Windows uses a 64bit wide floating point stack.
+ #define DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS 1
diff --git a/mfbt/double-conversion/update.sh b/mfbt/double-conversion/update.sh
--- a/mfbt/double-conversion/update.sh
+++ b/mfbt/double-conversion/update.sh
@@ -15,9 +15,12 @@ cp $1/src/*.h ./
 
 # Source
 cp $1/src/*.cc ./
 
 patch -p3 < add-mfbt-api-markers.patch
 patch -p3 < use-StandardInteger.patch
 patch -p3 < use-mozilla-assertions.patch
 patch -p3 < use-static_assert.patch
-patch -p3 < ToPrecision-exponential.patch
\ No newline at end of file
+patch -p3 < ToPrecision-exponential.patch
+
+# Merged upstream, part of 2.0.1 version
+patch -p3 < fix-aarch64-macro.patch
diff --git a/mfbt/double-conversion/utils.h b/mfbt/double-conversion/utils.h
--- a/mfbt/double-conversion/utils.h
+++ b/mfbt/double-conversion/utils.h
@@ -55,17 +55,17 @@
 #if defined(_M_X64) || defined(__x86_64__) || \
     defined(__ARMEL__) || defined(__avr32__) || \
     defined(__hppa__) || defined(__ia64__) || \
     defined(__mips__) || \
     defined(__powerpc__) || defined(__ppc__) || defined(__ppc64__) || \
     defined(__sparc__) || defined(__sparc) || defined(__s390__) || \
     defined(__SH4__) || defined(__alpha__) || \
     defined(_MIPS_ARCH_MIPS32R2) || \
-    defined(_AARCH64EL_)
+    defined(__AARCH64EL__)
 #define DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS 1
 #elif defined(_M_IX86) || defined(__i386__) || defined(__i386)
 #if defined(_WIN32)
 // Windows uses a 64bit wide floating point stack.
 #define DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS 1
 #else
 #undef DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS
 #endif  // _WIN32

bgstack15