Index | Thread | Search

From:
Stuart Henderson <stu@spacehopper.org>
Subject:
Re: Merge devel/clang-tools-extra into devel/llvm/22
To:
Rafael Sadowski <rafael@sizeofvoid.org>, ports@openbsd.org, Anton Lindqvist <anton@basename.se>, Laurent Cheylus <foxy@free.fr>, "Kirill A. Korinsky" <kirill@korins.ky>, tb@openbsd.org, robert@openbsd.org
Date:
Tue, 23 Jun 2026 07:47:50 +0100

Download raw body.

Thread
> >  COMMENT-python =	Python bindings for Clang
> > +COMMENT-tools-extra =	Clang extra tools
> 
> Have you considered using just -tools as the suffix for the Makefile
> variables and package name?  It would make the names shorter and just
> as clear I think.  Anyway, I don't feel strongly about it!

yes, please.

> > +BUILD_CLANG_TOOLS_EXTRA ?= No

there is a standard mechanism for turning on/off subpackages.
they should be included  MULTI_PACKAGES unconditionally, and use
the no_xx pseudo-flavour mechanism, something like this:

PSEUDO_FLAVORS += no_tools
...
.include <bsd.port.arch.mk>
.if ${BUILD_PACKAGES:Mtools}
CLANG_TOOLS_EXTRA_PROJ = ;clang-tools-extra
.endif

bsd.port.mk(5) advises that "dpb(1) will break if all subpackages are
not properly listed". (I think that's a "may" rather than an "if" but
still..)

(in cases where DEBUG_PACKAGES is used, bsd.port.arch.mk must not be
included until _after_ DEBUG_PACKAGES has been defined).

> >  # BUILD_LLDB is defined by /usr/share/mk/bsd.own.mk
> >  .if ${BUILD_LLDB:L} == yes

it would be nice if this also used the no_xx mechanism e.g.

PSEUDO_FLAVORS += no_lldb
.if ${BUILD_LLDB:L} != yes
FLAVORS += no_lldb
.endif

this way you can build w/o lldb manually on an arch that normally
has it (which is useful for checking/fixing up PLISTs)

> > -MULTI_PACKAGES ?=	-main -python -lldb ${LIBCPP_PACKAGE}
> > -PROJECTS ?=		clang;lld;lldb
> > +MULTI_PACKAGES ?=	-main -python -lldb ${LIBCPP_PACKAGE} \

what's going on here, why is this not just -libcxx?