[sound-juicer/musicbrainz4: 10/12] mb4: enable libmusicbrainz4 support



commit 872fbec86f9fa0a3c7e35807a4035b556e55bf55
Author: Christophe Fergeau <cfergeau redhat com>
Date:   Sat Aug 6 13:22:00 2011 +0200

    mb4: enable libmusicbrainz4 support
    
    Now that the libmusicbrainz4 is on par feature-wise with
    the libmusicbrainz3 code, we can enable it in configure.in. It also
    adds it to the list of metadata backends known to sound-juicer
    so that it can be used for metadata retrieval.

 configure.in                   |    4 +---
 libjuicer/sj-metadata-getter.c |    6 ++++++
 2 files changed, 7 insertions(+), 3 deletions(-)
---
diff --git a/configure.in b/configure.in
index 9e97014..1fd4b9b 100644
--- a/configure.in
+++ b/configure.in
@@ -75,9 +75,7 @@ PKG_CHECK_MODULES(MUSICBRAINZ4, libmusicbrainz4 libdiscid, [have_mb4=yes], [have
 AC_SUBST(MUSICBRAINZ4_CFLAGS)
 AC_SUBST(MUSICBRAINZ4_LIBS)
 if test "$have_mb4" = "yes" ; then
-        dnl AC_DEFINE([HAVE_MUSICBRAINZ4], 1, [Whether libmusicbrainz4 is available])
-        AC_MSG_WARN([libmusicbrainz4 support disabled since it's currently non-functional])
-        have_mb4="no"
+        AC_DEFINE([HAVE_MUSICBRAINZ4], 1, [Whether libmusicbrainz4 is available])
 fi
 AM_CONDITIONAL([HAVE_MUSICBRAINZ4], [test "$have_mb4" = "yes"])
 
diff --git a/libjuicer/sj-metadata-getter.c b/libjuicer/sj-metadata-getter.c
index 1aff2f5..11002fa 100644
--- a/libjuicer/sj-metadata-getter.c
+++ b/libjuicer/sj-metadata-getter.c
@@ -26,6 +26,9 @@
 #include "sj-metadata-getter.h"
 #include "sj-metadata-marshal.h"
 #include "sj-metadata.h"
+#ifdef HAVE_MUSICBRAINZ4
+#include "sj-metadata-musicbrainz4.h"
+#endif /* HAVE_MUSICBRAINZ4 */
 #ifdef HAVE_MUSICBRAINZ3
 #include "sj-metadata-musicbrainz3.h"
 #endif /* HAVE_MUSICBRAINZ3 */
@@ -175,6 +178,9 @@ lookup_cd (SjMetadataGetter *mdg)
   GError *error = NULL;
   gboolean found = FALSE;
   GType types[] = {
+#ifdef HAVE_MUSICBRAINZ4
+    SJ_TYPE_METADATA_MUSICBRAINZ4,
+#endif /* HAVE_MUSICBRAINZ4 */
 #ifdef HAVE_MUSICBRAINZ3
     SJ_TYPE_METADATA_MUSICBRAINZ3,
 #endif /* HAVE_MUSICBRAINZ3 */



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]