[GTK][jhbuild] Switch to GStreamer 1.0 build
authorphiln@webkit.org <philn@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 11 Dec 2012 09:42:32 +0000 (09:42 +0000)
committerphiln@webkit.org <philn@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 11 Dec 2012 09:42:32 +0000 (09:42 +0000)
https://bugs.webkit.org/show_bug.cgi?id=91727

Patch by Xabier Rodriguez Calvar <calvaris@igalia.com> on 2012-12-11
Reviewed by Philippe Normand.

Switch build-webkit --gtk to GStreamer 1.0 support and build the
necessary GStreamer git modules from JHBuild.

.:

* configure.ac: Removed GStreamer unstable API flag, made
GStreamer 1.0 default instead of 0.10 and made required version
1.0.3. In case no GStreamer version is specified, it falls back to
0.10. In case no video or web-audio are requested, GStreamer
and Farstream checks are not performed.

Tools:

* gtk/jhbuild.modules: Added GStreamer 1.0.3 build support.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@137271 268f45cc-cd09-0410-ab3c-d52691b4dbfc

ChangeLog
Tools/ChangeLog
Tools/gtk/jhbuild.modules
configure.ac

index d7d76e9..460cc26 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,19 @@
+2012-12-11  Xabier Rodriguez Calvar <calvaris@igalia.com>
+
+        [GTK][jhbuild] Switch to GStreamer 1.0 build
+        https://bugs.webkit.org/show_bug.cgi?id=91727
+
+        Reviewed by Philippe Normand.
+
+        Switch build-webkit --gtk to GStreamer 1.0 support and build the
+        necessary GStreamer git modules from JHBuild.
+
+        * configure.ac: Removed GStreamer unstable API flag, made
+        GStreamer 1.0 default instead of 0.10 and made required version
+        1.0.3. In case no GStreamer version is specified, it falls back to
+        0.10. In case no video or web-audio are requested, GStreamer
+        and Farstream checks are not performed.
+
 2012-12-11  Zan Dobersek  <zandobersek@gmail.com>
 
         [GTK] Feature enabling/disabling should be possible through build-webkit
index 8b3ee42..9bbf8a8 100644 (file)
@@ -1,3 +1,15 @@
+2012-12-11  Xabier Rodriguez Calvar  <calvaris@igalia.com>
+
+        [GTK][jhbuild] Switch to GStreamer 1.0 build
+        https://bugs.webkit.org/show_bug.cgi?id=91727
+
+        Reviewed by Philippe Normand.
+
+        Switch build-webkit --gtk to GStreamer 1.0 support and build the
+        necessary GStreamer git modules from JHBuild.
+
+        * gtk/jhbuild.modules: Added GStreamer 1.0.3 build support.
+
 2012-12-11  Zan Dobersek  <zandobersek@gmail.com>
 
         [GTK] Feature enabling/disabling should be possible through build-webkit
index ed5f115..3d4e14f 100644 (file)
       <dep package="libsoup"/>
       <dep package="at-spi2-core"/>
       <dep package="at-spi2-atk"/>
+      <dep package="gstreamer"/>
+      <dep package="gst-plugins-base"/>
+      <dep package="gst-plugins-good"/>
+      <dep package="gst-plugins-bad"/>
+      <dep package="gst-libav"/>
     </dependencies>
   </metamodule>
 
@@ -40,6 +45,8 @@
       href="http://www.freedesktop.org"/>
   <repository type="tarball" name="xmlsoft.org"
       href="ftp://xmlsoft.org"/>
+  <repository type="git" name="gstreamer"
+      href="git://anongit.freedesktop.org/git/gstreamer/"/>
 
   <autotools id="make" autogen-sh="configure">
     <branch repo="ftp.gnu.org"
             md5sum="5b9bebf4f5d2200ae2c4efe8fa6103f7"/>
   </autotools>
 
