tech-pkg archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: C++20 and gcc12/10
* On 2025-04-04 at 02:17 BST, David Holland wrote:
Is it reasonable to commit
-USE_CXX_FEATURES= c++20
+# gcc10's C++20 support seems to be adequate and since an explicit
+# requirement of C++20 requires building gcc12 on 10.x and elsewhere,
+# hold off on the stricter constraint for now.
+#USE_CXX_FEATURES= c++20
+GCC_REQD+= 10
in packages where it works? It's easy enough to put back the stronger
constraint if the build stops working.
No, this belongs in infrastructure. A package should only have to
declare what it needs in terms of compiler support, not have OS-specific
hacks spread across them. Since adding support for *_FEATURES there
shouldn't be any GCC_REQD in packages.
(Or would it be better to add a new CXX_FEATURE for this, like
c++20-gcc10 or something? I am not at all clear on how any of this
interacts with clang.)
What needs to happen is these NetBSD-specific hacks need to move to
mk/platform/NetBSD.mk. gcc.mk should contain what is correct for gcc,
and then if there are hacky workarounds required to try and avoid those
requirements to retain the ability to use the system compiler then they
are overridden there, without affecting anyone else.
Also, if only specific parts of c++20 are required and they would be
satisfied by GCC 10.x then they should be newly added to
USE_CXX_FEATURES and handled appropriately.
--
Jonathan Perkin pkgsrc.smartos.org
Open Source Complete Cloud www.tritondatacenter.com
Home |
Main Index |
Thread Index |
Old Index