Skip to content

Commit

Permalink
[workspace] Fix leaky symbol in abseill_cpp (RobotLocomotion#20359)
Browse files Browse the repository at this point in the history
  • Loading branch information
jwnimmer-tri authored and WawasCode committed Oct 31, 2023
1 parent 3d53770 commit a1744bf
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 3 deletions.
1 change: 0 additions & 1 deletion tools/install/libdrake/test/exported_symbols_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@
# will not cause this test to fail.
_KNOWN_BAD_SYMBOLS_SUBSTR = [
"5bazel5tools3cpp8runfiles",
"AbslInternal",
"Ampl",
"BitVector128",
"Clp",
Expand Down
19 changes: 17 additions & 2 deletions tools/workspace/abseil_cpp_internal/patches/inline_namespace.patch
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ Use an inline namespace for Abseil.
This prevents Drake's build of Abseil from interfering with a user's
downstream build of Abseil when the user is using static linking.

--- absl/base/options.h.orig 2022-03-08 13:01:16.000000000 -0800
+++ absl/base/options.h 2022-03-13 13:44:21.385254191 -0700
--- absl/base/options.h
+++ absl/base/options.h
@@ -205,8 +205,8 @@
// be changed to a new, unique identifier name. In particular "head" is not
// allowed.
Expand All @@ -16,3 +16,18 @@ downstream build of Abseil when the user is using static linking.

// ABSL_OPTION_HARDENED
//

--- absl/debugging/symbolize_elf.inc
+++ absl/debugging/symbolize_elf.inc
@@ -1653,9 +1653,11 @@
ABSL_NAMESPACE_END
} // namespace absl

+#if 0 // This (dead) code disobeys the drake_vendor inline namespace.
extern "C" bool AbslInternalGetFileMappingHint(const void **start,
const void **end, uint64_t *offset,
const char **filename) {
return absl::debugging_internal::GetFileMappingHint(start, end, offset,
filename);
}
+#endif

0 comments on commit a1744bf

Please sign in to comment.