diff options
Diffstat (limited to 'meta-oe/recipes-devtools')
5 files changed, 166 insertions, 1 deletions
diff --git a/meta-oe/recipes-devtools/abseil-cpp/abseil-cpp/0001-Export-of-internal-Abseil-changes.patch b/meta-oe/recipes-devtools/abseil-cpp/abseil-cpp/0001-Export-of-internal-Abseil-changes.patch new file mode 100644 index 000000000..c0fb0571f --- /dev/null +++ b/meta-oe/recipes-devtools/abseil-cpp/abseil-cpp/0001-Export-of-internal-Abseil-changes.patch @@ -0,0 +1,82 @@ +From d3424201a73f29ab533121b1821a76e1b4313beb Mon Sep 17 00:00:00 2001 +From: Abseil Team <absl-team@google.com> +Date: Mon, 3 May 2021 07:37:39 -0700 +Subject: [PATCH] Export of internal Abseil changes + +-- +cf88f9cf40eab54c06bca7f20795352ec23bb583 by Derek Mauro <dmauro@google.com>: + +Fixes build with latest glibc +Fixes #952 + +PiperOrigin-RevId: 371693908 + +-- +99bcd0f4a747ce7a401e23c745adf34d0ec5131b by Samuel Benzaquen <sbenza@google.com>: + +Add support for std::string_view in StrFormat even when +absl::string_view != std::string_view. + +PiperOrigin-RevId: 371693633 + +-- +e35463572149a6c2d4a0d439b9300ce03fd6b96d by Abseil Team <absl-team@google.com>: + +Cmake builds should only install pkg-config when explicitly requested. + +PiperOrigin-RevId: 371403419 +GitOrigin-RevId: cf88f9cf40eab54c06bca7f20795352ec23bb583 +Change-Id: I4360a18c638a4d901ff44ab1e0a9d8f321c302ea +--- + absl/debugging/failure_signal_handler.cc | 3 ++- + absl/strings/internal/str_format/arg.h | 8 ++++++++ + absl/strings/internal/str_format/convert_test.cc | 3 +++ + 3 files changed, 13 insertions(+), 1 deletion(-) + +diff --git a/absl/debugging/failure_signal_handler.cc b/absl/debugging/failure_signal_handler.cc +index 5d13bdbb..2ed137b5 100644 +--- a/absl/debugging/failure_signal_handler.cc ++++ b/absl/debugging/failure_signal_handler.cc +@@ -135,7 +135,8 @@ static bool SetupAlternateStackOnce() { + #else + const size_t page_mask = sysconf(_SC_PAGESIZE) - 1; + #endif +- size_t stack_size = (std::max(SIGSTKSZ, 65536) + page_mask) & ~page_mask; ++ size_t stack_size = ++ (std::max<size_t>(SIGSTKSZ, 65536) + page_mask) & ~page_mask; + #if defined(ABSL_HAVE_ADDRESS_SANITIZER) || \ + defined(ABSL_HAVE_MEMORY_SANITIZER) || defined(ABSL_HAVE_THREAD_SANITIZER) + // Account for sanitizer instrumentation requiring additional stack space. +diff --git a/absl/strings/internal/str_format/arg.h b/absl/strings/internal/str_format/arg.h +index 3dbc1526..f9d89d12 100644 +--- a/absl/strings/internal/str_format/arg.h ++++ b/absl/strings/internal/str_format/arg.h +@@ -108,6 +108,14 @@ StringConvertResult FormatConvertImpl(const std::string& v, + StringConvertResult FormatConvertImpl(string_view v, + FormatConversionSpecImpl conv, + FormatSinkImpl* sink); ++#if defined(ABSL_HAVE_STD_STRING_VIEW) && !defined(ABSL_USES_STD_STRING_VIEW) ++inline StringConvertResult FormatConvertImpl(std::string_view v, ++ FormatConversionSpecImpl conv, ++ FormatSinkImpl* sink) { ++ return FormatConvertImpl(absl::string_view(v.data(), v.size()), conv, sink); ++} ++#endif // ABSL_HAVE_STD_STRING_VIEW && !ABSL_USES_STD_STRING_VIEW ++ + ArgConvertResult<FormatConversionCharSetUnion( + FormatConversionCharSetInternal::s, FormatConversionCharSetInternal::p)> + FormatConvertImpl(const char* v, const FormatConversionSpecImpl conv, +diff --git a/absl/strings/internal/str_format/convert_test.cc b/absl/strings/internal/str_format/convert_test.cc +index 634ee78b..cc789530 100644 +--- a/absl/strings/internal/str_format/convert_test.cc ++++ b/absl/strings/internal/str_format/convert_test.cc +@@ -215,6 +215,9 @@ TEST_F(FormatConvertTest, BasicString) { + TestStringConvert(static_cast<const char*>("hello")); + TestStringConvert(std::string("hello")); + TestStringConvert(string_view("hello")); ++#if defined(ABSL_HAVE_STD_STRING_VIEW) ++ TestStringConvert(std::string_view("hello")); ++#endif // ABSL_HAVE_STD_STRING_VIEW + } + + TEST_F(FormatConvertTest, NullString) { diff --git a/meta-oe/recipes-devtools/abseil-cpp/abseil-cpp_git.bb b/meta-oe/recipes-devtools/abseil-cpp/abseil-cpp_git.bb index 569bb1399..a49fe672e 100644 --- a/meta-oe/recipes-devtools/abseil-cpp/abseil-cpp_git.bb +++ b/meta-oe/recipes-devtools/abseil-cpp/abseil-cpp_git.bb @@ -14,6 +14,7 @@ SRC_URI = "git://github.com/abseil/abseil-cpp;branch=${BRANCH};protocol=https \ file://0001-absl-always-use-asm-sgidefs.h.patch \ file://0002-Remove-maes-option-from-cross-compilation.patch \ file://abseil-ppc-fixes.patch \ + file://0001-Export-of-internal-Abseil-changes.patch \ " S = "${WORKDIR}/git" diff --git a/meta-oe/recipes-devtools/breakpad/breakpad_git.bb b/meta-oe/recipes-devtools/breakpad/breakpad_git.bb index d85e51ba8..1434e4fee 100644 --- a/meta-oe/recipes-devtools/breakpad/breakpad_git.bb +++ b/meta-oe/recipes-devtools/breakpad/breakpad_git.bb @@ -29,7 +29,7 @@ SRCREV_lss = "fd00dbbd0c06a309c657d89e9430143b179ff6db" SRCREV_gyp = "324dd166b7c0b39d513026fa52d6280ac6d56770" SRC_URI = "git://github.com/google/breakpad;name=breakpad;branch=main;protocol=https \ - git://github.com/google/googletest.git;destsuffix=git/src/testing/gtest;name=gtest;branch=master;protocol=https \ + git://github.com/google/googletest.git;destsuffix=git/src/testing/gtest;name=gtest;branch=main;protocol=https \ git://github.com/protocolbuffers/protobuf.git;destsuffix=git/src/third_party/protobuf/protobuf;name=protobuf;branch=master;protocol=https \ git://chromium.googlesource.com/linux-syscall-support;protocol=https;branch=main;destsuffix=git/src/third_party/lss;name=lss \ git://chromium.googlesource.com/external/gyp;protocol=https;destsuffix=git/src/tools/gyp;name=gyp;branch=master \ diff --git a/meta-oe/recipes-devtools/protobuf/protobuf/0001-Lower-init-prio-for-extension-attributes.patch b/meta-oe/recipes-devtools/protobuf/protobuf/0001-Lower-init-prio-for-extension-attributes.patch new file mode 100644 index 000000000..9f4fd7179 --- /dev/null +++ b/meta-oe/recipes-devtools/protobuf/protobuf/0001-Lower-init-prio-for-extension-attributes.patch @@ -0,0 +1,81 @@ +From 00362d12edf1b7fde723b041a4569dc659e65ad1 Mon Sep 17 00:00:00 2001 +From: Jani Nurminen <jani.nurminen@windriver.com> +Date: Fri, 24 Sep 2021 09:56:11 +0200 +Subject: Lower init prio for extension attributes +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Added PROTOBUF_EXTENSION_ATTRIBUTE_INIT_PRIORITY in +code generation for extension attributes. +It has lower prio than PROTOBUF_ATTRIBUTE_INIT_PRIORITY to +ensure that extension attributes are initialized after +other attribute. +This is needed in some applications to avoid segmentation fault. + +Reported by Karl-Herman Näslund. + +Signed-off-by: Jani Nurminen <jani.nurminen@windriver.com> + +Upstream-Status: Pending + +Signed-off-by: He Zhe <zhe.he@windriver.com> +--- + src/google/protobuf/compiler/cpp/cpp_extension.cc | 2 +- + src/google/protobuf/port_def.inc | 7 +++++++ + src/google/protobuf/port_undef.inc | 1 + + 3 files changed, 9 insertions(+), 1 deletion(-) + +diff --git a/src/google/protobuf/compiler/cpp/cpp_extension.cc b/src/google/protobuf/compiler/cpp/cpp_extension.cc +index 3792db81a..cbec19d30 100644 +--- a/src/google/protobuf/compiler/cpp/cpp_extension.cc ++++ b/src/google/protobuf/compiler/cpp/cpp_extension.cc +@@ -174,7 +174,7 @@ void ExtensionGenerator::GenerateDefinition(io::Printer* printer) { + } + + format( +- "PROTOBUF_ATTRIBUTE_INIT_PRIORITY " ++ "PROTOBUF_EXTENSION_ATTRIBUTE_INIT_PRIORITY " + "::$proto_ns$::internal::ExtensionIdentifier< $extendee$,\n" + " ::$proto_ns$::internal::$type_traits$, $field_type$, $packed$ >\n" + " $scoped_name$($constant_name$, $1$);\n", +diff --git a/src/google/protobuf/port_def.inc b/src/google/protobuf/port_def.inc +index ae9fef425..f1d203707 100644 +--- a/src/google/protobuf/port_def.inc ++++ b/src/google/protobuf/port_def.inc +@@ -154,6 +154,9 @@ + #ifdef PROTOBUF_ATTRIBUTE_INIT_PRIORITY + #error PROTOBUF_ATTRIBUTE_INIT_PRIORITY was previously defined + #endif ++#ifdef PROTOBUF_EXTENSION_ATTRIBUTE_INIT_PRIORITY ++#error PROTOBUF_EXTENSION_ATTRIBUTE_INIT_PRIORITY was previously defined ++#endif + #ifdef PROTOBUF_PRAGMA_INIT_SEG + #error PROTOBUF_PRAGMA_INIT_SEG was previously defined + #endif +@@ -596,6 +599,10 @@ + // Highest priority is 101. We use 102 to allow code that really wants to + // higher priority to still beat us. + #define PROTOBUF_ATTRIBUTE_INIT_PRIORITY __attribute__((init_priority((102)))) ++// Some embedded systems get a segmentation fault if extension attributes are ++// initialized with higher or equal priority as other attributes. This gives ++// extension attributes high priority, but lower than other attributes. ++#define PROTOBUF_EXTENSION_ATTRIBUTE_INIT_PRIORITY __attribute__((init_priority((103)))) + #else + #define PROTOBUF_ATTRIBUTE_INIT_PRIORITY + #endif +diff --git a/src/google/protobuf/port_undef.inc b/src/google/protobuf/port_undef.inc +index daef09bc4..d0c613b55 100644 +--- a/src/google/protobuf/port_undef.inc ++++ b/src/google/protobuf/port_undef.inc +@@ -77,6 +77,7 @@ + #undef PROTOBUF_ATTRIBUTE_WEAK + #undef PROTOBUF_ATTRIBUTE_NO_DESTROY + #undef PROTOBUF_ATTRIBUTE_INIT_PRIORITY ++#undef PROTOBUF_EXTENSION_ATTRIBUTE_INIT_PRIORITY + #undef PROTOBUF_PRAGMA_INIT_SEG + + // Restore macro that may have been #undef'd in port_def.inc. +-- +2.17.1 + diff --git a/meta-oe/recipes-devtools/protobuf/protobuf_3.15.2.bb b/meta-oe/recipes-devtools/protobuf/protobuf_3.15.2.bb index 62c6ee015..ac4e1ad84 100644 --- a/meta-oe/recipes-devtools/protobuf/protobuf_3.15.2.bb +++ b/meta-oe/recipes-devtools/protobuf/protobuf_3.15.2.bb @@ -17,6 +17,7 @@ SRC_URI = "git://github.com/protocolbuffers/protobuf.git;branch=master;protocol= file://0001-protobuf-fix-configure-error.patch \ file://0001-Makefile.am-include-descriptor.cc-when-building-libp.patch \ file://0001-examples-Makefile-respect-CXX-LDFLAGS-variables-fix-.patch \ + file://0001-Lower-init-prio-for-extension-attributes.patch \ " S = "${WORKDIR}/git" |