Source code

Revision control

Other Tools

1
--- a/toolkit/components/protobuf/src/google/protobuf/io/zero_copy_stream_impl_lite.h
2
+++ b/toolkit/components/protobuf/src/google/protobuf/io/zero_copy_stream_impl_lite.h
3
@@ -43,16 +43,17 @@
4
5
#ifndef GOOGLE_PROTOBUF_IO_ZERO_COPY_STREAM_IMPL_LITE_H__
6
#define GOOGLE_PROTOBUF_IO_ZERO_COPY_STREAM_IMPL_LITE_H__
7
8
#include <memory>
9
#ifndef _SHARED_PTR_H
10
#include <google/protobuf/stubs/shared_ptr.h>
11
#endif
12
+#include <vector> /* Needed by GCC 4.9 on Android (see Bug 1186561) */
13
#include <string>
14
#include <iosfwd>
15
#include <google/protobuf/io/zero_copy_stream.h>
16
#include <google/protobuf/stubs/callback.h>
17
#include <google/protobuf/stubs/common.h>
18
#include <google/protobuf/stubs/stl_util.h>
19
20
21
diff --git a/toolkit/components/protobuf/src/google/protobuf/stubs/atomicops.h b/toolkit/components/protobuf/src/google/protobuf/stubs/atomicops.h
22
--- a/toolkit/components/protobuf/src/google/protobuf/stubs/atomicops.h
23
+++ b/toolkit/components/protobuf/src/google/protobuf/stubs/atomicops.h
24
@@ -84,17 +84,21 @@ typedef int64 Atomic64;
25
#else
26
typedef intptr_t Atomic64;
27
#endif
28
#endif
29
#endif
30
31
// Use AtomicWord for a machine-sized pointer. It will use the Atomic32 or
32
// Atomic64 routines below, depending on your architecture.
33
+#if defined(__OpenBSD__) && !defined(GOOGLE_PROTOBUF_ARCH_64_BIT) /* See Bug 1192556 */
34
+typedef Atomic32 AtomicWord;
35
+#else
36
typedef intptr_t AtomicWord;
37
+#endif
38
39
// Atomically execute:
40
// result = *ptr;
41
// if (*ptr == old_value)
42
// *ptr = new_value;
43
// return result;
44
//
45
// I.e., replace "*ptr" with "new_value" if "*ptr" used to be "old_value".
46
diff --git a/toolkit/components/protobuf/src/google/protobuf/stubs/platform_macros.h b/toolkit/components/protobuf/src/google/protobuf/stubs/platform_macros.h
47
--- a/toolkit/components/protobuf/src/google/protobuf/stubs/platform_macros.h
48
+++ b/toolkit/components/protobuf/src/google/protobuf/stubs/platform_macros.h
49
@@ -45,17 +45,17 @@
50
#define GOOGLE_PROTOBUF_ARCH_IA32 1
51
#define GOOGLE_PROTOBUF_ARCH_32_BIT 1
52
#elif defined(__QNX__)
53
#define GOOGLE_PROTOBUF_ARCH_ARM_QNX 1
54
#define GOOGLE_PROTOBUF_ARCH_32_BIT 1
55
#elif defined(_M_ARM) || defined(__ARMEL__)
56
#define GOOGLE_PROTOBUF_ARCH_ARM 1
57
#define GOOGLE_PROTOBUF_ARCH_32_BIT 1
58
-#elif defined(__aarch64__)
59
+#elif defined(__aarch64__) || defined(_M_ARM64)
60
#define GOOGLE_PROTOBUF_ARCH_AARCH64 1
61
#define GOOGLE_PROTOBUF_ARCH_64_BIT 1
62
#elif defined(__MIPSEL__)
63
#if defined(__LP64__)
64
#define GOOGLE_PROTOBUF_ARCH_MIPS64 1
65
#define GOOGLE_PROTOBUF_ARCH_64_BIT 1
66
#else
67
#define GOOGLE_PROTOBUF_ARCH_MIPS 1
68
diff --git a/toolkit/components/protobuf/src/google/protobuf/stubs/atomicops.h b/toolkit/components/protobuf/src/google/protobuf/stubs/atomicops.h
69
--- a/toolkit/components/protobuf/src/google/protobuf/stubs/atomicops.h
70
+++ b/toolkit/components/protobuf/src/google/protobuf/stubs/atomicops.h
71
@@ -179,17 +179,17 @@ Atomic64 Release_Load(volatile const Ato
72
#define GOOGLE_PROTOBUF_ATOMICOPS_ERROR \
73
"Atomic operations are not supported on your platform"
74
76
#if defined(THREAD_SANITIZER)
77
#include <google/protobuf/stubs/atomicops_internals_tsan.h>
78
// MSVC.
79
#elif defined(_MSC_VER)
80
-#if defined(GOOGLE_PROTOBUF_ARCH_IA32) || defined(GOOGLE_PROTOBUF_ARCH_X64) || defined(GOOGLE_PROTOBUF_ARCH_ARM)
81
+#if defined(GOOGLE_PROTOBUF_ARCH_IA32) || defined(GOOGLE_PROTOBUF_ARCH_X64) || defined(GOOGLE_PROTOBUF_ARCH_ARM) || defined(GOOGLE_PROTOBUF_ARCH_AARCH64)
82
#include <google/protobuf/stubs/atomicops_internals_x86_msvc.h>
83
#else
84
#error GOOGLE_PROTOBUF_ATOMICOPS_ERROR
85
#endif
86
87
// Solaris
88
#elif defined(GOOGLE_PROTOBUF_OS_SOLARIS)
89
#include <google/protobuf/stubs/atomicops_internals_solaris.h>