From 3dbf96faa3520b052ef7db3981c4c1031b69fb57 Mon Sep 17 00:00:00 2001 From: Thiago Santos Date: Mon, 2 Aug 2010 11:06:00 -0300 Subject: [PATCH] oggmux: Fix test build when theora and vorbis aren't available Ifdef properly to avoid build failures --- tests/check/pipelines/oggmux.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/tests/check/pipelines/oggmux.c b/tests/check/pipelines/oggmux.c index 16bb3f200a..a104c254bc 100644 --- a/tests/check/pipelines/oggmux.c +++ b/tests/check/pipelines/oggmux.c @@ -46,11 +46,11 @@ typedef struct ChainCodec codec; } ChainState; +#if (defined (HAVE_THEORA) || defined (HAVE_VORBIS)) static ogg_sync_state oggsync; static GHashTable *eos_chain_states; static gulong probe_id; - static ChainCodec get_page_codec (ogg_page * page) { @@ -77,15 +77,6 @@ get_page_codec (ogg_page * page) return codec; } -static gboolean -check_chain_final_state (gpointer key, ChainState * state, gpointer data) -{ - fail_unless (state->eos, "missing EOS flag on chain %u", state->serialno); - - /* return TRUE to empty the chain table */ - return TRUE; -} - static void fail_if_audio (gpointer key, ChainState * state, gpointer data) { @@ -157,6 +148,14 @@ is_video (gpointer key, ChainState * state, gpointer data) *((gboolean *) data) = TRUE; } +static gboolean +check_chain_final_state (gpointer key, ChainState * state, gpointer data) +{ + fail_unless (state->eos, "missing EOS flag on chain %u", state->serialno); + + /* return TRUE to empty the chain table */ + return TRUE; +} static gboolean eos_buffer_probe (GstPad * pad, GstBuffer * buffer, gpointer unused) @@ -309,6 +308,7 @@ test_pipeline (const char *pipeline) gst_object_unref (pad); gst_object_unref (bin); } +#endif #ifdef HAVE_VORBIS GST_START_TEST (test_vorbis)