diff --git a/Makefile.common b/Makefile.common index 1aa2604cae..c834ee9689 100644 --- a/Makefile.common +++ b/Makefile.common @@ -18,6 +18,10 @@ ifeq ($(HAVE_LIBRETRODB),) HAVE_LIBRETRODB = 1 endif +ifeq ($(HAVE_VIDEO_PROCESSOR), 1) + DEFINES += -DHAVE_VIDEO_PROCESSOR +endif + ifeq ($(HAVE_HID), 1) DEFINES += -DHAVE_HID endif @@ -1030,12 +1034,15 @@ endif # Video4Linux 2 ifeq ($(HAVE_V4L2),1) - OBJ += camera/drivers/video4linux2.o \ - cores/libretro-video-processor/video_processor_v4l2.o + OBJ += camera/drivers/video4linux2.o +ifeq ($(HAVE_VIDEO_PROCESSOR),1) + OBJ += cores/libretro-video-processor/video_processor_v4l2.o +endif DEFINES += -DHAVE_V4L2 LIBS += $(V4L2_LIBS) endif + # Things that depend on network availability ifeq ($(HAVE_NETWORKING), 1) diff --git a/dynamic.c b/dynamic.c index 434d67d0a2..cce6db3c6e 100644 --- a/dynamic.c +++ b/dynamic.c @@ -81,7 +81,7 @@ static dylib_t lib_handle; #define SYMBOL_NETRETROPAD(x) current_core->x = libretro_netretropad_##x #endif -#if defined(HAVE_V4L2) +#if defined(HAVE_VIDEO_PROCESSOR) #define SYMBOL_VIDEOPROCESSOR(x) current_core->x = libretro_videoprocessor_##x #endif @@ -550,7 +550,7 @@ static void load_symbols(enum rarch_core_type type, struct retro_core_t *current #endif break; case CORE_TYPE_VIDEOPROCESSOR: -#if defined(HAVE_NETWORKGAMEPAD) && defined(HAVE_NETPLAY) +#if defined(HAVE_VIDEO_PROCESSOR) SYMBOL_VIDEOPROCESSOR(retro_init); SYMBOL_VIDEOPROCESSOR(retro_deinit); diff --git a/griffin/griffin.c b/griffin/griffin.c index 00e500d314..fdd8031db8 100644 --- a/griffin/griffin.c +++ b/griffin/griffin.c @@ -530,10 +530,13 @@ CAMERA #endif #ifdef HAVE_V4L2 -#include "../cores/libretro-video-processor/video_processor_v4l2.c" #include "../camera/drivers/video4linux2.c" #endif +#ifdef HAVE_VIDEO_PROCESSOR +#include "../cores/libretro-video-processor/video_processor_v4l2.c" +#endif + #include "../camera/drivers/nullcamera.c" /*============================================================ diff --git a/qb/config.libs.sh b/qb/config.libs.sh index 06efe16937..99a2c6ddf1 100644 --- a/qb/config.libs.sh +++ b/qb/config.libs.sh @@ -445,6 +445,10 @@ if [ "$HAVE_THREADS" = 'no' ] && [ "HAVE_LIBUSB" != 'no' ]; then echo "Notice: Threads are not available, libusb will also be disabled." fi +if [ "$HAVE_V4L2" != 'no' ]; then + HAVE_VIDEO_PROCESSOR=yes +fi + # Creates config.mk and config.h. add_define_make GLOBAL_CONFIG_DIR "$GLOBAL_CONFIG_DIR" VARS=$(eval set | grep ^HAVE_ | sed s/=.*// | sed s/^HAVE_//)