#
# You should have received a copy of the GNU Library General Public
# License along with this library; if not, write to the
-# Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-# Boston, MA 02111-1307, USA.
+# Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
+# Boston, MA 02110-1301, USA.
#
# ----------------------------------------------------------------------------
set -e
-# set BRANCH to "0.10" for a GStreamer 0.10.x checkout
+# set BRANCH to e.g. "1.2" to track the stable 1.2 branch instead of master
BRANCH="master"
# set to "ssh" if you have a developer account and ssh access
GIT_ACCESS="anongit"
+# re-use and reference local master branch checkout if one already exists
+# (saves network bandwidth)
+REUSE_EXISTING_MASTER_CHECKOUT="true"
+
# git modules to clone
-MODULES="gstreamer gst-plugins-base gst-plugins-good gst-plugins-ugly gst-plugins-bad gst-ffmpeg"
+MODULES="gstreamer gst-plugins-base gst-plugins-good gst-plugins-ugly gst-plugins-bad"
+
+if test "$BRANCH" != "0.10"; then
+ MODULES="$MODULES gst-libav"
+else
+ MODULES="$MODULES gst-ffmpeg"
+fi
# note: we use ~/gst because that's what the gst-uninstalled script
# uses by default, so don't just change that to something else
mkdir -p $UNINSTALLED_ROOT/$BRANCH/prefix
+echo ""
+echo "Checking basic build tools and dependencies are installed..."
+echo ""
+
+if ! pkg-config --version 2>/dev/null >/dev/null; then
+ DEPS_OK="no"
+elif ! pkg-config --exists glib-2.0 orc-0.4 2>/dev/null >/dev/null; then
+ DEPS_OK="no"
+elif ! bison --version 2>/dev/null >/dev/null; then
+ DEPS_OK="no"
+elif ! flex --version 2>/dev/null >/dev/null; then
+ DEPS_OK="no"
+else
+ DEPS_OK="yes"
+fi
+
+if test "$DEPS_OK" != "yes"; then
+echo "==========================================================================================="
+echo ""
+echo " Some very basic build tools or dependencies are missing."
+echo ""
+echo " Please visit"
+echo ""
+echo " http://gstreamer.freedesktop.org/wiki/BuildDependenciesDebianUbuntu"
+echo ""
+#echo " or"
+#echo ""
+#echo " http://gstreamer.freedesktop.org/wiki/Fedora"
+#echo ""
+echo " for instructions how to install them on Debian/Ubuntu-based systems."
+echo ""
+echo "==========================================================================================="
+fi
+
+
cd $UNINSTALLED_ROOT/$BRANCH
for m in $MODULES
do
+ REF=""
+ if test "$BRANCH" != "master" \
+ -a "x$REUSE_EXISTING_MASTER_CHECKOUT" = "xtrue" \
+ -a -d ../master/$m; then
+ REF="--reference=../master/$m"
+ fi
+
if test "$GIT_ACCESS" = "ssh"; then
- git clone ssh://git.freedesktop.org/gstreamer/$m
+ git clone $REF ssh://git.freedesktop.org/git/gstreamer/$m
else
- git clone git://anongit.freedesktop.org/gstreamer/$m
+ git clone $REF git://anongit.freedesktop.org/gstreamer/$m
fi
cd $m
echo "by autogen.sh/configure"
echo
echo "==========================================================================================="
-echo
-echo "Also see http://gstreamer.freedesktop.org/wiki/UninstalledSetup
-echo
-echo "==========================================================================================="
+#echo
+#echo "Also see http://gstreamer.freedesktop.org/wiki/UninstalledSetup"
+#echo
+#echo "==========================================================================================="