Add videoutils submodule for GstVideoDecoder APIs.
authorGwenole Beauchesne <gwenole.beauchesne@intel.com>
Fri, 21 Dec 2012 13:29:01 +0000 (14:29 +0100)
committerGwenole Beauchesne <gwenole.beauchesne@intel.com>
Fri, 21 Dec 2012 15:01:16 +0000 (16:01 +0100)
.gitmodules
autogen.sh
configure.ac
ext/Makefile.am
ext/videoutils [new submodule]
gst-libs/gst/Makefile.am
gst-libs/gst/vaapi/Makefile.am
gst-libs/gst/video/Makefile.am [new file with mode: 0644]
gst/vaapi/Makefile.am

index e40ceed..bad3c46 100644 (file)
@@ -1,3 +1,6 @@
 [submodule "ext/codecparsers"]
        path = ext/codecparsers
        url = git://gitorious.org/vaapi/gstreamer-codecparsers.git
+[submodule "ext/videoutils"]
+       path = ext/videoutils
+       url = git://gitorious.org/vaapi/gstreamer-videoutils.git
index 4314352..b4a63f3 100755 (executable)
@@ -20,7 +20,13 @@ if test -z "$GIT"; then
     echo "*** No git found ***"
     exit 1
 else
-    if test ! -f ext/codecparsers/autogen.sh; then
+    submodule_init="no"
+    for ext_module in codecparsers videoutils; do
+        if test ! -f ext/${ext_module}/autogen.sh; then
+            submodule_init="yes"
+        fi
+    done
+    if test "$submodule_init" = "yes"; then
         $GIT submodule init
     fi
     $GIT submodule update
index 68dcd0e..657bea8 100644 (file)
@@ -234,9 +234,8 @@ AC_CACHE_CHECK([for GstVideoDecoder],
     CPPFLAGS="$saved_CPPFLAGS"
     LIBS="$saved_LIBS"
 ])
