pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc/devel/abseil
Module Name: pkgsrc
Committed By: prlw1
Date: Fri Sep 19 06:56:57 UTC 2025
Modified Files:
pkgsrc/devel/abseil: Makefile distinfo
Added Files:
pkgsrc/devel/abseil/patches: patch-absl_log_internal_check__op.h
Log Message:
abseil: add upstream gcc 8 std::underlying_type build fix
Hopefully fixes build on NetBSD 9
To generate a diff of this commit:
cvs rdiff -u -r1.34 -r1.35 pkgsrc/devel/abseil/Makefile
cvs rdiff -u -r1.32 -r1.33 pkgsrc/devel/abseil/distinfo
cvs rdiff -u -r0 -r1.1 \
pkgsrc/devel/abseil/patches/patch-absl_log_internal_check__op.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: pkgsrc/devel/abseil/Makefile
diff -u pkgsrc/devel/abseil/Makefile:1.34 pkgsrc/devel/abseil/Makefile:1.35
--- pkgsrc/devel/abseil/Makefile:1.34 Sun Aug 24 16:34:56 2025
+++ pkgsrc/devel/abseil/Makefile Fri Sep 19 06:56:57 2025
@@ -1,6 +1,7 @@
-# $NetBSD: Makefile,v 1.34 2025/08/24 16:34:56 wiz Exp $
+# $NetBSD: Makefile,v 1.35 2025/09/19 06:56:57 prlw1 Exp $
DISTNAME= abseil-20250814.0
+PKGREVISION= 1
CATEGORIES= devel
MASTER_SITES= ${MASTER_SITE_GITHUB:=abseil/}
GITHUB_PROJECT= abseil-cpp
Index: pkgsrc/devel/abseil/distinfo
diff -u pkgsrc/devel/abseil/distinfo:1.32 pkgsrc/devel/abseil/distinfo:1.33
--- pkgsrc/devel/abseil/distinfo:1.32 Sun Aug 24 16:34:56 2025
+++ pkgsrc/devel/abseil/distinfo Fri Sep 19 06:56:57 2025
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.32 2025/08/24 16:34:56 wiz Exp $
+$NetBSD: distinfo,v 1.33 2025/09/19 06:56:57 prlw1 Exp $
BLAKE2s (abseil-20250814.0-20250814.0.tar.gz) = 0a78be4e2086a448bf901ab2e7a608b6dc58277c04c95ffe8c9ad188f73fb2fe
SHA512 (abseil-20250814.0-20250814.0.tar.gz) = 4ee1a217203933382e728d354a149253a517150eee7580a0abecc69584b2eb200d91933ef424487e3a3fe0e8ab5e77b0288485cac982171b3585314a4417e7d4
@@ -6,4 +6,5 @@ Size (abseil-20250814.0-20250814.0.tar.g
SHA1 (patch-absl_base_internal_sysinfo.cc) = c96dd302dde0f6071a8353a5877a3bac37949467
SHA1 (patch-absl_debugging_internal_elf__mem__image.cc) = 4165ab657a03194a5266815440f40cf4aa958f7b
SHA1 (patch-absl_debugging_internal_vdso__support.cc) = 2292c5b0f2b41679039a1697508343ff5b6cc401
+SHA1 (patch-absl_log_internal_check__op.h) = d8b73eeb391b0306f13ca829da446210a5e9aa7a
SHA1 (patch-absl_time_internal_cctz_src_time__zone__format.cc) = 7f3b84cd63f847ffa4c2fcb04b28d1535ea1454b
Added files:
Index: pkgsrc/devel/abseil/patches/patch-absl_log_internal_check__op.h
diff -u /dev/null pkgsrc/devel/abseil/patches/patch-absl_log_internal_check__op.h:1.1
--- /dev/null Fri Sep 19 06:56:57 2025
+++ pkgsrc/devel/abseil/patches/patch-absl_log_internal_check__op.h Fri Sep 19 06:56:57 2025
@@ -0,0 +1,49 @@
+$NetBSD: patch-absl_log_internal_check__op.h,v 1.1 2025/09/19 06:56:57 prlw1 Exp $
+
+Fix check_op(s) compilation failures on gcc 8 which eagerly
+tries to instantiate std::underlying_type for non-num types.
+
+Before cpp20 using std::underlying_t on non enum types is undefined behaviour.
+
+https://github.com/abseil/abseil-cpp/commit/e8c1a5ff2346d40be5f2450044c01c845777cc02
+
+--- absl/log/internal/check_op.h.orig 2025-08-14 19:54:55.000000000 +0000
++++ absl/log/internal/check_op.h
+@@ -375,6 +375,18 @@ std::enable_if_t<std::negation_v<std::di
+ UnprintableWrapper>
+ Detect(...);
+
++// Equivalent to the updated std::underlying_type from C++20, which is no
++// longer undefined behavior for non-enum types.
++template <typename T, typename EnableT = void>
++struct UnderlyingType {};
++
++template <typename T>
++struct UnderlyingType<T, std::enable_if_t<std::is_enum_v<T>>> {
++ using type = std::underlying_type_t<T>;
++};
++template <typename T>
++using UnderlyingTypeT = typename UnderlyingType<T>::type;
++
+ // This overload triggers when T is a scoped enum that has not defined an output
+ // stream operator (operator<<) or AbslStringify. It causes the enum value to be
+ // converted to a type that can be streamed. For consistency with other enums, a
+@@ -386,12 +398,12 @@ std::enable_if_t<
+ std::is_enum<T>, std::negation<std::is_convertible<T, int>>,
+ std::negation<is_streamable<T>>, std::negation<HasAbslStringify<T>>>,
+ std::conditional_t<
+- std::is_same_v<std::underlying_type_t<T>, bool> ||
+- std::is_same_v<std::underlying_type_t<T>, char> ||
+- std::is_same_v<std::underlying_type_t<T>, signed char> ||
+- std::is_same_v<std::underlying_type_t<T>, unsigned char>,
+- std::underlying_type_t<T>,
+- std::conditional_t<std::is_signed_v<std::underlying_type_t<T>>, int64_t,
++ std::is_same_v<UnderlyingTypeT<T>, bool> ||
++ std::is_same_v<UnderlyingTypeT<T>, char> ||
++ std::is_same_v<UnderlyingTypeT<T>, signed char> ||
++ std::is_same_v<UnderlyingTypeT<T>, unsigned char>,
++ UnderlyingTypeT<T>,
++ std::conditional_t<std::is_signed_v<UnderlyingTypeT<T>>, int64_t,
+ uint64_t>>>
+ Detect(...);
+ } // namespace detect_specialization
Home |
Main Index |
Thread Index |
Old Index