git: 83a6aff27701 - main - multimedia/vdr: fix build with clang 16
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 04 Jun 2023 16:21:59 UTC
The branch main has been updated by dim:
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 | 11 +++++++++++
2 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/multimedia/vdr/Makefile b/multimedia/vdr/Makefile
index c52c5db8d5e9..168b605108bc 100644
--- a/multimedia/vdr/Makefile
+++ b/multimedia/vdr/Makefile
@@ -1,6 +1,6 @@
PORTNAME= vdr
PORTVERSION= 1.7.29
-PORTREVISION= 15
+PORTREVISION= 16
CATEGORIES= multimedia
MASTER_SITES= ftp://ftp.tvdr.de/vdr/Developer/
DIST_SUBDIR= vdr
diff --git a/multimedia/vdr/files/patch-libsi_util.c b/multimedia/vdr/files/patch-libsi_util.c
new file mode 100644
index 000000000000..8a68685edff1
--- /dev/null
+++ b/multimedia/vdr/files/patch-libsi_util.c
@@ -0,0 +1,11 @@
+--- libsi/util.c.orig 2006-02-18 11:17:50 UTC
++++ libsi/util.c
+@@ -266,7 +266,7 @@ u_int32_t CRC32::crc32 (const char *d, int len, u_int3
+
+ u_int32_t CRC32::crc32 (const char *d, int len, u_int32_t crc)
+ {
+- register int i;
++ int i;
+ const unsigned char *u=(unsigned char*)d; // Saves '& 0xff'
+
+ for (i=0; i<len; i++)