[vlc-devel] [PATCH] video_output && video_filter: fix missing OPENGL_COMMONCFLAGS for some plugins
Zhao Zhili
quinkblack at foxmail.com
Mon Jan 6 10:48:07 UTC 2025
From: Zhao Zhili <zhilizhao at tencent.com>
These plugins include libplacebo header directly or indirectly.
Without OPENGL_COMMONCFLAGS, they can failed to build when libplacebo
headers aren't installed at the default search path.
---
modules/video_filter/Makefile.am | 5 +++--
modules/video_output/Makefile.am | 6 +++---
2 files changed, 6 insertions(+), 5 deletions(-)
diff --git a/modules/video_filter/Makefile.am b/modules/video_filter/Makefile.am
index c9bc4dc0e2..55da983c18 100644
--- a/modules/video_filter/Makefile.am
+++ b/modules/video_filter/Makefile.am
@@ -129,11 +129,12 @@ video_filter_LTLIBRARIES += libci_filters_plugin.la
endif
libopengl_filter_plugin_la_SOURCES = video_filter/opengl.c
+libopengl_filter_plugin_la_CFLAGS = $(OPENGL_COMMONCFLAGS)
if HAVE_LINUX
if HAVE_ANDROID
libopengl_filter_plugin_la_LIBADD = libvlc_opengles.la
-libopengl_filter_plugin_la_CFLAGS = -DUSE_OPENGL_ES2=1
+libopengl_filter_plugin_la_CFLAGS += -DUSE_OPENGL_ES2=1
video_filter_LTLIBRARIES += libopengl_filter_plugin.la
else
libopengl_filter_plugin_la_LIBADD = libvlc_opengl.la
@@ -145,7 +146,7 @@ endif
if HAVE_IOS_OR_TVOS
libopengl_filter_plugin_la_LIBADD = libvlc_opengles.la
-libopengl_filter_plugin_la_CFLAGS = -DUSE_OPENGL_ES2=1
+libopengl_filter_plugin_la_CFLAGS += -DUSE_OPENGL_ES2=1
video_filter_LTLIBRARIES += libopengl_filter_plugin.la
endif
diff --git a/modules/video_output/Makefile.am b/modules/video_output/Makefile.am
index 844b0dd01c..02e33599a6 100644
--- a/modules/video_output/Makefile.am
+++ b/modules/video_output/Makefile.am
@@ -62,7 +62,7 @@ libwindow_macosx_plugin_la_OBJCFLAGS = $(AM_OBJCFLAGS) \
libvout_macosx_plugin_la_SOURCES = video_output/macosx.m \
$(OPENGL_VOUT_COMMONSOURCES)
-libvout_macosx_plugin_la_OBJCFLAGS = $(AM_OBJCFLAGS) -fobjc-arc
+libvout_macosx_plugin_la_OBJCFLAGS = $(AM_OBJCFLAGS) $(OPENGL_COMMONCFLAGS) -fobjc-arc
libvout_macosx_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) -DHAVE_GL_CORE_SYMBOLS -DGL_SILENCE_DEPRECATION
libvout_macosx_plugin_la_LIBADD = libvlc_opengl.la
libvout_macosx_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)' \
@@ -70,7 +70,7 @@ libvout_macosx_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)' \
libcaopengllayer_plugin_la_SOURCES = video_output/caopengllayer.m \
$(OPENGL_VOUT_COMMONSOURCES)
-libcaopengllayer_plugin_la_OBJCFLAGS = $(AM_OBJCFLAGS) -fobjc-arc
+libcaopengllayer_plugin_la_OBJCFLAGS = $(AM_OBJCFLAGS) $(OPENGL_COMMONCFLAGS) -fobjc-arc
libcaopengllayer_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) -DHAVE_GL_CORE_SYMBOLS -DGL_SILENCE_DEPRECATION
libcaopengllayer_plugin_la_LIBADD = libvlc_opengl.la
libcaopengllayer_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)' \
@@ -117,7 +117,7 @@ libcaeagl_ios_plugin_la_LDFLAGS = $(AM_LDFLAGS) \
libcaeagl_ios_plugin_la_OBJCFLAGS = $(AM_OBJCFLAGS) -fobjc-arc
libcvpx_gl_plugin_la_SOURCES = video_output/apple/VLCCVOpenGLProvider.m
-libcvpx_gl_plugin_la_OBJCFLAGS = $(AM_OBJCFLAGS) -fobjc-arc
+libcvpx_gl_plugin_la_OBJCFLAGS = $(AM_OBJCFLAGS) $(OPENGL_COMMONCFLAGS) -fobjc-arc
libcvpx_gl_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) -DGL_SILENCE_DEPRECATION
libcvpx_gl_plugin_la_LDFLAGS = $(AM_LDFLAGS) \
-Wl,-framework,Foundation,-framework,CoreFoundation,-framework,CoreVideo,-framework,Metal
--
2.46.0
More information about the vlc-devel
mailing list