-if test "$ac_cv_have_gst_video_decoder" != "yes"; then
-    AC_MSG_ERROR([GstVideoDecoder is not available])
-fi
+AM_CONDITIONAL([USE_LOCAL_GST_VIDEO_DECODER],
+    [test "$ac_cv_have_gst_video_decoder" != "yes"])
 
 dnl GStreamer -bad plugins
 PKG_CHECK_MODULES([GST_BASEVIDEO],
@@ -597,6 +596,7 @@ debian.upstream/libgstvaapi-x11.install.in
     gst-libs/gst/Makefile
     gst-libs/gst/codecparsers/Makefile
     gst-libs/gst/vaapi/Makefile
+    gst-libs/gst/video/Makefile
     gst/Makefile
     gst/vaapi/Makefile
     pkgconfig/Makefile
index bad55d5..cfb2bc0 100644 (file)
@@ -25,5 +25,24 @@ codecparsers_source_h = \
 
 EXTRA_DIST += $(codecparsers_source_h:%.h=$(codecparsers_srcdir)/%.h)
 
+videoutils_srcdir = \
+       $(top_srcdir)/ext/videoutils/gst-libs/gst/video
+
+videoutils_source_c = \
+       gstvideodecoder.c       \
+       gstvideoutils.c         \
+       video.c                 \
+       $(NULL)
+
+EXTRA_DIST += $(videoutils_source_c:%.c=$(videoutils_srcdir)/%.c)
+
+videoutils_source_h = \
+       gstvideodecoder.h       \
+       gstvideoutils.h         \
+       video.h                 \
+       $(NULL)
+
+EXTRA_DIST += $(videoutils_source_h:%.h=$(videoutils_srcdir)/%.h)
+
 # Extra clean files so that maintainer-clean removes *everything*
 MAINTAINERCLEANFILES = Makefile.in
diff --git a/ext/videoutils b/ext/videoutils
new file mode 160000 (submodule)
index 0000000..251df2b
--- /dev/null
@@ -0,0 +1 @@
+Subproject commit 251df2b0958e6265cf5752fdfc82c69a2869eca7
index 06d14db..6d09e2b 100644 (file)
@@ -1,4 +1,4 @@
-SUBDIRS = codecparsers vaapi
+SUBDIRS = codecparsers video vaapi
 
 # Extra clean files so that maintainer-clean removes *everything*
 MAINTAINERCLEANFILES = Makefile.in $(gen_headers)
index b0779d4..79684e2 100644 (file)
@@ -38,6 +38,7 @@ libgstvaapi_libs =                            \
        $(GST_VIDEO_LIBS)                       \
        $(GST_CODEC_PARSERS_LIBS)               \
        $(LIBVA_LIBS)                           \
+       $(top_builddir)/gst-libs/gst/video/libgstvaapi-videoutils.la \
        $(top_builddir)/gst-libs/gst/codecparsers/libgstvaapi-codecparsers.la
 
 libgstvaapi_source_c =                         \
diff --git a/gst-libs/gst/video/Makefile.am b/gst-libs/gst/video/Makefile.am
new file mode 100644 (file)
index 0000000..fc0ca01
--- /dev/null
@@ -0,0 +1,64 @@
+noinst_LTLIBRARIES =                           \
+       libgstvaapi-videoutils.la               \
+       $(NULL)
+
+local_videoutils_srcdir = \
+       $(top_srcdir)/ext/videoutils/gst-libs/gst/video
+
+libgstvaapi_videoutils_cflags =                        \
+       -DGST_USE_UNSTABLE_API                  \
+       -I$(top_srcdir)/gst-libs                \
+       $(GST_BASE_CFLAGS)                      \
+       $(GST_CFLAGS)                           \
+       $(NULL)
+
+libgstvaapi_videoutils_libs =                  \
+       $(GST_BASE_LIBS)                        \
+       $(GST_LIBS)                             \
+       $(NULL)
+
+gen_source_c =
+gen_source_h =
+
+if USE_LOCAL_GST_VIDEO_DECODER
+gen_source_c += gstvideodecoder.c gstvideoutils.c video.c
+gen_source_h += gstvideodecoder.h gstvideoutils.h video.h
+endif
+
+GENFILES = \
+       $(gen_source_c)                         \
+       $(gen_source_h)                         \
+       $(NULL)
+
+nodist_EXTRA_libgstvaapi_videoutils_la_SOURCES = dummy.c
+
+nodist_libgstvaapi_videoutils_la_SOURCES =     \
+       $(gen_source_c)                         \
+       $(NULL)
+
+libgstvaapi_videoutils_la_CFLAGS =             \
+       $(libgstvaapi_videoutils_cflags)        \
+       $(NULL)
+
+libgstvaapi_videoutils_la_LIBADD =             \
+       $(libgstvaapi_videoutils_libs)          \
+       $(NULL)
+
+libgstvaapi_videoutils_la_LDFLAGS =            \
+       $(GST_ALL_LDFLAGS)                      \
+       $(NULL)
+
+all-local: .timestamp.symlinks
+
+.timestamp.symlinks: $(GENFILES)
+       touch $@
+
+$(gen_source_c): %.c: $(local_videoutils_srcdir)/%.c %.h
+       $(LN_S) -f $< $@
+$(gen_source_h): %.h: $(local_videoutils_srcdir)/%.h
+       $(LN_S) -f $< $@
+
+DISTCLEANFILES = $(GENFILES) .timestamp.symlinks
+
+# Extra clean files so that maintainer-clean removes *everything*
+MAINTAINERCLEANFILES = Makefile.in
index 4da267e..df61ad9 100644 (file)
@@ -68,7 +68,8 @@ libgstvaapi_la_LIBADD =       \
        $(GST_VIDEO_LIBS)       \
        $(GST_INTERFACES_LIBS)  \
        $(GST_BASEVIDEO_LIBS)   \
-       $(GST_PLUGINS_BASE_LIBS)
+       $(GST_PLUGINS_BASE_LIBS) \
+       $(top_builddir)/gst-libs/gst/video/libgstvaapi-videoutils.la
 
 libgstvaapi_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
 libgstvaapi_la_LIBTOOLFLAGS = --tag=disable-static