Since clang 16 (and gcc 11) the default C++ standard is now gnu++17. Because multimedia/vdr's Makefile does not explicitly set its C++ standard, this leads to an error: util.c:269:4: error: ISO C++17 does not allow 'register' storage class specifier [-Wregister] register int i; ^~~~~~~~~ Because the port's own Makefile is rather non-standard it does not respect USE_CXXSTD=, so patch away the 'register' keyword instead.
Created attachment 242479 [details] multimedia/vdr: fix build with clang 16
^Triage: reporter is committer, assign accordingly
(In reply to Fernando Apesteguía from comment #2) Since this port does not seem to have a maintainer, can I just commit the fix? :)
(In reply to Dimitry Andric from comment #3) Yes :-) Any committer may commit to any repository with an accepted review from any committer with existing access to that repository. Committers may obtain review via a Differential in Phabricator, adding the "Contributor Reviewers ($Repository)" group as a Reviewer, reaching out to other committers; directly or via mailing lists, or setting the attachment flag to: maintainer-approval ? <person-youd-like-to-review> So here is my thumbs up: LGTM!
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=83a6aff27701c52b445db12baee2a98c8cfd4135 commit 83a6aff27701c52b445db12baee2a98c8cfd4135 Author: Dimitry Andric <dim@FreeBSD.org> AuthorDate: 2023-05-29 14:09:31 +0000 Commit: Dimitry Andric <dim@FreeBSD.org> CommitDate: 2023-06-04 16:21:24 +0000 multimedia/vdr: fix build with clang 16 Since clang 16 (and gcc 11) the default C++ standard is now gnu++17. Because multimedia/vdr's Makefile does not explicitly set its C++ standard, this leads to an error: util.c:269:4: error: ISO C++17 does not allow 'register' storage class specifier [-Wregister] register int i; ^~~~~~~~~ Because the port's own Makefile is rather non-standard it does not respect USE_CXXSTD=, so patch away the 'register' keyword instead. PR: 271707 Approved by: fernape MFH: 2023Q2 multimedia/vdr/Makefile | 2 +- multimedia/vdr/files/patch-libsi_util.c (new) | 11 +++++++++++ 2 files changed, 12 insertions(+), 1 deletion(-)