[376/906] build: support openGLES on linux via autofoo. Partialy fixes #593786
authorStefan Kost <ensonic@users.sf.net>
Tue, 1 Sep 2009 12:21:39 +0000 (15:21 +0300)
committerMatthew Waters <ystreet00@gmail.com>
Sat, 15 Mar 2014 17:36:36 +0000 (18:36 +0100)
Add a pkg-config check for opengl and if not found assume opengl-es. If user has
none of both one still get build error later on (there is no pkg-config for
opengl-es).
Add more files to EXTRA dist and build the opengles variant if selected.
Simmilar changes could be done for the winCE backend.

gst-libs/gst/gl/Makefile.am
gst/gl/Makefile.am

index 08ad810..8b10912 100644 (file)
@@ -3,7 +3,9 @@ lib_LTLIBRARIES = libgstgl-@GST_MAJORMINOR@.la
 
 EXTRA_DIST = \
        gstglwindow_x11.c \
+       gstglwindow_x11ES2.c \
        gstglwindow_win32.c \
+       gstglwindow_winCE.c \
        gstglwindow_cocoa.m
 
 libgstgl_@GST_MAJORMINOR@_la_SOURCES = \
@@ -21,6 +23,9 @@ endif
 if GL_BACKEND_X11
 libgstgl_@GST_MAJORMINOR@_la_SOURCES += gstglwindow_x11.c
 endif
+if GL_BACKEND_X11ES2
+libgstgl_@GST_MAJORMINOR@_la_SOURCES += gstglwindow_x11ES2.c
+endif
 
 libgstgl_@GST_MAJORMINOR@includedir = $(includedir)/gstreamer-@GST_MAJORMINOR@/gst/gl
 libgstgl_@GST_MAJORMINOR@include_HEADERS = \
index 159fdb8..6064474 100644 (file)
@@ -4,22 +4,15 @@ plugin_LTLIBRARIES = libgstopengl.la
 AM_CFLAGS = $(GST_PLUGINS_BASE_CFLAGS) $(GST_BASE_CFLAGS) $(GST_CFLAGS)
 AM_LIBS = $(GST_BASE_LIBS)
 
-libgstopengl_la_SOURCES = \
-       gstopengl.c \
-       gstglimagesink.c \
-       gstglimagesink.h \
-       gstglupload.c \
-       gstglupload.h \
+# full opengl required
+if GL_IS_OPENGL
+OPENGL_SOURCES =  \
        gstglbumper.c \
        gstglbumper.h \
-       gstgldownload.c \
-       gstgldownload.h \
        gstglfilterblur.c \
        gstglfilterblur.h \
        gstglfiltersobel.c \
        gstglfiltersobel.h \
-       gstglfiltercube.c \
-       gstglfiltercube.h \
        gstglfilterlaplacian.c \
        gstglfilterlaplacian.h \
        gstglfilterglass.c \
@@ -58,6 +51,19 @@ libgstopengl_la_SOURCES = \
        effects/gstgleffectsin.c \
        effects/gstgleffectglow.c \
        effects/gstgleffectxray.c
+endif
+
+libgstopengl_la_SOURCES = \
+       gstopengl.c \
+       gstglimagesink.c \
+       gstglimagesink.h \
+       gstglupload.c \
+       gstglupload.h \
+       gstgldownload.c \
+       gstgldownload.h \
+       gstglfiltercube.c \
+       gstglfiltercube.h \
+       $(OPENGL_SOURCES)
 
 # check order of CFLAGS and LIBS, shouldn't the order be the other way around
 # (like in AM_CFLAGS)?