Date: Sun, 15 Sep 2024 15:57:20 +0000 From: bugzilla-noreply@freebsd.org To: ports-bugs@FreeBSD.org Subject: [Bug 281519] devel/catch: fix build with clang 19 Message-ID: <bug-281519-7788@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D281519 Bug ID: 281519 Summary: devel/catch: fix build with clang 19 Product: Ports & Packages Version: Latest Hardware: Any OS: Any Status: New Severity: Affects Some People Priority: --- Component: Individual Port(s) Assignee: sunpoet@FreeBSD.org Reporter: dim@FreeBSD.org Assignee: sunpoet@FreeBSD.org Flags: maintainer-feedback?(sunpoet@FreeBSD.org) Clang 19 has become more strict about C++ extensions, which results in: =20 /wrkdirs/usr/ports/devel/catch/work/Catch2-2.13.10/projects/SelfTest/UsageT= ests/Class.tests.cpp:83:1: error: passing no argument for the '...' parameter of a variadic macro is a C++20 extension [-Werror,-Wc++20-extensions] 83 | TEMPLATE_TEST_CASE_METHOD(Template_Fixture, "A TEMPLATE_TEST_CASE_METHOD based test run that succeeds", "[class][template]= ", int, float, double) { | ^ /wrkdirs/usr/ports/devel/catch/work/Catch2-2.13.10/include/catch.hpp:257:= 53: note: expanded from macro 'TEMPLATE_TEST_CASE_METHOD' 257 | #define TEMPLATE_TEST_CASE_METHOD( className, ... ) INTERNAL_CATCH_TEMPLATE_TEST_CASE_METHOD( className, __VA_ARGS__ ) | ^ =20 /wrkdirs/usr/ports/devel/catch/work/Catch2-2.13.10/include/internal/catch_t= est_registry.h:302:9: note: expanded from macro 'INTERNAL_CATCH_TEMPLATE_TEST_CASE_METHOD' 302 | INTERNAL_CATCH_TEMPLATE_TEST_CASE_METHOD_2( INTERNAL_CATCH_UNIQUE_NAME( C_A_T_C_H_T_E_M_P_L_A_T_E_T_E_S_T_C_L_A_S_S_ ), INTERNAL_CATCH_UNIQUE_NAME( C_A_T_C_H_T_E_M_P_L_A_T_E_T_E_S_T_ ) , ClassNam= e, Name, Tags, typename T, __VA_ARGS__ ) | ^ =20 /wrkdirs/usr/ports/devel/catch/work/Catch2-2.13.10/include/internal/catch_t= est_registry.h:279:13: note: expanded from macro 'INTERNAL_CATCH_TEMPLATE_TEST_CASE_METHOD_2' 279 |=20=20=20=20=20=20=20=20=20=20=20=20 INTERNAL_CATCH_NTTP_GEN(INTERNAL_CATCH_REMOVE_PARENS(Signature))\ | ^ =20 /wrkdirs/usr/ports/devel/catch/work/Catch2-2.13.10/include/internal/catch_p= reprocessor.hpp:217:465: note: expanded from macro 'INTERNAL_CATCH_NTTP_GEN' 217 | #define INTERNAL_CATCH_NTTP_GEN(...) INTERNAL_CATCH_VA_NARGS_IMPL(__VA_ARGS__, INTERNAL_CATCH_NTTP_1(__VA_ARGS__= ), INTERNAL_CATCH_NTTP_1(__VA_ARGS__), INTERNAL_CATCH_NTTP_1(__VA_ARGS__), INTERNAL_CATCH_NTTP_1(__VA_ARGS__), INTERNAL_CATCH_NTTP_1(__VA_ARGS__), INTERNAL_CATCH_NTTP_1( __VA_ARGS__), INTERNAL_CATCH_NTTP_1( __VA_ARGS__), INTERNAL_CATCH_NTTP_1( __VA_ARGS__), INTERNAL_CATCH_NTTP_1( __VA_ARGS__),INTERNAL_CATCH_NTTP_1( __VA_ARGS__), INTERNAL_CATCH_NTTP_0) |=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20 =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20 =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20 =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20 ^ =20 /wrkdirs/usr/ports/devel/catch/work/Catch2-2.13.10/include/internal/catch_p= reprocessor.hpp:100:9: note: macro 'INTERNAL_CATCH_VA_NARGS_IMPL' defined here 100 | #define INTERNAL_CATCH_VA_NARGS_IMPL(_0, _1, _2, _3, _4, _5, _6, = _7, _8, _9, _10, N, ...) N | ^ This can be fixed by adding -Wno-error=3Dc++20-extensions, which is supported by both clang and gcc. Unfortunately adding it to CXXFLAGS does not work, since that is prepended to the compiler flags in CMakeLists.txt, so -Werror comes after it. Therefore, patch the appropriate CMakeLists.txt file. --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-281519-7788>