+  <autotools id="gstreamer">
+    <branch repo="gstreamer" module="gstreamer" checkoutdir="gstreamer" tag="1.0.3"/>
+  </autotools>
+
+  <autotools id="gst-plugins-base" autogenargs="--disable-examples">
+    <dependencies>
+      <dep package="gstreamer"/>
+    </dependencies>
+    <branch repo="gstreamer" module="gst-plugins-base" checkoutdir="gst-plugins-base" tag="1.0.3"/>
+  </autotools>
+
+  <autotools id="gst-plugins-good" autogenargs="--disable-examples">
+    <dependencies>
+      <dep package="gst-plugins-base"/>
+    </dependencies>
+    <branch repo="gstreamer" module="gst-plugins-good" checkoutdir="gst-plugins-good" tag="1.0.3"/>
+  </autotools>
+
+  <autotools id="gst-plugins-bad" autogenargs="--disable-examples">
+    <dependencies>
+      <dep package="gst-plugins-base"/>
+    </dependencies>
+    <branch repo="gstreamer" module="gst-plugins-bad" checkoutdir="gst-plugins-bad" tag="1.0.3"/>
+  </autotools>
+
+  <autotools id="gst-libav" autogenargs="--with-libav-extra-configure='--disable-yasm'">
+    <dependencies>
+      <dep package="gst-plugins-base"/>
+    </dependencies>
+    <branch repo="gstreamer" module="gst-libav" checkoutdir="gst-libav" tag="1.0.3"/>
+  </autotools>
+
 </moduleset>
index ad2b494..758861d 100644 (file)
@@ -336,38 +336,6 @@ esac
 
 AC_MSG_RESULT([$with_target])
 
-AC_MSG_CHECKING([the GStreamer version to use])
-AC_ARG_WITH([gstreamer],
-        [AS_HELP_STRING([--with-gstreamer=0.10|1.0], [the GStreamer version to use (default: 0.10)])],
-        [case "$with_gstreamer" in
-        0.10|1.0) ;;
-        *) AC_MSG_ERROR([invalid GStreamer version specified]) ;;
-        esac],
-        [with_gstreamer=0.10])
-AC_MSG_RESULT([$with_gstreamer])
-
-GSTREAMER_0_10_REQUIRED_VERSION=0.10
-GSTREAMER_0_10_PLUGINS_BASE_REQUIRED_VERSION=0.10.30
-GSTREAMER_1_0_REQUIRED_VERSION=0.11.90
-GSTREAMER_1_0_PLUGINS_BASE_REQUIRED_VERSION=0.11.90
-
-case "$with_gstreamer" in
-     0.10) GSTREAMER_REQUIRED_VERSION=$GSTREAMER_0_10_REQUIRED_VERSION
-           GSTREAMER_PLUGINS_BASE_REQUIRED_VERSION=$GSTREAMER_0_10_PLUGINS_BASE_REQUIRED_VERSION
-           GST_API_VERSION=0.10
-           ;;
-     1.0) GSTREAMER_REQUIRED_VERSION=$GSTREAMER_1_0_REQUIRED_VERSION
-           GSTREAMER_PLUGINS_BASE_REQUIRED_VERSION=$GSTREAMER_1_0_PLUGINS_BASE_REQUIRED_VERSION
-           GST_API_VERSION=1.0
-           ;;
-esac
-
-AC_SUBST([GST_API_VERSION])
-if test "$GST_API_VERSION" = "1.0"; then
-AC_DEFINE([GST_USE_UNSTABLE_API], [1], [Using unstable GStreamer API])
-AC_DEFINE([GST_API_VERSION_1],[1], [Using GStreamer 1.0])
-fi
-
 # minimum base dependencies
 CAIRO_REQUIRED_VERSION=1.10
 FONTCONFIG_REQUIRED_VERSION=2.4
@@ -475,18 +443,6 @@ AC_SUBST(ENCHANT_CFLAGS)
 AC_SUBST(ENCHANT_LIBS)
 fi
 
-# farstream-0.1 depends on gstreamer 0.10 currently. Disable
-# media_stream if gstreamer 0.11 build support is enabled.
-if test "$GST_API_VERSION" = "1.0"; then
-   enable_media_stream=false
-fi
-if test "$enable_media_stream" = "yes"; then
-   PKG_CHECK_MODULES([FARSTREAM], [farstream-0.1],
-                     [have_farstream=yes], [enable_media_stream=false])
-   AC_SUBST([FARSTREAM_CFLAGS])
-   AC_SUBST([FARSTREAM_LIBS])
-fi
-
 PKG_CHECK_MODULES(GAIL, $GAIL_PC_NAME >= $GAIL_REQUIRED_VERSION)
 AC_SUBST(GAIL_CFLAGS)
 AC_SUBST(GAIL_LIBS)
@@ -838,6 +794,57 @@ case "$enable_debug_symbols" in
 esac
 AC_MSG_RESULT([$enable_debug_symbols])
 
