svn commit: r382525 - head/multimedia/v4l-utils/files
Juergen Lock
nox at FreeBSD.org
Sat Mar 28 17:17:33 UTC 2015
Author: nox
Date: Sat Mar 28 17:17:32 2015
New Revision: 382525
URL: https://svnweb.freebsd.org/changeset/ports/382525
QAT: https://qat.redports.org/buildarchive/r382525/
Log:
Fix build on 8 and 9.
Submitted by: beefy1 via pkg-fallout
Modified:
head/multimedia/v4l-utils/files/patch-v4l2-ctl__v4l2-ctl.cpp
Modified: head/multimedia/v4l-utils/files/patch-v4l2-ctl__v4l2-ctl.cpp
==============================================================================
--- head/multimedia/v4l-utils/files/patch-v4l2-ctl__v4l2-ctl.cpp Sat Mar 28 16:50:00 2015 (r382524)
+++ head/multimedia/v4l-utils/files/patch-v4l2-ctl__v4l2-ctl.cpp Sat Mar 28 17:17:32 2015 (r382525)
@@ -1,5 +1,5 @@
---- v4l2-ctl/v4l2-ctl.cpp.orig 2012-04-14 19:33:44.000000000 +0200
-+++ v4l2-ctl/v4l2-ctl.cpp 2015-03-17 21:05:27.176219337 +0100
+--- v4l2-ctl/v4l2-ctl.cpp.orig
++++ v4l2-ctl/v4l2-ctl.cpp
@@ -21,7 +21,6 @@
*/
@@ -16,10 +16,29 @@
#include <linux/videodev2.h>
#include <libv4l2.h>
-@@ -1643,10 +1641,31 @@
- printf("%s\n", iter->second.c_str());
+@@ -1644,9 +1642,50 @@ static void list_devices()
}
}
+
++#if __FreeBSD_version < 1000000
++/* from FreeBSD src/lib/libc/string/strchrnul.c: */
++
++char *strchrnul(const char *p, int ch);
++
++char *
++strchrnul(const char *p, int ch)
++{
++ char c;
++
++ c = ch;
++ for (;; ++p) {
++ if (*p == c || *p == '\0')
++ return ((char *)p);
++ }
++ /* NOTREACHED */
++}
++#endif
++
+int
+my_getsubopt (char **optionp, char *const *tokens, char **valuep)
+{
@@ -41,7 +60,7 @@
+
+ return -1;
+}
-
++
static int parse_subopt(char **subs, const char * const *subopts, char **value)
{
- int opt = getsubopt(subs, (char * const *)subopts, value);
@@ -49,7 +68,7 @@
if (opt == -1) {
fprintf(stderr, "Invalid suboptions specified\n");
-@@ -1667,7 +1686,7 @@
+@@ -1667,7 +1704,7 @@ static void parse_next_subopt(char **sub
static char *const subopts[] = {
NULL
};
@@ -58,7 +77,7 @@
if (value == NULL) {
fprintf(stderr, "No value given to suboption <%s>\n",
-@@ -3493,6 +3512,7 @@
+@@ -3493,6 +3530,7 @@ int main(int argc, char **argv)
static char buf[40960];
int len;
@@ -66,7 +85,7 @@
if (doioctl(fd, VIDIOC_LOG_STATUS, NULL) == 0) {
printf("\nStatus Log:\n\n");
len = klogctl(3, buf, sizeof(buf) - 1);
-@@ -3514,6 +3534,7 @@
+@@ -3514,6 +3552,7 @@ int main(int argc, char **argv)
}
}
}
More information about the svn-ports-all
mailing list