From ef9004136586ce9f5fc44e9f72ea5023923a0248 Mon Sep 17 00:00:00 2001 From: Benjamin Barenblat Date: Mon, 12 May 2025 17:26:59 +0200 Subject: [PATCH] Set package configuration options Forwarded: not-needed Configure Abseil for Debian. - Set the SONAME appropriately. - To minimize the possibility of future ABI breakage, treat absl::any, absl::optional, absl::string_view, and absl::variant as their own types (rather than aliases for the std:: versions), and compile everything in an inline namespace. - Enable upstream's hardened build mode. Gbp-Pq: Name configure.diff --- CMake/AbseilHelpers.cmake | 3 ++- absl/base/options.h | 12 ++++++------ 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/CMake/AbseilHelpers.cmake b/CMake/AbseilHelpers.cmake index dbb09fe..6b6613f 100644 --- a/CMake/AbseilHelpers.cmake +++ b/CMake/AbseilHelpers.cmake @@ -281,7 +281,8 @@ Cflags: -I\${includedir}${PC_CFLAGS}\n") if(ABSL_ENABLE_INSTALL) set_target_properties(${_NAME} PROPERTIES OUTPUT_NAME "absl_${_NAME}" - SOVERSION "2206.0.0" + SOVERSION 20220623 + VERSION "20220623.0.0" ) endif() else() diff --git a/absl/base/options.h b/absl/base/options.h index bc59847..62f29a1 100644 --- a/absl/base/options.h +++ b/absl/base/options.h @@ -100,7 +100,7 @@ // User code should not inspect this macro. To check in the preprocessor if // absl::any is a typedef of std::any, use the feature macro ABSL_USES_STD_ANY. -#define ABSL_OPTION_USE_STD_ANY 2 +#define ABSL_OPTION_USE_STD_ANY 0 // ABSL_OPTION_USE_STD_OPTIONAL @@ -127,7 +127,7 @@ // absl::optional is a typedef of std::optional, use the feature macro // ABSL_USES_STD_OPTIONAL. -#define ABSL_OPTION_USE_STD_OPTIONAL 2 +#define ABSL_OPTION_USE_STD_OPTIONAL 0 // ABSL_OPTION_USE_STD_STRING_VIEW @@ -154,7 +154,7 @@ // absl::string_view is a typedef of std::string_view, use the feature macro // ABSL_USES_STD_STRING_VIEW. -#define ABSL_OPTION_USE_STD_STRING_VIEW 2 +#define ABSL_OPTION_USE_STD_STRING_VIEW 0 // ABSL_OPTION_USE_STD_VARIANT // @@ -180,7 +180,7 @@ // absl::variant is a typedef of std::variant, use the feature macro // ABSL_USES_STD_VARIANT. -#define ABSL_OPTION_USE_STD_VARIANT 2 +#define ABSL_OPTION_USE_STD_VARIANT 0 // ABSL_OPTION_USE_INLINE_NAMESPACE @@ -206,7 +206,7 @@ // allowed. #define ABSL_OPTION_USE_INLINE_NAMESPACE 1 -#define ABSL_OPTION_INLINE_NAMESPACE_NAME lts_20220623 +#define ABSL_OPTION_INLINE_NAMESPACE_NAME debian3 // ABSL_OPTION_HARDENED // @@ -233,6 +233,6 @@ // checks enabled by this option may abort the program in a different way and // log additional information when `NDEBUG` is not defined. -#define ABSL_OPTION_HARDENED 0 +#define ABSL_OPTION_HARDENED 1 #endif // ABSL_BASE_OPTIONS_H_ -- 2.30.2