summaryrefslogtreecommitdiff
path: root/media-sound/mpfc
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /media-sound/mpfc
reinit the tree, so we can have metadata
Diffstat (limited to 'media-sound/mpfc')
-rw-r--r--media-sound/mpfc/Manifest14
-rw-r--r--media-sound/mpfc/files/mpfc-1.3.7-INT_MAX.patch20
-rw-r--r--media-sound/mpfc/files/mpfc-1.3.7-asneeded.patch26
-rw-r--r--media-sound/mpfc/files/mpfc-1.3.7-libdir.patch113
-rw-r--r--media-sound/mpfc/files/mpfc-1.3.7-mathlib.patch20
-rw-r--r--media-sound/mpfc/files/mpfc-1.3.8.1-fix-underlinking.patch32
-rw-r--r--media-sound/mpfc/files/mpfc-1.3.8.1-qa-implicit-declarations.patch193
-rw-r--r--media-sound/mpfc/files/mpfc-gcc4.patch13
-rw-r--r--media-sound/mpfc/metadata.xml14
-rw-r--r--media-sound/mpfc/mpfc-1.3.7-r1.ebuild55
-rw-r--r--media-sound/mpfc/mpfc-1.3.8.1-r2.ebuild57
11 files changed, 557 insertions, 0 deletions
diff --git a/media-sound/mpfc/Manifest b/media-sound/mpfc/Manifest
new file mode 100644
index 000000000000..7b23f06f0445
--- /dev/null
+++ b/media-sound/mpfc/Manifest
@@ -0,0 +1,14 @@
+AUX mpfc-1.3.7-INT_MAX.patch 499 SHA256 41e60b73155317bab5d70e5dacc5bb1ac888bf37858ee193238cd6fd8319a44c SHA512 29ab9d5f5f2198011bac008f05bbc870191246721896ed8f30c112b46e4dd7be1bc61afa457f907ff98e4bb2da7bdc610448af7e75d0d3570b142bffb51d1911 WHIRLPOOL 6ce0bf99fec3d74700916eb96ca2e1352f13d1913d500b17d7b5b914af485ef1108f0ed897f1adfba354da57005d0afd6074d0a9767448feda8ef13b4aff8ee7
+AUX mpfc-1.3.7-asneeded.patch 1236 SHA256 123231c565ba381dfc46e6bda60b9feb42f88a888555bc8f8dad5af6564ffb0b SHA512 7455fe7d8c6549669af94357fa4275152ffd63638b04bf327219cb76afedd4d687d10371720508b76a006437b7207b7653ea18400f662fbe8afae3a4158bc52e WHIRLPOOL bfd82c74501a5bbaf88cbb6ee036311edbc62ee6a988860fb2efb11a661b2f55d5f6c20fe13b2c1c655e2f05bb4ce0033fdb972a144f91104bd02a0ea520aa67
+AUX mpfc-1.3.7-libdir.patch 4081 SHA256 c2fb48ac91b0aa8e7d3f36c422ae05f85825f39c3a2c86c47c9cff600353c0d8 SHA512 97245e787dd1521cf82c33e7da0842ad2cc46737b9b624d76cdb45c2e4b2ae4f2f38afe64b11142e7330abec69dcf0aa2d3b4af2e523ef03a94ab061b3018673 WHIRLPOOL 9ddbf1c4f2150fc8f36ce0c83730db3381cbe3aab63cb92c8ffc0fee6c28916c9174cb87c43729b28b35c34dda4c9e299718431a3ba65ba6f1dd8e62ef2d3349
+AUX mpfc-1.3.7-mathlib.patch 705 SHA256 2a5ef7a7008ab2e5c19af3e84080f6e4aa2c662dc3c6b4d12a8d30bb5c163aef SHA512 7bbe651309b8424eaa525b49f6da90ebae89dfca38dca075e9f40f9606bf51955942ecf9c958ea9183ac84a91bbe4c3249e733707578e67abc4673e298dbb8aa WHIRLPOOL 317626d270aac774f2bb629ab580ed152c54af30167c9b4efdb85792752f63912126acd8924bfe2df06158fcbf95366f753f0af85339464d14549de68b2deb36
+AUX mpfc-1.3.8.1-fix-underlinking.patch 960 SHA256 73815f3aff12516a65ca0a0aaa59a074201c47328e0a4f279fb7afe43f0dc4b9 SHA512 117c49a7893c95b8b7e592aba76afd4f05f076b88db303a4fcb0efdaad351008bd91d88d06f278586920907c54801df49c7101c8dc2e41475038244cefd6a480 WHIRLPOOL d6fe9ddaa656047cc0158fe257f8a6850b7fc2e10e4a4513a61842a13a2e7dd1b3a2f15c09e10205f7ceb2a8625a385e233a983c4e96b8008d3f8c9e40224b72
+AUX mpfc-1.3.8.1-qa-implicit-declarations.patch 4938 SHA256 db388c2f00575f81ca40ab1f8da93ee9f465e692338000307d2ad6c912dd1f18 SHA512 afd61c08964b237124316a7cad4cecef29d8c269c6e2d0c645d81272167e9f7de2b3c1ef33e2877e1b5f2c0a4021bf2e548a04976142c22e889a6cf769807233 WHIRLPOOL 39672af3729fe2d79bfcd66d2c8c88a096466e365927acf4d77875e4117398ff402dd78aa518bb16d54adaf3c43cea937008b918a0b5f3a2571b1a1d407cbe43
+AUX mpfc-gcc4.patch 475 SHA256 779863f55a7c29f85072d395ff614c57be957bb1e4295442eca8d89cc0a5946f SHA512 25369112b269b1bd4022a3d48c154fe59f7bc02a69ae78e274ae3325df4e6462d1e7f6a3784dd4786d3950d80fadb643bcb7084e980a23c801bf6db3b7af5271 WHIRLPOOL 8ed812043934eaa9c29b7fde9cc92c3ba89a18152fe821d3b79cb9135c0893ab03dbf6146cbdd402f814e99625d3f34ae1e59078261971c91b8d865a2fa7a610
+DIST mpfc-1.3.7.tar.gz 869364 SHA256 256ec3a9ebe3296e614b937d3e9044ba11d27c863f723fc939beb82daf54ec8d SHA512 bef536c639a4d2422d0e04ca9aa6c18cee28e4936349ec796a4a25dd069fe0a7996c0d32b18b29b25f5acfa11e4fd4fe78becfe447d6726574bc320041fdf3d6 WHIRLPOOL 7803324f3496350369960a30185086994885a3a5282fd0fd152845f7c7ba77a7d6bc7ce4fccf10131ff44f2773eb13b5d74741b842dbf774cd03766f6ced7699
+DIST mpfc-1.3.8.1.tar.gz 1042027 SHA256 e8a498ba390bd4ad91d4a36a84d676bcdd9525264ed34548df1d94118abc1116 SHA512 071e12ea784a8610aa6621f5afa1c6ba1e2a3ffe0deac8175b8b43b4446f0c54ff049fd8321aff7551766fe4561a974e39bbf93e30b353b25e27673ea9584573 WHIRLPOOL f4cf742e460205e45fb5ac741613a2fd2288fef1a9758e78555c32ce7358ec1a55be5a04e2a286015ffce733bddabca7b9e34993402ad158a1d5848c1cbc1209
+EBUILD mpfc-1.3.7-r1.ebuild 1218 SHA256 942e3edc60d198bb360587421dc7c1fd70558fbf0f8e4d3306ed2281df4db80a SHA512 ccb9d1ea5dd52c4579a21f5a427ee3179a49d93a318982409a2c081f734976c76111b2600c87896ab0b42f1adc3e8d1e734d134f1aa959cce4acec9dc9bc48fa WHIRLPOOL 49f03a11b0ad330a0faf5c7b1104b6b9fcaded8e1f5fbb4c3b24eea28a4c5f390ad2a04a50d2acaf58ff4bfd9cce473b17cf6cedcb5107fa9d928a8cc9ff7b3f
+EBUILD mpfc-1.3.8.1-r2.ebuild 1139 SHA256 cd7cb98685dd92dde1539f0b0337935ddfe2c5874af0b01e4726d52f327a71ef SHA512 fb0ac917518d6bda5a7b6bc4ab3e96a82bb0540ce2b402b1b75f48f91832d9a24f36e3f9146ae05602197e4d88a2e493374c68516e2d2c6a476e27df89fb800d WHIRLPOOL 90b0ff55f02388cb94fe2180a8bfe6545fcc2635d4193e07cc40f56f61a80dbee69d7cc236fed31984f3e5e050f95278eea9ab97fcc5c5a9cf700ed1c328aec0
+MISC ChangeLog 3165 SHA256 b4fcc4d82d8f7ade3d43a865db8eeff313d51ed566c3e51a29d112e2641b51aa SHA512 0fe565958e6447ba4db14ab06c09de4a5e6fc575e0a0f577fa380d838e36e1689f380b5c5756b4f73d771837586854a9cd9b91d5c6efe885d5175d98b737acf1 WHIRLPOOL e2d11f5c3bdb9c95a0fe53b3818284da219bda0f9e7ecbc1fb0a3fd3c5035575a47681c04bbbc1b9ae8a35818bdc4d1ed800d8b848655ba919265a44eb42967a
+MISC ChangeLog-2015 4330 SHA256 2385e19dc8dbd8493e59971cdd60a94feb3ef76e3c870d5ae2ced12c9f63dc69 SHA512 e523998868e3bb6fd2fa6e30610aa93f2e2ef411b63db55ce768b5264a074d4f0924048bae8c2d01b7e3eb123fbecaf37198145f8086afab4b777af89886d05f WHIRLPOOL f0b90dcae773690749d7513a23dd4f47fa4a8f7e15d65ce55a6e0d523de92f285e14d7de6d704bd4da19e18bbad9e60cd4122a57d6aba4391f6a53b0770863c0
+MISC metadata.xml 413 SHA256 452572494f12f9e7c746f24641b4dbdfc27eaf2669451a69a617d9cae65732b7 SHA512 fd972a9e503642f833b6c08bfc662bec020bb9e88959e433e6c20ef582c2b05edd248d2b652cf2b884097fae888ab29413b41efa731399cffb261a10e6435b3a WHIRLPOOL 053452f76c7cd21dffacc5ed1d6dc74bf027dbdce2e1bb6e91fea302a42374017a6f4156f0f4343f43a35f22a21b7e14a40b6f19e0cd150fcc36b6b16b875188
diff --git a/media-sound/mpfc/files/mpfc-1.3.7-INT_MAX.patch b/media-sound/mpfc/files/mpfc-1.3.7-INT_MAX.patch
new file mode 100644
index 000000000000..8bca2f380366
--- /dev/null
+++ b/media-sound/mpfc/files/mpfc-1.3.7-INT_MAX.patch
@@ -0,0 +1,20 @@
+--- plugins/input/audiocd/audiocd.c
++++ plugins/input/audiocd/audiocd.c
+@@ -21,6 +21,7 @@
+ */
+
+ #include <stdio.h>
++#include <limits.h> /* cdrom.h and INT_MAX */
+ #include <linux/cdrom.h>
+ #include <errno.h>
+ #include <string.h>
+--- plugins/input/audiocd/audiocd.h
++++ plugins/input/audiocd/audiocd.h
+@@ -23,6 +23,7 @@
+ #ifndef __SG_MPFC_AUDIOCD_H__
+ #define __SG_MPFC_AUDIOCD_H__
+
++#include <limits.h> /* cdrom.h and INT_MAX */
+ #include <linux/cdrom.h>
+ #include "types.h"
+ #include "logger.h"
diff --git a/media-sound/mpfc/files/mpfc-1.3.7-asneeded.patch b/media-sound/mpfc/files/mpfc-1.3.7-asneeded.patch
new file mode 100644
index 000000000000..d681e8784f74
--- /dev/null
+++ b/media-sound/mpfc/files/mpfc-1.3.7-asneeded.patch
@@ -0,0 +1,26 @@
+Index: mpfc-1.3.7/libmpfc/Makefile.am
+===================================================================
+--- mpfc-1.3.7.orig/libmpfc/Makefile.am
++++ mpfc-1.3.7/libmpfc/Makefile.am
+@@ -18,6 +18,6 @@ libmpfc_la_SOURCES = cfg.c charset.c fil
+ song_info.c string.c vfs.c logger.c cfg_rcfile.c \
+ plugin.c plugin_general.c command.c \
+ $(libmpfchdr_HEADERS)
+-libmpfc_la_LIBADD = @COMMON_LIBS@ @RESOLV_LIBS@
++libmpfc_la_LIBADD = @COMMON_LIBS@ @RESOLV_LIBS@ @DL_LIBS@
+ INCLUDES = -I$(top_builddir)/src -I$(top_builddir)/libmpfcwnd
+ localedir = $(datadir)/locale
+Index: mpfc-1.3.7/src/Makefile.am
+===================================================================
+--- mpfc-1.3.7.orig/src/Makefile.am
++++ mpfc-1.3.7/src/Makefile.am
+@@ -13,6 +13,7 @@ localedir = $(datadir)/locale
+ DEFS = -DLOCALEDIR=\"$(localedir)\" -DLIBDIR=\"$(libdir)\" \
+ -DSYSCONFDIR=\"$(sysconfdir)\" @DEFS@
+ INCLUDES = -I$(top_builddir)/libmpfcwnd/
+-mpfc_LDADD = @COMMON_LIBS@ @PTHREAD_LIBS@ @DL_LIBS@ @MATH_LIBS@ \
++mpfc_LDADD = \
+ $(top_builddir)/libmpfc/libmpfc.la \
+- $(top_builddir)/libmpfcwnd/libmpfcwnd.la
++ $(top_builddir)/libmpfcwnd/libmpfcwnd.la \
++ @COMMON_LIBS@ @PTHREAD_LIBS@ @DL_LIBS@ @MATH_LIBS@
diff --git a/media-sound/mpfc/files/mpfc-1.3.7-libdir.patch b/media-sound/mpfc/files/mpfc-1.3.7-libdir.patch
new file mode 100644
index 000000000000..52a318463154
--- /dev/null
+++ b/media-sound/mpfc/files/mpfc-1.3.7-libdir.patch
@@ -0,0 +1,113 @@
+Index: mpfc-1.3.7/libmpfc/Makefile.am
+===================================================================
+--- mpfc-1.3.7.orig/libmpfc/Makefile.am
++++ mpfc-1.3.7/libmpfc/Makefile.am
+@@ -1,7 +1,5 @@
+ lib_LTLIBRARIES = libmpfc.la
+
+-libdir = $(prefix)/lib/
+-
+ libmpfchdrdir = $(prefix)/include/mpfc
+ libmpfchdr_HEADERS = ../mpfc-config.h ../src/types.h ../src/cfg.h \
+ ../src/charset.h \
+Index: mpfc-1.3.7/libmpfcwnd/Makefile.am
+===================================================================
+--- mpfc-1.3.7.orig/libmpfcwnd/Makefile.am
++++ mpfc-1.3.7/libmpfcwnd/Makefile.am
+@@ -1,5 +1,4 @@
+ lib_LTLIBRARIES = libmpfcwnd.la
+-libdir = $(prefix)/lib/
+ libmpfcwndhdrdir = $(prefix)/include/mpfc/libmpfcwnd
+ libmpfcwndhdr_HEADERS = wnd.h wnd_print.h wnd_msg.h wnd_kbd.h \
+ wnd_def_handlers.h wnd_root.h wnd_mouse.h wnd_types.h \
+Index: mpfc-1.3.7/plugins/input/audiocd/Makefile.am
+===================================================================
+--- mpfc-1.3.7.orig/plugins/input/audiocd/Makefile.am
++++ mpfc-1.3.7/plugins/input/audiocd/Makefile.am
+@@ -1,6 +1,6 @@
+-lib_LTLIBRARIES = libaudiocd.la
++plugin_LTLIBRARIES = libaudiocd.la
+
+-libdir = $(prefix)/lib/mpfc/input
++plugindir = $(libdir)/mpfc/input
+
+ libaudiocd_la_SOURCES = audiocd.c audiocd.h cddb.c cddb.h
+ libaudiocd_la_LIBADD = @COMMON_LIBS@ @RESOLV_LIBS@
+Index: mpfc-1.3.7/plugins/input/mp3/Makefile.am
+===================================================================
+--- mpfc-1.3.7.orig/plugins/input/mp3/Makefile.am
++++ mpfc-1.3.7/plugins/input/mp3/Makefile.am
+@@ -1,6 +1,6 @@
+-lib_LTLIBRARIES = libmp3.la
++plugin_LTLIBRARIES = libmp3.la
+
+-libdir = $(prefix)/lib/mpfc/input
++plugindir = $(libdir)/mpfc/input
+
+ libmp3_la_SOURCES = mp3.c mp3.h
+ INCLUDES = -I$(top_builddir)/src -I$(top_builddir)/libmpfcwnd
+Index: mpfc-1.3.7/plugins/input/ogg/Makefile.am
+===================================================================
+--- mpfc-1.3.7.orig/plugins/input/ogg/Makefile.am
++++ mpfc-1.3.7/plugins/input/ogg/Makefile.am
+@@ -1,6 +1,6 @@
+-lib_LTLIBRARIES = libogg_vorbis.la
++plugin_LTLIBRARIES = libogg_vorbis.la
+
+-libdir = $(prefix)/lib/mpfc/input
++plugindir = $(libdir)/mpfc/input
+
+ libogg_vorbis_la_SOURCES = ogg.c vcedit.c vcedit.h
+ INCLUDES = -I$(top_builddir)/src -I$(top_builddir)/libmpfcwnd
+Index: mpfc-1.3.7/plugins/input/wav/Makefile.am
+===================================================================
+--- mpfc-1.3.7.orig/plugins/input/wav/Makefile.am
++++ mpfc-1.3.7/plugins/input/wav/Makefile.am
+@@ -1,6 +1,6 @@
+-lib_LTLIBRARIES = libwav.la
++plugin_LTLIBRARIES = libwav.la
+
+-libdir = $(prefix)/lib/mpfc/input
++plugindir = $(libdir)/mpfc/input
+
+ libwav_la_SOURCES = wav.c wav.h
+ libwav_la_LIBADD = @COMMON_LIBS@
+Index: mpfc-1.3.7/plugins/output/alsa/Makefile.am
+===================================================================
+--- mpfc-1.3.7.orig/plugins/output/alsa/Makefile.am
++++ mpfc-1.3.7/plugins/output/alsa/Makefile.am
+@@ -1,6 +1,6 @@
+-lib_LTLIBRARIES = libalsa.la
++plugin_LTLIBRARIES = libalsa.la
+
+-libdir = $(prefix)/lib/mpfc/output
++plugindir = $(libdir)/mpfc/output
+
+ libalsa_la_SOURCES = alsa.c
+ INCLUDES = -I$(top_builddir)/src -I$(top_builddir)/libmpfcwnd
+Index: mpfc-1.3.7/plugins/output/disk_writer/Makefile.am
+===================================================================
+--- mpfc-1.3.7.orig/plugins/output/disk_writer/Makefile.am
++++ mpfc-1.3.7/plugins/output/disk_writer/Makefile.am
+@@ -1,6 +1,6 @@
+-lib_LTLIBRARIES = libdisk_writer.la
++plugin_LTLIBRARIES = libdisk_writer.la
+
+-libdir = $(prefix)/lib/mpfc/output
++plugindir = $(libdir)/mpfc/output
+
+ libdisk_writer_la_SOURCES = writer.c
+ libdisk_writer_la_LIBADD = @COMMON_LIBS@
+Index: mpfc-1.3.7/plugins/output/oss/Makefile.am
+===================================================================
+--- mpfc-1.3.7.orig/plugins/output/oss/Makefile.am
++++ mpfc-1.3.7/plugins/output/oss/Makefile.am
+@@ -1,6 +1,6 @@
+-lib_LTLIBRARIES = liboss.la
++plugin_LTLIBRARIES = liboss.la
+
+-libdir = $(prefix)/lib/mpfc/output
++plugindir = $(libdir)/mpfc/output
+
+ liboss_la_SOURCES = oss.c
+ liboss_la_LIBADD = @COMMON_LIBS@
diff --git a/media-sound/mpfc/files/mpfc-1.3.7-mathlib.patch b/media-sound/mpfc/files/mpfc-1.3.7-mathlib.patch
new file mode 100644
index 000000000000..09471407398b
--- /dev/null
+++ b/media-sound/mpfc/files/mpfc-1.3.7-mathlib.patch
@@ -0,0 +1,20 @@
+Index: mpfc-1.3.7/configure.in
+===================================================================
+--- mpfc-1.3.7.orig/configure.in
++++ mpfc-1.3.7/configure.in
+@@ -66,7 +66,6 @@ LIBS=$LIBS_save
+ AC_ARG_ENABLE(mp3,
+ [ --disable-mp3 Disable mp3 input plugin [default=enabled]],,
+ enable_mp3="yes")
+-if test "x$enable_mp3" = xyes; then
+ # Check for math lib
+ LIBS_save=$LIBS
+ AC_CHECK_HEADERS([math.h],,[AC_MSG_ERROR(*** Can't find math header ***)])
+@@ -75,6 +74,7 @@ if test "x$enable_mp3" = xyes; then
+ AC_SUBST(MATH_LIBS)
+ LIBS=$LIBS_save
+
++if test "x$enable_mp3" = xyes; then
+ # Check for libmad
+ LIBS_save=$LIBS
+ AC_CHECK_HEADERS([mad.h],,[AC_MSG_ERROR(*** Can't find libmad header ***)])
diff --git a/media-sound/mpfc/files/mpfc-1.3.8.1-fix-underlinking.patch b/media-sound/mpfc/files/mpfc-1.3.8.1-fix-underlinking.patch
new file mode 100644
index 000000000000..0fb96ae1ff00
--- /dev/null
+++ b/media-sound/mpfc/files/mpfc-1.3.8.1-fix-underlinking.patch
@@ -0,0 +1,32 @@
+Fix libm (and ncurses) underlinking issues.
+https://bugs.gentoo.org/show_bug.cgi?id=529490
+
+--- mpfc-1.3.8.1/configure.ac
++++ mpfc-1.3.8.1/configure.ac
+@@ -13,13 +13,13 @@
+ COMMON_LIBS=""
+ AC_SUBST(COMMON_LIBS)
+
++dnl Check for libm for rintf()
++AC_SEARCH_LIBS([rintf], [m], [], [
++ AC_MSG_ERROR([unable to find the rintf() function])
++])
++
+ # Check for ncurses
+-LIBS_save=$LIBS
+-AC_CHECK_HEADERS([curses.h],,[AC_MSG_ERROR(*** Can't find curses.h ***)])
+-AC_CHECK_LIB(ncursesw, waddch,,[AC_MSG_ERROR(*** Can't find ncurses library ***)])
+-CURSES_LIBS="-lncursesw"
+-AC_SUBST(CURSES_LIBS)
+-LIBS=$LIBS_save
++PKG_CHECK_MODULES([CURSES], [ncursesw])
+
+ # Check for pthread
+ LIBS_save=$LIBS
+--- mpfc-1.3.8.1/libmpfcwnd/Makefile.am
++++ mpfc-1.3.8.1/libmpfcwnd/Makefile.am
+@@ -1,3 +1,4 @@
++AM_CPPFLAGS = @CURSES_CFLAGS@
+ lib_LTLIBRARIES = libmpfcwnd.la
+ libmpfcwndhdrdir = $(includedir)/mpfc/libmpfcwnd
+ libmpfcwndhdr_HEADERS = wnd.h wnd_print.h wnd_msg.h wnd_kbd.h \
diff --git a/media-sound/mpfc/files/mpfc-1.3.8.1-qa-implicit-declarations.patch b/media-sound/mpfc/files/mpfc-1.3.8.1-qa-implicit-declarations.patch
new file mode 100644
index 000000000000..31958582e90d
--- /dev/null
+++ b/media-sound/mpfc/files/mpfc-1.3.8.1-qa-implicit-declarations.patch
@@ -0,0 +1,193 @@
+Fix QA warnings caused by implicit declarations, such as
+
+* QA Notice: Package triggers severe warnings which indicate that it
+* may exhibit random runtime failures.
+* wnd.c:1081:4: warning: implicit declaration of function ‘add_wch’ [-Wimplicit-function-declaration]
+
+--- mpfc-1.3.8.1/libmpfc/file_http.c
++++ mpfc-1.3.8.1/libmpfc/file_http.c
+@@ -35,6 +35,7 @@
+ #include "file.h"
+ #include "file_http.h"
+ #include "mystring.h"
++#include "util.h"
+
+ /* Get file data */
+ #define FHTTP_GET_DATA(data, file) \
+--- mpfc-1.3.8.1/libmpfc/id3.c
++++ mpfc-1.3.8.1/libmpfc/id3.c
+@@ -26,6 +26,7 @@
+ #include <unicode/ucnv.h>
+ #include "types.h"
+ #include "myid3.h"
++#include "util.h"
+
+ /* Create a new empty tag */
+ id3_tag_t *id3_new( void )
+--- mpfc-1.3.8.1/libmpfc/logger.c
++++ mpfc-1.3.8.1/libmpfc/logger.c
+@@ -28,6 +28,8 @@
+ #include "cfg.h"
+ #include "logger.h"
+
++int logger_get_level( logger_t *log );
++
+ /* Initialize logger */
+ logger_t *logger_new( cfg_node_t *cfg_list, char *file_name )
+ {
+--- mpfc-1.3.8.1/libmpfcwnd/wnd.h
++++ mpfc-1.3.8.1/libmpfcwnd/wnd.h
+@@ -23,7 +23,6 @@
+ #ifndef __SG_MPFC_WND_H__
+ #define __SG_MPFC_WND_H__
+
+-#define _XOPEN_SOURCE_EXTENDED
+ #include <curses.h>
+ #include "types.h"
+ #include "cfg.h"
+--- mpfc-1.3.8.1/libmpfcwnd/wnd.c
++++ mpfc-1.3.8.1/libmpfcwnd/wnd.c
+@@ -29,6 +29,8 @@
+ #include "logger.h"
+ #include "wnd.h"
+ #include "wnd_root.h"
++#include "util.h"
++#include <curses.h>
+
+ /* Initialize window system and create root window */
+ wnd_t *wnd_init( cfg_node_t *cfg_list, logger_t *log )
+--- mpfc-1.3.8.1/libmpfcwnd/wnd_combobox.c
++++ mpfc-1.3.8.1/libmpfcwnd/wnd_combobox.c
+@@ -28,6 +28,8 @@
+ #include "wnd_dlgitem.h"
+ #include "wnd_editbox.h"
+ #include "wnd_hbox.h"
++#include "wnd_label.h"
++#include "util.h"
+
+ /* Create a new combo box */
+ combo_t *combo_new( wnd_t *parent, char *id, char *text, char letter,
+--- mpfc-1.3.8.1/libmpfcwnd/wnd_filebox.c
++++ mpfc-1.3.8.1/libmpfcwnd/wnd_filebox.c
+@@ -24,7 +24,6 @@
+ #include <fnmatch.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+-#define __USE_GNU
+ #include <string.h>
+ #include <unistd.h>
+ #include "types.h"
+@@ -33,6 +32,8 @@
+ #include "wnd_editbox.h"
+ #include "wnd_filebox.h"
+ #include "wnd_hbox.h"
++#include "wnd_label.h"
++#include "util.h"
+
+ /* Create a new file box */
+ filebox_t *filebox_new( wnd_t *parent, char *id, char *text, char letter,
+--- mpfc-1.3.8.1/libmpfcwnd/wnd_mouse.c
++++ mpfc-1.3.8.1/libmpfcwnd/wnd_mouse.c
+@@ -27,6 +27,7 @@
+ #include <stdlib.h>
+ #include <string.h>
+ #include "wnd.h"
++#include "util.h"
+
+ /* Initialize mouse */
+ wnd_mouse_data_t *wnd_mouse_init( wnd_global_data_t *global )
+--- mpfc-1.3.8.1/libmpfcwnd/wnd_print.c
++++ mpfc-1.3.8.1/libmpfcwnd/wnd_print.c
+@@ -32,6 +32,7 @@
+ #include "types.h"
+ #include "wnd.h"
+ #include "wnd_print.h"
++#include "util.h"
+
+ /* Move cursor to a specified position */
+ void wnd_move( wnd_t *wnd, wnd_move_style_t style, int x, int y )
+--- mpfc-1.3.8.1/libmpfcwnd/wnd_repval.c
++++ mpfc-1.3.8.1/libmpfcwnd/wnd_repval.c
+@@ -25,6 +25,7 @@
+ #include "wnd_dialog.h"
+ #include "wnd_editbox.h"
+ #include "wnd_repval.h"
++#include "wnd_label.h"
+
+ /* Create a repeat value dialog */
+ dialog_t *wnd_repval_new( wnd_t *parent, void *on_ok, int dig )
+--- mpfc-1.3.8.1/src/browser.c
++++ mpfc-1.3.8.1/src/browser.c
+@@ -24,6 +24,7 @@
+ #include <glob.h>
+ #include <string.h>
+ #include <sys/types.h>
++#include <fnmatch.h>
+ #include "types.h"
+ #include "browser.h"
+ #include "help_screen.h"
+--- mpfc-1.3.8.1/src/info_rw_thread.c
++++ mpfc-1.3.8.1/src/info_rw_thread.c
+@@ -27,6 +27,7 @@
+ #include "info_rw_thread.h"
+ #include "player.h"
+ #include "song.h"
++#include "util.h"
+
+ /* Thread queue */
+ irw_queue_t *irw_head, *irw_tail;
+--- mpfc-1.3.8.1/src/player.c
++++ mpfc-1.3.8.1/src/player.c
+@@ -35,6 +35,7 @@
+ #include "command.h"
+ #include "eqwnd.h"
+ #include "file.h"
++#include "genp.h"
+ #include "help_screen.h"
+ #include "logger.h"
+ #include "logger_view.h"
+@@ -57,8 +58,13 @@
+ #include "wnd_listbox.h"
+ #include "wnd_multiview_dialog.h"
+ #include "wnd_radio.h"
++#include "wnd_repval.h"
+ #include "wnd_root.h"
+ #include "xconvert.h"
++#include "info_rw_thread.h"
++
++void pmng_hook( pmng_t *pmng, char *hook );
++void outp_set_mixer_type( out_plugin_t *p, plugin_mixer_type_t type );
+
+ /*****
+ *
+--- mpfc-1.3.8.1/src/plist.c
++++ mpfc-1.3.8.1/src/plist.c
+@@ -36,6 +36,7 @@
+ #include "util.h"
+ #include "undo.h"
+ #include "wnd.h"
++#include "info_rw_thread.h"
+
+ extern void pmng_hook( pmng_t *pmng, char *hook );
+
+--- mpfc-1.3.8.1/src/util.h
++++ mpfc-1.3.8.1/src/util.h
+@@ -26,6 +26,8 @@
+ #include <stdio.h>
+ #include "types.h"
+
++int mbslen( char *str );
++
+ /* Write message to log file */
+ void util_log( char *format, ... );
+
+--- mpfc-1.3.8.1/src/vfs.h
++++ mpfc-1.3.8.1/src/vfs.h
+@@ -36,6 +36,7 @@
+ } vfs_t;
+
+ /* Check that input plugin uses VFS */
++dword inp_get_flags( in_plugin_t *p );
+ #define VFS_INP_HAS(inp) (inp_get_flags(inp) & INP_VFS)
+
+ /* Get logger object */
diff --git a/media-sound/mpfc/files/mpfc-gcc4.patch b/media-sound/mpfc/files/mpfc-gcc4.patch
new file mode 100644
index 000000000000..5cb1efb6834b
--- /dev/null
+++ b/media-sound/mpfc/files/mpfc-gcc4.patch
@@ -0,0 +1,13 @@
+--- mpfc-1.3.7/plugins/input/audiocd/audiocd.c.old 2006-11-05 21:13:25.000000000 +0100
++++ mpfc-1.3.7/plugins/input/audiocd/audiocd.c 2006-11-05 21:13:35.000000000 +0100
+@@ -60,8 +60,8 @@
+ /* Tracks information array */
+ struct acd_trk_info_t acd_tracks_info[ACD_MAX_TRACKS];
+ int acd_num_tracks = 0;
+-static int acd_cur_track = -1;
+-static bool_t acd_info_read = FALSE;
++int acd_cur_track = -1;
++bool_t acd_info_read = FALSE;
+
+ /* Current time */
+ static int acd_time = 0;
diff --git a/media-sound/mpfc/metadata.xml b/media-sound/mpfc/metadata.xml
new file mode 100644
index 000000000000..0a33c89e6992
--- /dev/null
+++ b/media-sound/mpfc/metadata.xml
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+ <email>sound@gentoo.org</email>
+ <name>Gentoo Sound project</name>
+ </maintainer>
+ <use>
+ <flag name="wav">Enable wav audio codec support</flag>
+ </use>
+ <upstream>
+ <remote-id type="sourceforge">mpfc</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/media-sound/mpfc/mpfc-1.3.7-r1.ebuild b/media-sound/mpfc/mpfc-1.3.7-r1.ebuild
new file mode 100644
index 000000000000..9dc80425d13e
--- /dev/null
+++ b/media-sound/mpfc/mpfc-1.3.7-r1.ebuild
@@ -0,0 +1,55 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=2
+inherit autotools eutils
+
+DESCRIPTION="Music Player For Console"
+HOMEPAGE="http://mpfc.sourceforge.net/"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 ppc x86"
+IUSE="alsa gpm mad vorbis oss wav cdda nls"
+
+RDEPEND="alsa? ( >=media-libs/alsa-lib-0.9.0 )
+ gpm? ( >=sys-libs/gpm-1.19.3 )
+ mad? ( media-libs/libmad )
+ vorbis? ( media-libs/libvorbis )"
+DEPEND="${RDEPEND}"
+
+src_prepare() {
+ sed -i \
+ -e 's:../src/file.h ../src/file.h:../src/file.h:' \
+ libmpfc/Makefile.am || die #335449
+
+ epatch "${FILESDIR}"/${P}-libdir.patch \
+ "${FILESDIR}"/${PN}-gcc4.patch \
+ "${FILESDIR}"/${P}-mathlib.patch \
+ "${FILESDIR}"/${P}-asneeded.patch \
+ "${FILESDIR}"/${P}-INT_MAX.patch
+
+ AT_M4DIR="m4" eautoreconf
+}
+
+src_configure() {
+ econf \
+ $(use_enable alsa) \
+ $(use_enable gpm) \
+ $(use_enable mad mp3) \
+ $(use_enable vorbis ogg) \
+ $(use_enable oss) \
+ $(use_enable wav) \
+ $(use_enable cdda audiocd) \
+ $(use_enable nls)
+}
+
+src_install() {
+ emake DESTDIR="${D}" install || die
+
+ insinto /etc
+ doins mpfcrc || die
+
+ dodoc AUTHORS ChangeLog NEWS README
+}
diff --git a/media-sound/mpfc/mpfc-1.3.8.1-r2.ebuild b/media-sound/mpfc/mpfc-1.3.8.1-r2.ebuild
new file mode 100644
index 000000000000..45a4bd4c4cbb
--- /dev/null
+++ b/media-sound/mpfc/mpfc-1.3.8.1-r2.ebuild
@@ -0,0 +1,57 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit autotools eutils
+
+DESCRIPTION="Music Player For Console"
+HOMEPAGE="http://mpfc.sourceforge.net/"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86"
+IUSE="alsa cdda flac gpm mad nls oss static-libs vorbis wav"
+
+RDEPEND="alsa? ( >=media-libs/alsa-lib-0.9.0 )
+ flac? ( media-libs/flac )
+ gpm? ( >=sys-libs/gpm-1.19.3 )
+ mad? ( media-libs/libmad )
+ vorbis? ( media-libs/libvorbis )
+ sys-libs/ncurses:0=[unicode]
+ dev-libs/icu:="
+DEPEND="${RDEPEND}"
+
+PATCHES=(
+ "${FILESDIR}/${P}-fix-underlinking.patch"
+ "${FILESDIR}/${P}-qa-implicit-declarations.patch"
+)
+
+src_prepare() {
+ default
+ eautoreconf
+}
+
+src_configure() {
+ econf \
+ $(use_enable alsa) \
+ $(use_enable cdda audiocd) \
+ $(use_enable flac) \
+ $(use_enable gpm) \
+ $(use_enable mad mp3) \
+ $(use_enable nls) \
+ $(use_enable oss) \
+ $(use_enable static-libs static) \
+ $(use_enable vorbis ogg) \
+ $(use_enable wav)
+}
+
+src_install() {
+ default
+
+ insinto /etc
+ doins mpfcrc
+
+ prune_libtool_files --all
+}