Date: Wed, 10 Jun 2026 19:32:36 +0000 From: Craig Leres <leres@FreeBSD.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org Subject: git: c7b27b642111 - main - security/zeek: Unbreak build for current after 86326398b73b Message-ID: <6a29bbd4.18b7e.33b7285b@gitrepo.freebsd.org>
index | next in thread | raw e-mail
The branch main has been updated by leres: URL: https://cgit.FreeBSD.org/ports/commit/?id=c7b27b6421118cd73d455078ec22b876f19d16ed commit c7b27b6421118cd73d455078ec22b876f19d16ed Author: Craig Leres <leres@FreeBSD.org> AuthorDate: 2026-06-10 19:32:03 +0000 Commit: Craig Leres <leres@FreeBSD.org> CommitDate: 2026-06-10 19:32:03 +0000 security/zeek: Unbreak build for current after 86326398b73b Upstream issue: https://github.com/zeek/zeek/issues/5557 Upstream analysis: In C++20 which we use assert is still a mess since it is so underspecified, but many implementations already perform conversion of its arguments to bool; this is likely the reason we missed this. According to your logs the implementation of assert in your particular build configuration does not do that Upstream fixes: https://github.com/zeek/spicy/pull/2399 Do not assume assert performs C++26 contextual conversions (plus two additional changes) While here switch to USES=compiler:c++20-lang Obtained from: Benjamin Bannier Reported by: pkg-fallout --- security/zeek/Makefile | 2 +- ...auxil_spicy_hilti_runtime_include_configuration.h | 11 +++++++++++ ...-auxil_spicy_hilti_runtime_include_types_stream.h | 20 ++++++++++++++++++++ ..._spicy_hilti_toolchain_include_compiler_printer.h | 11 +++++++++++ ...uxil_spicy_hilti_toolchain_src_ast_ast-context.cc | 11 +++++++++++ ...uxil_spicy_hilti_toolchain_src_compiler_driver.cc | 20 ++++++++++++++++++++ ...auxil_spicy_spicy_runtime_include_configuration.h | 11 +++++++++++ .../patch-auxil_spicy_spicy_runtime_src_sink.cc | 11 +++++++++++ ...clude_compiler_detail_codegen_productions_while.h | 11 +++++++++++ ...toolchain_src_compiler_codegen_grammar-builder.cc | 11 +++++++++++ 10 files changed, 118 insertions(+), 1 deletion(-) diff --git a/security/zeek/Makefile b/security/zeek/Makefile index cd53642c8c70..c48a2a51b23f 100644 --- a/security/zeek/Makefile +++ b/security/zeek/Makefile @@ -16,7 +16,7 @@ LIB_DEPENDS= libcares.so:dns/c-ares \ libzmq.so:net/libzmq4 RUN_DEPENDS= c-ares>=1.25.0:dns/c-ares -USES= bison cmake compiler:c++17-lang cpe gettext-runtime perl5 \ +USES= bison cmake compiler:c++20-lang cpe gettext-runtime perl5 \ python:3.9+ shebangfix ssl USE_LDCONFIG= yes diff --git a/security/zeek/files/patch-auxil_spicy_hilti_runtime_include_configuration.h b/security/zeek/files/patch-auxil_spicy_hilti_runtime_include_configuration.h new file mode 100644 index 000000000000..89b1d7cf051a --- /dev/null +++ b/security/zeek/files/patch-auxil_spicy_hilti_runtime_include_configuration.h @@ -0,0 +1,11 @@ +--- auxil/spicy/hilti/runtime/include/configuration.h.orig 2026-05-12 18:14:47 UTC ++++ auxil/spicy/hilti/runtime/include/configuration.h +@@ -76,7 +76,7 @@ inline const Configuration& unsafeGet() { + * matters. + */ + inline const Configuration& unsafeGet() { +- assert(detail::__configuration); ++ assert(detail::__configuration.get()); + return *detail::__configuration; + } + diff --git a/security/zeek/files/patch-auxil_spicy_hilti_runtime_include_types_stream.h b/security/zeek/files/patch-auxil_spicy_hilti_runtime_include_types_stream.h new file mode 100644 index 000000000000..1aa2ea7c0a33 --- /dev/null +++ b/security/zeek/files/patch-auxil_spicy_hilti_runtime_include_types_stream.h @@ -0,0 +1,20 @@ +--- auxil/spicy/hilti/runtime/include/types/stream.h.orig 2026-05-12 18:14:47 UTC ++++ auxil/spicy/hilti/runtime/include/types/stream.h +@@ -691,7 +691,7 @@ class SafeConstIterator { (private) + + void _ensureValidChain() const { + // This must have been checked at this point already. +- assert(_chain); ++ assert(_chain.get()); + + if ( ! _chain->isValid() ) + throw InvalidIterator("stream object no longer available"); +@@ -1752,7 +1752,7 @@ class Stream { (public) + + /** Destructor. */ + ~Stream() { +- assert(_chain); ++ assert(_chain.get()); + _chain->invalidate(); + } + diff --git a/security/zeek/files/patch-auxil_spicy_hilti_toolchain_include_compiler_printer.h b/security/zeek/files/patch-auxil_spicy_hilti_toolchain_include_compiler_printer.h new file mode 100644 index 000000000000..b66c0a9c7765 --- /dev/null +++ b/security/zeek/files/patch-auxil_spicy_hilti_toolchain_include_compiler_printer.h @@ -0,0 +1,11 @@ +--- auxil/spicy/hilti/toolchain/include/compiler/printer.h.orig 2026-05-12 18:14:47 UTC ++++ auxil/spicy/hilti/toolchain/include/compiler/printer.h +@@ -59,7 +59,7 @@ class Stream { (public) + Stream(std::ostream& s) : _stream(s) {} + + auto& state() const { +- assert(detail::State::current); ++ assert(detail::State::current.get()); + return *detail::State::current; + } + diff --git a/security/zeek/files/patch-auxil_spicy_hilti_toolchain_src_ast_ast-context.cc b/security/zeek/files/patch-auxil_spicy_hilti_toolchain_src_ast_ast-context.cc new file mode 100644 index 000000000000..be8f3ff70565 --- /dev/null +++ b/security/zeek/files/patch-auxil_spicy_hilti_toolchain_src_ast_ast-context.cc @@ -0,0 +1,11 @@ +--- auxil/spicy/hilti/toolchain/src/ast/ast-context.cc.orig 2026-05-12 18:14:47 UTC ++++ auxil/spicy/hilti/toolchain/src/ast/ast-context.cc +@@ -328,7 +328,7 @@ void ASTContext::garbageCollect() { + changed = false; + + for ( auto& n : _nodes ) { +- assert(n); ++ assert(n.get()); + + if ( n->isRetained() ) { + ++retained; diff --git a/security/zeek/files/patch-auxil_spicy_hilti_toolchain_src_compiler_driver.cc b/security/zeek/files/patch-auxil_spicy_hilti_toolchain_src_compiler_driver.cc new file mode 100644 index 000000000000..15ef25453916 --- /dev/null +++ b/security/zeek/files/patch-auxil_spicy_hilti_toolchain_src_compiler_driver.cc @@ -0,0 +1,20 @@ +--- auxil/spicy/hilti/toolchain/src/compiler/driver.cc.orig 2026-05-12 18:14:47 UTC ++++ auxil/spicy/hilti/toolchain/src/compiler/driver.cc +@@ -683,7 +683,7 @@ Result<Nothing> Driver::compileUnits() { + } + + Result<Nothing> Driver::compileUnits() { +- assert(_builder); ++ assert(_builder.get()); + + if ( auto rc = context()->astContext()->processAST(_builder.get(), this); ! rc ) { + // hilti::detail::printer::print(std::cerr, context()->astContext()->root()); +@@ -723,7 +723,7 @@ Result<Nothing> Driver::run() { + Result<Nothing> Driver::run() { + assert(! _builder); + initialize(); +- assert(_builder); ++ assert(_builder.get()); + + for ( const auto& i : _driver_options.inputs ) { + if ( auto rc = addInput(i); ! rc ) diff --git a/security/zeek/files/patch-auxil_spicy_spicy_runtime_include_configuration.h b/security/zeek/files/patch-auxil_spicy_spicy_runtime_include_configuration.h new file mode 100644 index 000000000000..500d7bce576a --- /dev/null +++ b/security/zeek/files/patch-auxil_spicy_spicy_runtime_include_configuration.h @@ -0,0 +1,11 @@ +--- auxil/spicy/spicy/runtime/include/configuration.h.orig 2026-05-12 18:14:47 UTC ++++ auxil/spicy/spicy/runtime/include/configuration.h +@@ -43,7 +43,7 @@ inline const Configuration& unsafeGet() { + * matters. + */ + inline const Configuration& unsafeGet() { +- assert(rt::detail::globalState()->configuration); ++ assert(rt::detail::globalState()->configuration.get()); + return *rt::detail::globalState()->configuration; + } + diff --git a/security/zeek/files/patch-auxil_spicy_spicy_runtime_src_sink.cc b/security/zeek/files/patch-auxil_spicy_spicy_runtime_src_sink.cc new file mode 100644 index 000000000000..b41dff63a260 --- /dev/null +++ b/security/zeek/files/patch-auxil_spicy_spicy_runtime_src_sink.cc @@ -0,0 +1,11 @@ +--- auxil/spicy/spicy/runtime/src/sink.cc.orig 2026-06-10 16:58:45 UTC ++++ auxil/spicy/spicy/runtime/src/sink.cc +@@ -431,7 +431,7 @@ void Sink::_close(bool orderly) { + fmt("error in connected unit %s during close (%s)", s->parser->name, err.what())); + } + +- assert(s->resumable); // must have conluded after freezing/aborting ++ assert(static_cast<bool>(s->resumable)); // must have conluded after freezing/aborting + } + } + diff --git a/security/zeek/files/patch-auxil_spicy_spicy_toolchain_include_compiler_detail_codegen_productions_while.h b/security/zeek/files/patch-auxil_spicy_spicy_toolchain_include_compiler_detail_codegen_productions_while.h new file mode 100644 index 000000000000..d6834009e69c --- /dev/null +++ b/security/zeek/files/patch-auxil_spicy_spicy_toolchain_include_compiler_detail_codegen_productions_while.h @@ -0,0 +1,11 @@ +--- auxil/spicy/spicy/toolchain/include/compiler/detail/codegen/productions/while.h.orig 2026-05-12 18:14:47 UTC ++++ auxil/spicy/spicy/toolchain/include/compiler/detail/codegen/productions/while.h +@@ -55,7 +55,7 @@ class While : public Production { (public) + * loop body. This method must be called only after `preprocessLookAhead()`. + */ + const production::LookAhead* lookAheadProduction() const { +- assert(_body_for_grammar); // set by preprocessLookAhead() return ++ assert(_body_for_grammar.get()); // set by preprocessLookAhead() return + return _body_for_grammar->as<production::LookAhead>(); + } + diff --git a/security/zeek/files/patch-auxil_spicy_spicy_toolchain_src_compiler_codegen_grammar-builder.cc b/security/zeek/files/patch-auxil_spicy_spicy_toolchain_src_compiler_codegen_grammar-builder.cc new file mode 100644 index 000000000000..8685ba0688c7 --- /dev/null +++ b/security/zeek/files/patch-auxil_spicy_spicy_toolchain_src_compiler_codegen_grammar-builder.cc @@ -0,0 +1,11 @@ +--- auxil/spicy/spicy/toolchain/src/compiler/codegen/grammar-builder.cc.orig 2026-05-12 18:14:47 UTC ++++ auxil/spicy/spicy/toolchain/src/compiler/codegen/grammar-builder.cc +@@ -354,7 +354,7 @@ hilti::Result<hilti::Nothing> GrammarBuilder::run(type + Grammar g(id.str(), unit->location()); + auto pf = ProductionFactory(cg(), this, &g); + auto root = pf.createProduction(unit); +- assert(root); ++ assert(root.get()); + + if ( auto rc = g.setRoot(std::move(root)); ! rc ) + return rc.error();home | help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?6a29bbd4.18b7e.33b7285b>
