Re: [MacPorts] #70170: ctpv @1.1: error: expected ‘;’, ‘,’ or ‘)’ before ‘__VA_OPT__’
MacPorts
noreply at macports.org
Sat Oct 12 20:05:28 UTC 2024
#70170: ctpv @1.1: error: expected ‘;’, ‘,’ or ‘)’ before ‘__VA_OPT__’
---------------------------+-------------------------
Reporter: barracuda156 | Owner: suhailskhan
Type: defect | Status: reopened
Priority: Normal | Milestone:
Component: ports | Version: 2.9.3
Resolution: | Keywords:
Port: ctpv |
---------------------------+-------------------------
Comment (by suhailskhan):
Replying to [comment:11 barracuda156]:
> If it uses modern C++ specifically, then portfile must have
`compiler.cxx_standard`, blacklist won’t work correctly (since C++
standard does more than compiler choice).
For what it’s worth, ctpv is a pure C-based project, but `__VA_OPT__`
happens to be a C++20 feature as well as a C23 one. This is why
`compiler.cxx_standard 2020` is valid despite the source code not having
any C++. It still achieves the desired end result of ensuring only
compilers that support `__VA_OPT__` are used.
It appears that MacPorts currently does not recognize `compiler.c_standard
2023` yet because C23 is still very recent, so using that in the Portfile
will make it fall back to `compiler.c_standard 2017` instead, if I am not
mistaken.
--
Ticket URL: <https://trac.macports.org/ticket/70170#comment:13>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list