summaryrefslogtreecommitdiff
path: root/avmedia
diff options
context:
space:
mode:
authorDavid Tardon <dtardon@redhat.com>2012-08-10 08:11:46 +0200
committerDavid Tardon <dtardon@redhat.com>2012-08-10 08:11:46 +0200
commit982babf0488d5afcfadf78dc7eda7d0d47dda0e5 (patch)
treeeb58e0c33cb54e35c72a9f3510e67f8153d563ae /avmedia
parent2c2d6e261c538cc8f78a6b69d1d1d8cb0f4ab0c0 (diff)
make avmedia build with gstreamer-0.10
Change-Id: I6124904cecdb8ea66477f40b6771a103a8058c10
Diffstat (limited to 'avmedia')
-rw-r--r--avmedia/Library_avmediagst_0_10.mk62
-rw-r--r--avmedia/source/gstreamer/gstmanager.cxx2
-rw-r--r--avmedia/source/gstreamer/gstplayer.cxx8
3 files changed, 69 insertions, 3 deletions
diff --git a/avmedia/Library_avmediagst_0_10.mk b/avmedia/Library_avmediagst_0_10.mk
new file mode 100644
index 000000000000..0279717b4337
--- /dev/null
+++ b/avmedia/Library_avmediagst_0_10.mk
@@ -0,0 +1,62 @@
+# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*-
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# Matúš Kukan <matus.kukan@gmail.com>
+# Portions created by the Initial Developer are Copyright (C) 2011 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_Library_Library,avmediagst_0_10))
+
+$(eval $(call gb_Library_set_componentfile,avmediagst_0_10,avmedia/source/gstreamer/avmediagstreamer_0_10))
+
+$(eval $(call gb_Library_set_include,avmediagst_0_10,\
+ $$(INCLUDE) \
+ -I$(SRCDIR)/avmedia/source/inc \
+ $(GSTREAMER_0_10_CFLAGS) \
+))
+$(eval $(call gb_Library_add_libs,avmediagst_0_10,$(GSTREAMER_0_10_LIBS)))
+
+$(eval $(call gb_Library_use_sdk_api,avmediagst_0_10))
+
+ifeq ($(GUI),WNT)
+$(eval $(call gb_Library_add_defs,avmediagst_0_10,\
+ -DWINNT
+))
+endif
+
+$(eval $(call gb_Library_use_libraries,avmediagst_0_10,\
+ comphelper \
+ cppu \
+ cppuhelper \
+ sal \
+ tl \
+ vcl \
+ $(gb_STDLIBS) \
+))
+
+$(eval $(call gb_Library_add_exception_objects,avmediagst_0_10,\
+ avmedia/source/gstreamer/gst_0_10 \
+))
+
+# vim: set noet sw=4 ts=4:
diff --git a/avmedia/source/gstreamer/gstmanager.cxx b/avmedia/source/gstreamer/gstmanager.cxx
index 6b3ffffd33ca..f04e5ccd2f3d 100644
--- a/avmedia/source/gstreamer/gstmanager.cxx
+++ b/avmedia/source/gstreamer/gstmanager.cxx
@@ -34,11 +34,13 @@
#define AVMEDIA_GST_MANAGER_IMPLEMENTATIONNAME "com.sun.star.comp.avmedia.Manager_GStreamer"
#define AVMEDIA_GST_MANAGER_SERVICENAME "com.sun.star.media.Manager"
+#if !defined DBG
#if OSL_DEBUG_LEVEL > 2
#define DBG OSL_TRACE
#else
#define DBG(...)
#endif
+#endif
using namespace ::com::sun::star;
diff --git a/avmedia/source/gstreamer/gstplayer.cxx b/avmedia/source/gstreamer/gstplayer.cxx
index 28e5d343bfaf..36544100072d 100644
--- a/avmedia/source/gstreamer/gstplayer.cxx
+++ b/avmedia/source/gstreamer/gstplayer.cxx
@@ -50,11 +50,13 @@
# define AVVERSION "gst 1.0: "
#endif
-#if 1 //OSL_DEBUG_LEVEL > 2
+#if !defined DBG
+#if OSL_DEBUG_LEVEL > 2
#define DBG(...) do { fprintf (stderr, "%s", AVVERSION); fprintf (stderr, __VA_ARGS__); fprintf (stderr, "\n"); } while (0);
#else
#define DBG(...)
#endif
+#endif
using namespace ::com::sun::star;
@@ -192,7 +194,7 @@ GstBusSyncReply Player::processSyncMessage( GstMessage *message )
{
// DBG( "%p processSyncMessage has handle: %s", this, GST_MESSAGE_TYPE_NAME( message ) );
-#if 1 // OSL_DEBUG_LEVEL > 0
+#if OSL_DEBUG_LEVEL > 0
if ( GST_MESSAGE_TYPE( message ) == GST_MESSAGE_ERROR )
{
GError* error;
@@ -575,7 +577,7 @@ awt::Size SAL_CALL Player::getPreferredPlayerWindowSize()
DBG( "%p Player::getPreferredPlayerWindowSize, member %d x %d", this, mnWidth, mnHeight );
TimeValue aTimeout = { 10, 0 };
-#if 1 // OSL_DEBUG_LEVEL > 2
+#if OSL_DEBUG_LEVEL > 2
osl::Condition::Result aResult =
#endif
maSizeCondition.wait( &aTimeout );