mirror of
https://github.com/MiyooCFW/buildroot.git
synced 2025-09-27 22:24:19 +03:00
Merge from bittboy/buildroot@db180c0
This commit is contained in:
@@ -0,0 +1,44 @@
|
||||
From e5952b043a71fe83fbc392e498e8f77774fca0d8 Mon Sep 17 00:00:00 2001
|
||||
From: Peter Korsgaard <jacmet@sunsite.dk>
|
||||
Date: Sat, 28 Jun 2014 09:32:53 -0300
|
||||
Subject: [PATCH] fixup lfs mismatch in preload libraries
|
||||
|
||||
Ensure that the lfs variants are not transparently used instead of the !lfs
|
||||
ones so both can be wrapped, independently of any custom CFLAGS/CPPFLAGS.
|
||||
|
||||
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
|
||||
---
|
||||
lib/libv4l1/v4l1compat.c | 3 +++
|
||||
lib/libv4l2/v4l2convert.c | 3 +++
|
||||
2 files changed, 6 insertions(+)
|
||||
|
||||
diff --git a/lib/libv4l1/v4l1compat.c b/lib/libv4l1/v4l1compat.c
|
||||
index e328288..70eb74f 100644
|
||||
--- a/lib/libv4l1/v4l1compat.c
|
||||
+++ b/lib/libv4l1/v4l1compat.c
|
||||
@@ -19,6 +19,9 @@
|
||||
# Foundation, Inc., 51 Franklin Street, Suite 500, Boston, MA 02110-1335 USA
|
||||
*/
|
||||
|
||||
+/* ensure we see *64 variants and they aren't transparently used */
|
||||
+#undef _LARGEFILE_SOURCE
|
||||
+#undef _FILE_OFFSET_BITS
|
||||
#define _LARGEFILE64_SOURCE 1
|
||||
|
||||
#include <config.h>
|
||||
diff --git a/lib/libv4l2/v4l2convert.c b/lib/libv4l2/v4l2convert.c
|
||||
index 9b46ab8..bc41056 100644
|
||||
--- a/lib/libv4l2/v4l2convert.c
|
||||
+++ b/lib/libv4l2/v4l2convert.c
|
||||
@@ -23,6 +23,9 @@
|
||||
/* prevent GCC 4.7 inlining error */
|
||||
#undef _FORTIFY_SOURCE
|
||||
|
||||
+/* ensure we see *64 variants and they aren't transparently used */
|
||||
+#undef _LARGEFILE_SOURCE
|
||||
+#undef _FILE_OFFSET_BITS
|
||||
#define _LARGEFILE64_SOURCE 1
|
||||
|
||||
#include <config.h>
|
||||
--
|
||||
1.9.1
|
||||
@@ -0,0 +1,35 @@
|
||||
From 663b7be9d27c979c914011a3ce707e227987bc59 Mon Sep 17 00:00:00 2001
|
||||
From: Peter Seiderer <ps.report@gmx.net>
|
||||
Date: Sat, 3 Feb 2018 22:47:18 +0100
|
||||
Subject: [PATCH] keytable: fix EVIOCSCLOCKID related compile failure
|
||||
|
||||
Fixes:
|
||||
|
||||
keytable.c: In function 'test_event':
|
||||
keytable.c:1351:12: error: 'EVIOCSCLOCKID' undeclared (first use in this function)
|
||||
ioctl(fd, EVIOCSCLOCKID, &mode);
|
||||
^~~~~~~~~~~~~
|
||||
|
||||
Signed-off-by: Peter Seiderer <ps.report@gmx.net>
|
||||
---
|
||||
utils/keytable/keytable.c | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/utils/keytable/keytable.c b/utils/keytable/keytable.c
|
||||
index 34a1522e..925eab00 100644
|
||||
--- a/utils/keytable/keytable.c
|
||||
+++ b/utils/keytable/keytable.c
|
||||
@@ -55,6 +55,10 @@ struct input_keymap_entry_v2 {
|
||||
u_int8_t scancode[32];
|
||||
};
|
||||
|
||||
+#ifndef EVIOCSCLOCKID
|
||||
+#define EVIOCSCLOCKID _IOW('E', 0xa0, int)
|
||||
+#endif
|
||||
+
|
||||
#ifndef EVIOCGKEYCODE_V2
|
||||
#define EVIOCGKEYCODE_V2 _IOR('E', 0x04, struct input_keymap_entry_v2)
|
||||
#define EVIOCSKEYCODE_V2 _IOW('E', 0x04, struct input_keymap_entry_v2)
|
||||
--
|
||||
2.16.1
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
From 5c407e130f8d0416f91f5a12bcdc2709f00dda65 Mon Sep 17 00:00:00 2001
|
||||
From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
|
||||
Date: Fri, 29 Jun 2018 21:15:10 +0200
|
||||
Subject: [PATCH] Build sdlcam only if jpeg is enabled
|
||||
|
||||
Fixes:
|
||||
- http://autobuild.buildroot.net/results/1eded8b44cc369550566c6ce0b3c042f1aec8d44
|
||||
|
||||
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
|
||||
---
|
||||
contrib/test/Makefile.am | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/contrib/test/Makefile.am b/contrib/test/Makefile.am
|
||||
index 0188fe21..c7c38e7a 100644
|
||||
--- a/contrib/test/Makefile.am
|
||||
+++ b/contrib/test/Makefile.am
|
||||
@@ -17,8 +17,10 @@ noinst_PROGRAMS += v4l2gl
|
||||
endif
|
||||
|
||||
if HAVE_SDL
|
||||
+if HAVE_JPEG
|
||||
noinst_PROGRAMS += sdlcam
|
||||
endif
|
||||
+endif
|
||||
|
||||
driver_test_SOURCES = driver-test.c
|
||||
driver_test_LDADD = ../../utils/libv4l2util/libv4l2util.la
|
||||
--
|
||||
2.14.1
|
||||
|
||||
76
package/libv4l/0004-v4l2-compliance-needs-fork.patch
Normal file
76
package/libv4l/0004-v4l2-compliance-needs-fork.patch
Normal file
@@ -0,0 +1,76 @@
|
||||
From 21d7082c635433176aebcd9d6f0177edb059f41f Mon Sep 17 00:00:00 2001
|
||||
From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
|
||||
Date: Sat, 17 Nov 2018 21:26:57 +0100
|
||||
Subject: [PATCH] v4l2-compliance needs fork
|
||||
|
||||
v4l2-compliance uses fork, since
|
||||
https://git.linuxtv.org/v4l-utils.git/commit/utils/v4l2-compliance/?id=79d98edd1a27233667a6bc38d3d7f8958c2ec02c
|
||||
|
||||
So don't build it if fork is not available
|
||||
|
||||
Fixes:
|
||||
- http://autobuild.buildroot.org/results/447d792ce21c0e33a36ca9384fee46e099435ed8
|
||||
|
||||
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
|
||||
---
|
||||
configure.ac | 5 ++++-
|
||||
utils/Makefile.am | 6 +++++-
|
||||
2 files changed, 9 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 5cc34c24..52ea5c6d 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -478,7 +478,8 @@ AM_CONDITIONAL([WITH_QTGL], [test x${qt_pkgconfig_gl} = xtrue])
|
||||
AM_CONDITIONAL([WITH_GCONV], [test x$enable_gconv = xyes -a x$enable_shared == xyes -a x$with_gconvdir != x -a -f $with_gconvdir/gconv-modules])
|
||||
AM_CONDITIONAL([WITH_V4L2_CTL_LIBV4L], [test x${enable_v4l2_ctl_libv4l} != xno])
|
||||
AM_CONDITIONAL([WITH_V4L2_CTL_STREAM_TO], [test x${enable_v4l2_ctl_stream_to} != xno])
|
||||
-AM_CONDITIONAL([WITH_V4L2_COMPLIANCE_LIBV4L], [test x${enable_v4l2_compliance_libv4l} != xno])
|
||||
+AM_CONDITIONAL([WITH_V4L2_COMPLIANCE], [test x$ac_cv_func_fork = xyes])
|
||||
+AM_CONDITIONAL([WITH_V4L2_COMPLIANCE_LIBV4L], [test x$ac_cv_func_fork = xyes -a x${enable_v4l2_compliance_libv4l} != xno])
|
||||
AM_CONDITIONAL([WITH_BPF], [test x$enable_bpf != xno -a x$libelf_pkgconfig = xyes -a x$CLANG = xclang])
|
||||
|
||||
# append -static to libtool compile and link command to enforce static libs
|
||||
@@ -509,6 +510,7 @@ AM_COND_IF([WITH_V4L_PLUGINS], [USE_V4L_PLUGINS="yes"
|
||||
AM_COND_IF([WITH_V4L_WRAPPERS], [USE_V4L_WRAPPERS="yes"], [USE_V4L_WRAPPERS="no"])
|
||||
AM_COND_IF([WITH_GCONV], [USE_GCONV="yes"], [USE_GCONV="no"])
|
||||
AM_COND_IF([WITH_V4L2_CTL_LIBV4L], [USE_V4L2_CTL_LIBV4L="yes"], [USE_V4L2_CTL_LIBV4L="no"])
|
||||
+AM_COND_IF([WITH_V4L2_COMPLIANCE], [USE_V4L2_COMPLIANCE="yes"], [USE_V4L2_COMPLIANCE="no"])
|
||||
AM_COND_IF([WITH_V4L2_COMPLIANCE_LIBV4L], [USE_V4L2_COMPLIANCE_LIBV4L="yes"], [USE_V4L2_COMPLIANCE_LIBV4L="no"])
|
||||
AM_COND_IF([WITH_BPF], [USE_BPF="yes"
|
||||
AC_DEFINE([HAVE_BPF], [1], [BPF IR decoder support enabled])],
|
||||
@@ -556,6 +558,7 @@ compile time options summary
|
||||
qv4l2 : $USE_QV4L2
|
||||
qvidcap : $USE_QVIDCAP
|
||||
v4l2-ctl uses libv4l : $USE_V4L2_CTL_LIBV4L
|
||||
+ v4l2-compliance : $USE_V4L2_COMPLIANCE
|
||||
v4l2-compliance uses libv4l: $USE_V4L2_COMPLIANCE_LIBV4L
|
||||
BPF IR Decoders: : $USE_BPF
|
||||
EOF
|
||||
diff --git a/utils/Makefile.am b/utils/Makefile.am
|
||||
index 2d507028..9c29926a 100644
|
||||
--- a/utils/Makefile.am
|
||||
+++ b/utils/Makefile.am
|
||||
@@ -6,7 +6,6 @@ SUBDIRS = \
|
||||
cx18-ctl \
|
||||
keytable \
|
||||
media-ctl \
|
||||
- v4l2-compliance \
|
||||
v4l2-ctl \
|
||||
v4l2-dbg \
|
||||
v4l2-sysfs-path \
|
||||
@@ -20,6 +19,11 @@ SUBDIRS += \
|
||||
dvb
|
||||
endif
|
||||
|
||||
+if WITH_V4L2_COMPLIANCE
|
||||
+SUBDIRS += \
|
||||
+ v4l2-compliance
|
||||
+endif
|
||||
+
|
||||
if WITH_QV4L2
|
||||
SUBDIRS += qv4l2
|
||||
endif
|
||||
--
|
||||
2.17.1
|
||||
|
||||
42
package/libv4l/Config.in
Normal file
42
package/libv4l/Config.in
Normal file
@@ -0,0 +1,42 @@
|
||||
config BR2_PACKAGE_LIBV4L
|
||||
bool "libv4l"
|
||||
depends on BR2_TOOLCHAIN_HAS_THREADS
|
||||
depends on BR2_INSTALL_LIBSTDCPP
|
||||
depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_0 # media headers
|
||||
select BR2_PACKAGE_ARGP_STANDALONE if BR2_TOOLCHAIN_USES_UCLIBC || BR2_TOOLCHAIN_USES_MUSL
|
||||
select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
|
||||
help
|
||||
libv4l is a collection of libraries which adds a thin
|
||||
abstraction layer on top of video4linux2 devices. libv4l
|
||||
consists of 3 different libraries: libv4lconvert, libv4l1 and
|
||||
libv4l2.
|
||||
|
||||
http://linuxtv.org/wiki/index.php/V4l-utils
|
||||
|
||||
if BR2_PACKAGE_LIBV4L
|
||||
|
||||
comment "libv4l JPEG support not enabled"
|
||||
depends on !BR2_PACKAGE_JPEG
|
||||
|
||||
config BR2_PACKAGE_LIBV4L_UTILS
|
||||
bool "v4l-utils tools"
|
||||
help
|
||||
v4l-utils is a collection of various video4linux and DVB
|
||||
utilities.
|
||||
Enable this if you want to build the following tools:
|
||||
- cx18-ctl
|
||||
- dvb-fe-tool, dvbv5-zap, dvbv5-scan, dvb-format-convert
|
||||
- decode_tm6000
|
||||
- ir-keytable
|
||||
- media-ctl
|
||||
- v4l2-compliance
|
||||
- v4l2-ctl, cx18-ctl, ivtv-ctl
|
||||
- v4l2-sysfs-path
|
||||
- rds-ctl
|
||||
- qv4l2 (if Qt is enabled)
|
||||
|
||||
endif
|
||||
|
||||
comment "libv4l needs a toolchain w/ threads, C++ and headers >= 3.0"
|
||||
depends on !BR2_TOOLCHAIN_HAS_THREADS \
|
||||
|| !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_0
|
||||
7
package/libv4l/libv4l.hash
Normal file
7
package/libv4l/libv4l.hash
Normal file
@@ -0,0 +1,7 @@
|
||||
# Locally calculated after checking signature
|
||||
# https://linuxtv.org/downloads/v4l-utils/v4l-utils-1.16.5.tar.bz2.asc
|
||||
sha256 ed80242510385017a1dc566e17a285a77222bb301f5bc19386badfcc2c19df1b v4l-utils-1.16.5.tar.bz2
|
||||
# Locally calculated
|
||||
sha256 391e4da1c54a422a78d83be7bf84b2dfb8bacdd8ad256fa4374e128655584a8a COPYING
|
||||
sha256 5a7f623a50e384aaf6d2ced068339ddf93d0a50d3a0ecbe86f125b07804ecc78 COPYING.libv4l
|
||||
sha256 34229b5aadfb768d0d083987cba54203a920904a3ec8320823c6125b9831acd1 lib/libv4l1/libv4l1-kernelcode-license.txt
|
||||
89
package/libv4l/libv4l.mk
Normal file
89
package/libv4l/libv4l.mk
Normal file
@@ -0,0 +1,89 @@
|
||||
################################################################################
|
||||
#
|
||||
# libv4l
|
||||
#
|
||||
################################################################################
|
||||
|
||||
LIBV4L_VERSION = 1.16.5
|
||||
LIBV4L_SOURCE = v4l-utils-$(LIBV4L_VERSION).tar.bz2
|
||||
LIBV4L_SITE = https://linuxtv.org/downloads/v4l-utils
|
||||
LIBV4L_INSTALL_STAGING = YES
|
||||
LIBV4L_DEPENDENCIES = host-pkgconf
|
||||
LIBV4L_CONF_OPTS = --disable-doxygen-doc --disable-qvidcap
|
||||
# We're patching contrib/test/Makefile.am
|
||||
LIBV4L_AUTORECONF = YES
|
||||
# add host-gettext for AM_ICONV macro
|
||||
LIBV4L_DEPENDENCIES += host-gettext
|
||||
|
||||
# fix uclibc-ng configure/compile
|
||||
LIBV4L_CONF_ENV = ac_cv_prog_cc_c99='-std=gnu99'
|
||||
|
||||
# v4l-utils components have different licences, see v4l-utils.spec for details
|
||||
LIBV4L_LICENSE = GPL-2.0+ (utilities), LGPL-2.1+ (libraries)
|
||||
LIBV4L_LICENSE_FILES = COPYING COPYING.libv4l lib/libv4l1/libv4l1-kernelcode-license.txt
|
||||
|
||||
ifeq ($(BR2_PACKAGE_ALSA_LIB),y)
|
||||
LIBV4L_DEPENDENCIES += alsa-lib
|
||||
endif
|
||||
|
||||
ifeq ($(BR2_PACKAGE_ARGP_STANDALONE),y)
|
||||
LIBV4L_DEPENDENCIES += argp-standalone
|
||||
LIBV4L_LIBS += -largp
|
||||
endif
|
||||
|
||||
LIBV4L_DEPENDENCIES += $(if $(BR2_PACKAGE_LIBICONV),libiconv)
|
||||
|
||||
ifeq ($(BR2_PACKAGE_JPEG),y)
|
||||
LIBV4L_DEPENDENCIES += jpeg
|
||||
LIBV4L_CONF_OPTS += --with-jpeg
|
||||
else
|
||||
LIBV4L_CONF_OPTS += --without-jpeg
|
||||
endif
|
||||
|
||||
ifeq ($(BR2_PACKAGE_HAS_LIBGL),y)
|
||||
LIBV4L_DEPENDENCIES += libgl
|
||||
endif
|
||||
|
||||
ifeq ($(BR2_PACKAGE_HAS_UDEV),y)
|
||||
LIBV4L_CONF_OPTS += --with-udevdir=/usr/lib/udev
|
||||
LIBV4L_DEPENDENCIES += udev
|
||||
endif
|
||||
|
||||
ifeq ($(BR2_PACKAGE_LIBGLU),y)
|
||||
LIBV4L_DEPENDENCIES += libglu
|
||||
endif
|
||||
|
||||
ifeq ($(BR2_PACKAGE_LIBV4L_UTILS),y)
|
||||
LIBV4L_CONF_OPTS += --enable-v4l-utils
|
||||
LIBV4L_DEPENDENCIES += $(TARGET_NLS_DEPENDENCIES)
|
||||
|
||||
# IR BPF decoder support needs toolchain with linux-headers >= 3.18
|
||||
# libelf and clang support
|
||||
LIBV4L_CONF_OPTS += --disable-bpf
|
||||
|
||||
ifeq ($(BR2_PACKAGE_QT5BASE)$(BR2_PACKAGE_QT5BASE_GUI)$(BR2_PACKAGE_QT5BASE_WIDGETS),yyy)
|
||||
LIBV4L_CONF_OPTS += --enable-qv4l2
|
||||
LIBV4L_DEPENDENCIES += qt5base
|
||||
# protect against host version detection of moc-qt5/rcc-qt5/uic-qt5
|
||||
LIBV4L_CONF_ENV += \
|
||||
ac_cv_prog_MOC=$(HOST_DIR)/bin/moc \
|
||||
ac_cv_prog_RCC=$(HOST_DIR)/bin/rcc \
|
||||
ac_cv_prog_UIC=$(HOST_DIR)/bin/uic
|
||||
# qt5 needs c++11 (since qt-5.7)
|
||||
ifeq ($(BR2_PACKAGE_QT5_VERSION_LATEST),y)
|
||||
LIBV4L_CONF_ENV += CXXFLAGS="$(TARGET_CXXFLAGS) -std=c++11"
|
||||
endif
|
||||
else
|
||||
LIBV4L_CONF_OPTS += --disable-qv4l2
|
||||
endif
|
||||
else
|
||||
LIBV4L_CONF_OPTS += --disable-v4l-utils
|
||||
endif
|
||||
|
||||
ifeq ($(BR2_PACKAGE_SDL2_IMAGE),y)
|
||||
LIBV4L_DEPENDENCIES += sdl2_image
|
||||
endif
|
||||
|
||||
LIBV4L_CONF_ENV += LIBS="$(LIBV4L_LIBS)"
|
||||
|
||||
$(eval $(autotools-package))
|
||||
Reference in New Issue
Block a user