aboutsummaryrefslogtreecommitdiff
path: root/audio/vgmplay
diff options
context:
space:
mode:
authorSteve Wills <swills@FreeBSD.org>2019-01-17 12:45:34 +0000
committerSteve Wills <swills@FreeBSD.org>2019-01-17 12:45:34 +0000
commit1546c8a8e02e05f6ed9a88dbc56cd3cea9bd5475 (patch)
treee29208d3a707ab69807a696eaa149292611cf725 /audio/vgmplay
parentd584ffc1d32a277597498732a6211b7f82eb613f (diff)
downloadports-1546c8a8e02e05f6ed9a88dbc56cd3cea9bd5475.tar.gz
ports-1546c8a8e02e05f6ed9a88dbc56cd3cea9bd5475.zip
audio/vgmplay: create port
The official and always up-to-date player for all VGM (Video Game Music) files. VGM is an audio file format for multiple video game platforms, such as Sega Master System, Game Gear, Mega Drive/Genesis, MSX, Neo Geo, IBM PC AT (Adlib/SoundBlaster), and has expanded to a variety of arcade system boards since its release. WWW: https://github.com/vgmrips/vgmplay PR: 234848 Submitted by: Hiroki Tagato <tagattie@yandex.com>
Notes
Notes: svn path=/head/; revision=490554
Diffstat (limited to 'audio/vgmplay')
-rw-r--r--audio/vgmplay/Makefile48
-rw-r--r--audio/vgmplay/distinfo3
-rw-r--r--audio/vgmplay/files/patch-Makefile12
-rw-r--r--audio/vgmplay/files/patch-Stream.c11
-rw-r--r--audio/vgmplay/pkg-descr7
5 files changed, 81 insertions, 0 deletions
diff --git a/audio/vgmplay/Makefile b/audio/vgmplay/Makefile
new file mode 100644
index 000000000000..d5813e1c4473
--- /dev/null
+++ b/audio/vgmplay/Makefile
@@ -0,0 +1,48 @@
+# $FreeBSD$
+
+PORTNAME= vgmplay
+PORTVERSION= 0.40.9
+CATEGORIES= audio
+MASTER_SITES= https://github.com/vgmrips/${PORTNAME}/releases/download/${PORTVERSION}/
+DISTNAME= ${PORTNAME:S/vgmp/VGMP/}_${PORTVERSION:S/.//:S/./-/}_src
+
+MAINTAINER= tagattie@yandex.com
+COMMENT= Command-line player for VGM (video game music) files
+
+LICENSE= GPLv2
+LICENSE_FILE= ${WRKSRC}/licenses/GPL.txt
+
+USES= 7z dos2unix gmake
+
+NO_WRKSUBDIR= yes
+
+OPTIONS_SINGLE= AUDIO
+OPTIONS_SINGLE_AUDIO= OSS LIBAO
+OPTIONS_DEFAULT= OSS
+
+OSS_DESC= Use OSS (/dev/dsp)
+LIBAO_DESC= Use libao
+
+OSS_MAKE_ENV+= USE_LIBAO=0
+LIBAO_MAKE_ENV+= USE_LIBAO=1
+LIBAO_LIB_DEPENDS= libao.so:audio/libao
+LIBAO_CFLAGS+= -I${LOCALBASE}/include
+LIBAO_LDFLAGS+= -L${LOCALBASE}/lib
+
+MAKE_ENV+= PREFIX=${LOCALBASE}
+
+PLIST_FILES= bin/vgmplay bin/vgm2pcm bin/vgm2wav man/man1/vgmplay.1.gz ${EXAMPLESDIR}/vgmplay.ini
+
+post-patch:
+ ${REINPLACE_CMD} -e 's/@//' ${WRKSRC}/Makefile
+ ${REINPLACE_CMD} -e 's|/usr/local|${LOCALBASE}|; s|/usr/share/vgmplay|${EXAMPLESDIR}|; s|VGMPlay|vgmplay|g;' ${WRKSRC}/vgmplay.1
+
+do-install:
+ ${INSTALL_PROGRAM} ${WRKSRC}/vgmplay ${STAGEDIR}${PREFIX}/bin
+ ${INSTALL_PROGRAM} ${WRKSRC}/vgm2pcm ${STAGEDIR}${PREFIX}/bin
+ ${INSTALL_PROGRAM} ${WRKSRC}/vgm2wav ${STAGEDIR}${PREFIX}/bin
+ ${INSTALL_MAN} ${WRKSRC}/vgmplay.1 ${STAGEDIR}${PREFIX}/man/man1
+ ${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
+ ${INSTALL_DATA} ${WRKSRC}/VGMPlay.ini ${STAGEDIR}${EXAMPLESDIR}/vgmplay.ini
+
+.include <bsd.port.mk>
diff --git a/audio/vgmplay/distinfo b/audio/vgmplay/distinfo
new file mode 100644
index 000000000000..015632fd1686
--- /dev/null
+++ b/audio/vgmplay/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1546946539
+SHA256 (VGMPlay_040-9_src.7z) = 4f799bb21ba288893a627b0c6d71db84e2d8a74ec8852a092845ad831de8e19a
+SIZE (VGMPlay_040-9_src.7z) = 586532
diff --git a/audio/vgmplay/files/patch-Makefile b/audio/vgmplay/files/patch-Makefile
new file mode 100644
index 000000000000..5979ec0b143e
--- /dev/null
+++ b/audio/vgmplay/files/patch-Makefile
@@ -0,0 +1,12 @@
+--- Makefile.orig 2019-01-11 06:06:08 UTC
++++ Makefile
+@@ -58,7 +58,9 @@ endif
+
+
+
++ifndef CC
+ CC = gcc
++endif
+ ifndef PREFIX
+ PREFIX = /usr/local
+ #PREFIX = $(HOME)/.local
diff --git a/audio/vgmplay/files/patch-Stream.c b/audio/vgmplay/files/patch-Stream.c
new file mode 100644
index 000000000000..722e0a797096
--- /dev/null
+++ b/audio/vgmplay/files/patch-Stream.c
@@ -0,0 +1,11 @@
+--- Stream.c.orig 2019-01-08 12:56:30 UTC
++++ Stream.c
+@@ -16,6 +16,8 @@
+ #include <fcntl.h>
+ #ifdef __NetBSD__
+ #include <sys/audioio.h>
++#elif defined(__FreeBSD__)
++#include <sys/soundcard.h>
+ #elif defined(__APPLE__) || defined(__OpenBSD__)
+ // nothing
+ #else
diff --git a/audio/vgmplay/pkg-descr b/audio/vgmplay/pkg-descr
new file mode 100644
index 000000000000..862c1918d2c1
--- /dev/null
+++ b/audio/vgmplay/pkg-descr
@@ -0,0 +1,7 @@
+The official and always up-to-date player for all VGM (Video Game
+Music) files. VGM is an audio file format for multiple video game
+platforms, such as Sega Master System, Game Gear, Mega Drive/Genesis,
+MSX, Neo Geo, IBM PC AT (Adlib/SoundBlaster), and has expanded to a
+variety of arcade system boards since its release.
+
+WWW: https://github.com/vgmrips/vgmplay