+#selecting GStreamer version
+AC_MSG_CHECKING([the GStreamer version to use])
+AC_ARG_WITH([gstreamer],
+        [AS_HELP_STRING([--with-gstreamer=1.0|0.10|auto], [the GStreamer version to use (default: auto, tries 1.0 first, 0.10 is fallback)])],
+        [case "$with_gstreamer" in
+        0.10|1.0|auto) ;;
+        *) AC_MSG_ERROR([invalid GStreamer version specified]) ;;
+        esac],
+        [with_gstreamer=auto])
+AC_MSG_RESULT([$with_gstreamer])
+
+GSTREAMER_0_10_REQUIRED_VERSION=0.10
+GSTREAMER_0_10_PLUGINS_BASE_REQUIRED_VERSION=0.10.30
+GSTREAMER_1_0_REQUIRED_VERSION=1.0.3
+GSTREAMER_1_0_PLUGINS_BASE_REQUIRED_VERSION=1.0.3
+
+if test "$enable_video" = "yes" || test "$enable_web_audio" = "yes"; then
+   if test "$with_gstreamer" = "auto"; then
+       gstreamer_modules="gstreamer-1.0 >= $GSTREAMER_1_0_REQUIRED_VERSION
+                          gstreamer-app-1.0
+                          gstreamer-audio-1.0
+                          gstreamer-fft-1.0
+                          gstreamer-base-1.0
+                          gstreamer-pbutils-1.0
+                          gstreamer-plugins-base-1.0 >= $GSTREAMER_1_0_PLUGINS_BASE_REQUIRED_VERSION
+                          gstreamer-video-1.0";
+       PKG_CHECK_MODULES([GSTREAMER_1_0], [$gstreamer_modules], [with_gstreamer=1.0], [with_gstreamer=0.10])
+       AC_MSG_NOTICE([Selected GStreamer $with_gstreamer])
+   fi
+else
+   if test "$with_gstreamer" != "auto"; then
+       AC_MSG_WARN([You have specified GStreamer $with_gstreamer version but it will not be used because neither HTML5 Video nor Web Audio are enabled])
+   fi
+fi
+
+case "$with_gstreamer" in
+     0.10) GSTREAMER_REQUIRED_VERSION=$GSTREAMER_0_10_REQUIRED_VERSION
+           GSTREAMER_PLUGINS_BASE_REQUIRED_VERSION=$GSTREAMER_0_10_PLUGINS_BASE_REQUIRED_VERSION
+           GST_API_VERSION=0.10
+           ;;
+     1.0) GSTREAMER_REQUIRED_VERSION=$GSTREAMER_1_0_REQUIRED_VERSION
+           GSTREAMER_PLUGINS_BASE_REQUIRED_VERSION=$GSTREAMER_1_0_PLUGINS_BASE_REQUIRED_VERSION
+           GST_API_VERSION=1.0
+           ;;
+esac
+
+AC_SUBST([GST_API_VERSION])
+if test "$GST_API_VERSION" = "1.0"; then
+   AC_DEFINE([GST_API_VERSION_1],[1], [Using GStreamer 1.0])
+fi
+
 # check whether to enable debug features
 AC_MSG_CHECKING([whether to enable debug features])
 AC_ARG_ENABLE(debug_features,
@@ -1028,6 +1035,21 @@ if test "$enable_video" = "yes" || test "$enable_web_audio" = "yes"; then
    AC_SUBST([GSTREAMER_LIBS])
 fi
 
+# farstream-0.1 depends on gstreamer 0.10 currently. Disable
+# media_stream if gstreamer 1.0 build support is enabled.
+if test "$have_gstreamer" != "yes" || test "$GST_API_VERSION" = "1.0"; then
+   if test "$enable_media_stream" = "yes"; then
+      AC_MSG_WARN([Disabling Media Stream because no GStreamer 0.10 support is enabled])
+   fi
+   enable_media_stream=false
+fi
+if test "$enable_media_stream" = "yes"; then
+   PKG_CHECK_MODULES([FARSTREAM], [farstream-0.1],
+                     [have_farstream=yes], [enable_media_stream=false])
+   AC_SUBST([FARSTREAM_CFLAGS])
+   AC_SUBST([FARSTREAM_LIBS])
+fi
+
 acceleration_backend_description=$with_acceleration_backend
 if test "$with_acceleration_backend" = "clutter"; then
    PKG_CHECK_MODULES(CLUTTER, clutter-1.0 >= $CLUTTER_REQUIRED_VERSION)