- Fix build on 7.X
Submitted by: maintainer
This commit is contained in:
parent
c97fe5c631
commit
88fce9020b
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=270671
@ -36,6 +36,11 @@ CFLAGS+= -DHAVE_LINUX_INTEGER_TYPES
|
||||
|
||||
.include <bsd.port.pre.mk>
|
||||
|
||||
# add strnlen(3) from head/lib/libc/string/strnlen.c
|
||||
.if ${OSVERSION} < 800067
|
||||
EXTRA_PATCHES+= ${PATCHDIR}/extra-patch-va-va_trace.c
|
||||
.endif
|
||||
|
||||
.if !defined(WITH_DEBUG)
|
||||
CFLAGS+= -DNDEBUG
|
||||
.else
|
||||
|
20
multimedia/libva/files/extra-patch-va-va_trace.c
Normal file
20
multimedia/libva/files/extra-patch-va-va_trace.c
Normal file
@ -0,0 +1,20 @@
|
||||
--- va/va_trace.c~
|
||||
+++ va/va_trace.c
|
||||
@@ -140,6 +140,17 @@ VAStatus vaUnlockSurface(VADisplay dpy,
|
||||
VASurfaceID surface
|
||||
);
|
||||
|
||||
+static size_t
|
||||
+strnlen(const char *s, size_t maxlen)
|
||||
+{
|
||||
+ size_t len;
|
||||
+
|
||||
+ for (len = 0; len < maxlen; len++, s++) {
|
||||
+ if (!*s)
|
||||
+ break;
|
||||
+ }
|
||||
+ return (len);
|
||||
+}
|
||||
|
||||
void va_TraceInit(VADisplay dpy)
|
||||
{
|
Loading…
Reference in New Issue
Block a user