aboutsummaryrefslogtreecommitdiffstats
path: root/multimedia
diff options
context:
space:
mode:
authorjhale <jhale@FreeBSD.org>2018-03-27 18:57:06 +0800
committerjhale <jhale@FreeBSD.org>2018-03-27 18:57:06 +0800
commitdcb3bc3130d9e713ca867ac37076338c4d87f464 (patch)
tree9b3beb53d4607aa391c607f8d780cd20a1347d96 /multimedia
parent9dae89d5ba9fd1b5525d31bc5f18f531807b7c58 (diff)
downloadfreebsd-ports-gnome-dcb3bc3130d9e713ca867ac37076338c4d87f464.tar.gz
freebsd-ports-gnome-dcb3bc3130d9e713ca867ac37076338c4d87f464.tar.zst
freebsd-ports-gnome-dcb3bc3130d9e713ca867ac37076338c4d87f464.zip
Fix build with CDIO option enabled
Obtained from: Arch Linux (https://aur.archlinux.org/cgit/aur.git/tree/cdio-api-fixes.patch?h=gmerlin)
Diffstat (limited to 'multimedia')
-rw-r--r--multimedia/gmerlin/Makefile4
-rw-r--r--multimedia/gmerlin/files/patch-plugins_cdaudio_cdparanoia.c15
-rw-r--r--multimedia/gmerlin/files/patch-plugins_cdaudio_cdtext.c91
3 files changed, 108 insertions, 2 deletions
diff --git a/multimedia/gmerlin/Makefile b/multimedia/gmerlin/Makefile
index 2463bd758e5d..6dc5933c3f1a 100644
--- a/multimedia/gmerlin/Makefile
+++ b/multimedia/gmerlin/Makefile
@@ -45,9 +45,9 @@ ALSA_LIB_DEPENDS= libasound.so:audio/alsa-lib
ALSA_CONFIGURE_OFF= --disable-alsa --disable-alsamixer
CDDB_LIB_DEPENDS= libcddb.so:audio/libcddb
CDDB_CONFIGURE_OFF= --disable-cddb
-CDIO_LIB_DEPENDS= libcdio.so:sysutils/libcdio
+CDIO_LIB_DEPENDS= libcdio.so:sysutils/libcdio \
+ libcdio_cdda.so:sysutils/libcdio-paranoia
CDIO_CONFIGURE_OFF= --disable-libcdio
-CDIO_BROKEN= fails to build with new libcdio
ESOUND_USE= gnome=esound
ESOUND_CONFIGURE_OFF= --disable-esd
JACK_LIB_DEPENDS= libjack.so:audio/jack
diff --git a/multimedia/gmerlin/files/patch-plugins_cdaudio_cdparanoia.c b/multimedia/gmerlin/files/patch-plugins_cdaudio_cdparanoia.c
new file mode 100644
index 000000000000..706e7c6551ce
--- /dev/null
+++ b/multimedia/gmerlin/files/patch-plugins_cdaudio_cdparanoia.c
@@ -0,0 +1,15 @@
+Fix build with sysutils/libcdio >= 0.90
+
+--- plugins/cdaudio/cdparanoia.c.orig 2018-02-22 06:24:11 UTC
++++ plugins/cdaudio/cdparanoia.c
+@@ -28,8 +28,8 @@
+
+ #include "cdaudio.h"
+ #define DO_NOT_WANT_PARANOIA_COMPATIBILITY
+-#include <cdio/cdda.h>
+-#include <cdio/paranoia.h>
++#include <cdio/paranoia/cdda.h>
++#include <cdio/paranoia/paranoia.h>
+
+ /*
+ * Ripping support
diff --git a/multimedia/gmerlin/files/patch-plugins_cdaudio_cdtext.c b/multimedia/gmerlin/files/patch-plugins_cdaudio_cdtext.c
new file mode 100644
index 000000000000..147d5490d8d3
--- /dev/null
+++ b/multimedia/gmerlin/files/patch-plugins_cdaudio_cdtext.c
@@ -0,0 +1,91 @@
+Fix build with sysutils/libcdio >= 0.90
+
+--- plugins/cdaudio/cdtext.c.orig 2012-06-08 11:50:33 UTC
++++ plugins/cdaudio/cdtext.c
+@@ -34,7 +34,7 @@
+ #include "cdaudio.h"
+
+ #define GET_FIELD(dst, key) \
+- field = cdtext_get_const(key, cdtext);
++ field = cdtext_get_const(cdtext, key, i+1);
+
+ #define GET_FIELD_DEFAULT(dst,key) \
+ field = cdtext_get_const(key, cdtext); \
+@@ -64,38 +64,34 @@ int bg_cdaudio_get_metadata_cdtext(CdIo_t * cdio,
+
+ /* Get information for the whole disc */
+
+- cdtext = cdio_get_cdtext (cdio, 0);
++ cdtext = cdio_get_cdtext (cdio);
+
+ if(!cdtext)
+ return 0;
+
+- artist = cdtext_get_const(CDTEXT_PERFORMER, cdtext);
+- author = cdtext_get_const(CDTEXT_COMPOSER, cdtext); /* Composer overwrites songwriter */
++ artist = cdtext_get_const(cdtext, CDTEXT_FIELD_PERFORMER, 0);
++ author = cdtext_get_const(cdtext, CDTEXT_FIELD_COMPOSER, 0); /* Composer overwrites songwriter */
+
+ if(!author)
+- author = cdtext_get_const(CDTEXT_SONGWRITER, cdtext);
++ author = cdtext_get_const(cdtext, CDTEXT_FIELD_SONGWRITER, 0);
+
+- album = cdtext_get_const(CDTEXT_TITLE, cdtext);
+- genre = cdtext_get_const(CDTEXT_GENRE, cdtext);
+- comment = cdtext_get_const(CDTEXT_MESSAGE, cdtext);
++ album = cdtext_get_const(cdtext, CDTEXT_FIELD_TITLE, 0);
++ genre = cdtext_get_const(cdtext, CDTEXT_FIELD_GENRE, 0);
++ comment = cdtext_get_const(cdtext, CDTEXT_FIELD_MESSAGE, 0);
+
+ for(i = 0; i < idx->num_tracks; i++)
+ {
+ if(idx->tracks[i].is_audio)
+ {
+- cdtext = cdio_get_cdtext (cdio, i+1);
+- if(!cdtext)
+- return 0;
++ GET_FIELD(title, CDTEXT_FIELD_TITLE);
+
+- GET_FIELD(title, CDTEXT_TITLE);
+-
+ if(!title)
+ return 0;
+
+ gavl_metadata_set(&info[idx->tracks[i].index].metadata,
+ GAVL_META_TITLE, title);
+
+- if((field = cdtext_get_const(CDTEXT_PERFORMER, cdtext)))
++ if((field = cdtext_get_const(cdtext, CDTEXT_FIELD_PERFORMER, i+1)))
+ gavl_metadata_set(&info[idx->tracks[i].index].metadata,
+ GAVL_META_ARTIST, field);
+ else
+@@ -103,10 +99,10 @@ int bg_cdaudio_get_metadata_cdtext(CdIo_t * cdio,
+ GAVL_META_ARTIST, artist);
+
+
+- if((field = cdtext_get_const(CDTEXT_COMPOSER, cdtext)))
++ if((field = cdtext_get_const(cdtext, CDTEXT_FIELD_COMPOSER, i+1)))
+ gavl_metadata_set(&info[idx->tracks[i].index].metadata,
+ GAVL_META_AUTHOR, field);
+- else if((field = cdtext_get_const(CDTEXT_SONGWRITER, cdtext)))
++ else if((field = cdtext_get_const(cdtext, CDTEXT_FIELD_SONGWRITER, i+1)))
+ gavl_metadata_set(&info[idx->tracks[i].index].metadata,
+ GAVL_META_AUTHOR, field);
+ else if(author)
+@@ -114,14 +110,14 @@ int bg_cdaudio_get_metadata_cdtext(CdIo_t * cdio,
+ GAVL_META_AUTHOR, author);
+
+
+- if((field = cdtext_get_const(CDTEXT_GENRE, cdtext)))
++ if((field = cdtext_get_const(cdtext, CDTEXT_FIELD_GENRE, i+1)))
+ gavl_metadata_set(&info[idx->tracks[i].index].metadata,
+ GAVL_META_GENRE, field);
+ else
+ gavl_metadata_set(&info[idx->tracks[i].index].metadata,
+ GAVL_META_GENRE, genre);
+
+- if((field = cdtext_get_const(CDTEXT_MESSAGE, cdtext)))
++ if((field = cdtext_get_const(cdtext, CDTEXT_FIELD_MESSAGE, i+1)))
+ gavl_metadata_set(&info[idx->tracks[i].index].metadata,
+ GAVL_META_COMMENT, field);
+ else