- Update to version 2.7
PR: ports/131836 Submitted by: KATO Tsuguru <tkato432@yahoo.com>
This commit is contained in:
parent
38642b095a
commit
05adb12dd5
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=228790
6 changed files with 78 additions and 152 deletions
|
@ -5,59 +5,11 @@
|
|||
# $FreeBSD$
|
||||
#
|
||||
|
||||
PORTNAME= faad2
|
||||
PORTVERSION= 2.0
|
||||
PORTREVISION= 8
|
||||
CATEGORIES= audio
|
||||
MASTER_SITES= SF
|
||||
MASTER_SITE_SUBDIR= faac
|
||||
PKGNAMEPREFIX= xmms-
|
||||
|
||||
MAINTAINER= ports@FreeBSD.org
|
||||
COMMENT= XMMS plugin for faad
|
||||
|
||||
BUILD_DEPENDS= xmms-config:${PORTSDIR}/multimedia/xmms
|
||||
LIB_DEPENDS= id3-3.8.3:${PORTSDIR}/audio/id3lib \
|
||||
xmms.4:${PORTSDIR}/multimedia/xmms \
|
||||
faad.2:${PORTSDIR}/audio/faad \
|
||||
mp4v2.0:${PORTSDIR}/multimedia/mpeg4ip-libmp4v2
|
||||
PATCH_DEPENDS= ${BUILD_DEPENDS}
|
||||
MASTERDIR= ${.CURDIR}
|
||||
|
||||
WRKSRC= ${WRKDIR}/${PORTNAME}
|
||||
|
||||
USE_AUTOTOOLS= automake:15 autoheader:262 autoconf:262 libtool:15
|
||||
AUTOMAKE_ARGS= --add-missing
|
||||
USE_GNOME= gtk12
|
||||
USE_GMAKE= yes
|
||||
|
||||
CONFIGURE_ARGS= --with-xmms --with-mp4v2
|
||||
CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include ${PTHREAD_CFLAGS} -DHAVE_GTK" \
|
||||
LDFLAGS="-L${LOCALBASE}/lib ${PTHREAD_LIBS}" \
|
||||
|
||||
DESCR= ${PORTSDIR}/audio/faad/pkg-descr
|
||||
PLIST_FILES= lib/xmms/Input/libmp4.a \
|
||||
lib/xmms/Input/libmp4.la \
|
||||
lib/xmms/Input/libmp4.so
|
||||
|
||||
BUILD_WRKSRC= ${WRKSRC}/plugins/xmms/src
|
||||
INSTALL_WRKSRC= ${WRKSRC}/plugins/xmms/src
|
||||
|
||||
pre-patch: build-depends
|
||||
|
||||
post-patch:
|
||||
@${REINPLACE_CMD} -e 's|-lpthread|${PTHREAD_LIBS}|' ${WRKSRC}/plugins/xmms/src/Makefile.am
|
||||
@${REINPLACE_CMD} -e 's|"faad.h"|<faad.h>|; s|"mp4.h"|<mp4.h>|' \
|
||||
${WRKSRC}/plugins/xmms/src/libmp4.c
|
||||
# make sure everything is prepared prior to configure stage
|
||||
# pre-configure will not work since *AUTO* tools happen in-between
|
||||
@cd ${WRKSRC}; ${ACLOCAL} -I ${ACLOCAL_DIR} -I .; \
|
||||
${SETENV} ${SCRIPTS_ENV} ${LIBTOOLIZE} --automake
|
||||
@${REINPLACE_CMD} -e 's|$$lt_target|$$host|' \
|
||||
-e '/^_LT_AC_SHELL_INIT/d' ${WRKSRC}/aclocal.m4
|
||||
# CFLAGS safeness
|
||||
@${FIND} ${WRKSRC} -type f -name Makefile.am | \
|
||||
${XARGS} -n 5 -x \
|
||||
${REINPLACE_CMD} -e \
|
||||
's|-O2|${CFLAGS}|'
|
||||
|
||||
.include <bsd.port.mk>
|
||||
.include "${MASTERDIR}/Makefile.inc"
|
||||
|
|
47
audio/xmms-faad/Makefile.inc
Normal file
47
audio/xmms-faad/Makefile.inc
Normal file
|
@ -0,0 +1,47 @@
|
|||
# $FreeBSD$
|
||||
|
||||
PORTNAME= faad2
|
||||
PORTVERSION= 2.7
|
||||
CATEGORIES= audio
|
||||
MASTER_SITES= SFE/faac
|
||||
|
||||
BUILD_DEPENDS= faad2>=2.7:${PORTSDIR}/audio/faad
|
||||
RUN_DEPENDS= faad2>=2.7:${PORTSDIR}/audio/faad
|
||||
|
||||
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION}/plugins/xmms/src
|
||||
|
||||
USE_BZIP2= yes
|
||||
WANT_GNOME= yes
|
||||
|
||||
DESCR= ${PORTSDIR}/audio/faad/pkg-descr
|
||||
PLIST_FILES= ${PLUGINS_DIR:S,^${PREFIX}/,,}/libmp4.so
|
||||
|
||||
.include <bsd.port.pre.mk>
|
||||
|
||||
.if ${PKGNAMEPREFIX} == "bmp-"
|
||||
LIB_DEPENDS+= beep.2:${PORTSDIR}/multimedia/beep-media-player
|
||||
USE_GNOME+= gtk20
|
||||
PLUGINS_DIR= ${PREFIX}/lib/bmp/Input
|
||||
EXTRA_CFLAGS= `pkg-config --cflags bmp` -DHAVE_BMP
|
||||
EXTRA_LDFLAGS= `pkg-config --libs bmp`
|
||||
.endif
|
||||
|
||||
.if ${PKGNAMEPREFIX} == "xmms-"
|
||||
LIB_DEPENDS+= xmms.4:${PORTSDIR}/multimedia/xmms
|
||||
USE_GNOME+= gtk12
|
||||
PLUGINS_DIR= ${PREFIX}/lib/xmms/Input
|
||||
EXTRA_CFLAGS= `xmms-config --cflags`
|
||||
EXTRA_LDFLAGS+= `xmms-config --libs`
|
||||
.endif
|
||||
|
||||
do-build:
|
||||
cd ${WRKSRC} && ${CC} ${CFLAGS} -fPIC -shared \
|
||||
-I${LOCALBASE}/include -DHAVE_STDINT_H \
|
||||
${EXTRA_CFLAGS} *.c -o libmp4.so \
|
||||
-L${LOCALBASE}/lib -lfaad -lmp4ff \
|
||||
${EXTRA_LDFLAGS}
|
||||
|
||||
do-install:
|
||||
cd ${WRKSRC}; ${INSTALL_DATA} libmp4.so ${PLUGINS_DIR}
|
||||
|
||||
.include <bsd.port.post.mk>
|
|
@ -1,3 +1,3 @@
|
|||
MD5 (faad2-2.0.tar.gz) = 1a6f79365f2934a4888b210ef47a3a07
|
||||
SHA256 (faad2-2.0.tar.gz) = a62a4622862252e53e0dd58c3b0307a138f5100304e07bf50c8aee31a68ab861
|
||||
SIZE (faad2-2.0.tar.gz) = 766660
|
||||
MD5 (faad2-2.7.tar.bz2) = 4c332fa23febc0e4648064685a3d4332
|
||||
SHA256 (faad2-2.7.tar.bz2) = 14561b5d6bc457e825bfd3921ae50a6648f377a9396eaf16d4b057b39a3f63b5
|
||||
SIZE (faad2-2.7.tar.bz2) = 901043
|
||||
|
|
26
audio/xmms-faad/files/patch-mp4_utils.c
Normal file
26
audio/xmms-faad/files/patch-mp4_utils.c
Normal file
|
@ -0,0 +1,26 @@
|
|||
--- mp4_utils.c.orig 2004-10-18 05:44:51.000000000 +0900
|
||||
+++ mp4_utils.c 2009-02-12 02:53:15.000000000 +0900
|
||||
@@ -3,15 +3,22 @@
|
||||
*/
|
||||
|
||||
#include "mp4ff.h"
|
||||
-#include "faad.h"
|
||||
+#include "neaacdec.h"
|
||||
|
||||
#include <gtk/gtk.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <stdlib.h>
|
||||
+
|
||||
+#if defined(HAVE_BMP)
|
||||
+#include <bmp/plugin.h>
|
||||
+#include <bmp/titlestring.h>
|
||||
+#include <bmp/util.h>
|
||||
+#else
|
||||
#include <xmms/plugin.h>
|
||||
#include <xmms/titlestring.h>
|
||||
#include <xmms/util.h>
|
||||
+#endif /*HAVE_BMP*/
|
||||
|
||||
const char *mp4AudioNames[]=
|
||||
{
|
|
@ -1,12 +0,0 @@
|
|||
--- plugins/xmms/src/Makefile.am.orig Wed Sep 29 13:33:13 2004
|
||||
+++ plugins/xmms/src/Makefile.am Wed Sep 29 13:34:27 2004
|
||||
@@ -5,8 +5,7 @@
|
||||
`$(GTK_CONFIG) --cflags` -DHAVE_GLIB_H=1 \
|
||||
-I$(top_srcdir)/include -I$(top_srcdir)/common/mp4v2
|
||||
|
||||
-libmp4_la_LIBADD = $(top_builddir)/libfaad/libfaad.la \
|
||||
- $(top_builddir)/common/mp4v2/libmp4v2.la
|
||||
+LIBS= -lfaad -lmp4v2
|
||||
|
||||
libmp4_la_LDFLAGS = -module -avoid-version `$(XMMS_CONFIG) --libs` \
|
||||
`$(GTK_CONFIG) --libs` -lpthread -lstdc++
|
|
@ -1,87 +0,0 @@
|
|||
--- plugins/xmms/src/mp4_utils.c.orig Thu Dec 4 05:07:56 2003
|
||||
+++ plugins/xmms/src/mp4_utils.c Fri Jul 29 11:11:21 2005
|
||||
@@ -6,23 +6,35 @@
|
||||
|
||||
const char *mp4AudioNames[]=
|
||||
{
|
||||
- "MPEG-1 Audio Layers 1,2 or 3",
|
||||
- "MPEG-2 low biterate (MPEG-1 extension) - MP3",
|
||||
- "MPEG-2 AAC Main Profile",
|
||||
- "MPEG-2 AAC Low Complexity profile",
|
||||
- "MPEG-2 AAC SSR profile",
|
||||
- "MPEG-4 audio (MPEG-4 AAC)",
|
||||
- 0
|
||||
+ "MPEG-4 AAC Main profile",
|
||||
+ "MPEG-4 AAC Low Complexity profile",
|
||||
+ "MPEG-4 AAC SSR profile",
|
||||
+ "MPEG-4 AAC Long Term Prediction profile",
|
||||
+ "MPEG-4 AAC Scalable",
|
||||
+ "MPEG-4 CELP",
|
||||
+ "MPEG-4 HVXC",
|
||||
+ "MPEG-4 Text to Speech",
|
||||
+ "MPEG-4 Main Synthetic profile",
|
||||
+ "MPEG-4 Wavetable Synthesis profile",
|
||||
+ "MPEG-4 MIDI profile",
|
||||
+ "MPEG-4 Algorithmic Synthesis and Audio FX profile",
|
||||
+ NULL
|
||||
};
|
||||
|
||||
const u_int8_t mp4AudioTypes[] =
|
||||
{
|
||||
- MP4_MPEG1_AUDIO_TYPE, // 0x6B
|
||||
- MP4_MPEG2_AUDIO_TYPE, // 0x69
|
||||
- MP4_MPEG2_AAC_MAIN_AUDIO_TYPE, // 0x66
|
||||
- MP4_MPEG2_AAC_LC_AUDIO_TYPE, // 0x67
|
||||
- MP4_MPEG2_AAC_SSR_AUDIO_TYPE, // 0x68
|
||||
- MP4_MPEG4_AUDIO_TYPE, // 0x40
|
||||
+ MP4_MPEG4_AAC_MAIN_AUDIO_TYPE,
|
||||
+ MP4_MPEG4_AAC_LC_AUDIO_TYPE,
|
||||
+ MP4_MPEG4_AAC_SSR_AUDIO_TYPE,
|
||||
+ MP4_MPEG4_AAC_LTP_AUDIO_TYPE,
|
||||
+ MP4_MPEG4_AAC_SCALABLE_AUDIO_TYPE,
|
||||
+ MP4_MPEG4_CELP_AUDIO_TYPE,
|
||||
+ MP4_MPEG4_HVXC_AUDIO_TYPE,
|
||||
+ MP4_MPEG4_TTSI_AUDIO_TYPE,
|
||||
+ MP4_MPEG4_MAIN_SYNTHETIC_AUDIO_TYPE,
|
||||
+ MP4_MPEG4_WAVETABLE_AUDIO_TYPE,
|
||||
+ MP4_MPEG4_MIDI_AUDIO_TYPE,
|
||||
+ MP4_MPEG4_ALGORITHMIC_FX_AUDIO_TYPE,
|
||||
0
|
||||
};
|
||||
|
||||
@@ -54,7 +66,7 @@
|
||||
const char *trackType = MP4GetTrackType(file, trackID);
|
||||
if(!strcmp(trackType, MP4_AUDIO_TRACK_TYPE)){//we found audio track !
|
||||
int j=0;
|
||||
- u_int8_t audiotype = MP4GetTrackAudioType(file, trackID);
|
||||
+ u_int8_t audiotype = MP4GetTrackAudioMpeg4Type(file, trackID);
|
||||
while(mp4AudioTypes[j]){ // what kind of audio is ?
|
||||
if(mp4AudioTypes[j] == audiotype){
|
||||
if(mp4AudioTypes[j] == MP4_MPEG4_AUDIO_TYPE){//MPEG4 audio ok
|
||||
@@ -64,9 +76,9 @@
|
||||
}
|
||||
else{
|
||||
printf("%s\n", mp4AudioNames[j]);
|
||||
- if (mp4AudioTypes[j]== MP4_MPEG2_AAC_LC_AUDIO_TYPE ||
|
||||
- mp4AudioTypes[j]== MP4_MPEG2_AAC_MAIN_AUDIO_TYPE ||
|
||||
- mp4AudioTypes[j]== MP4_MPEG2_AAC_SSR_AUDIO_TYPE)
|
||||
+ if (mp4AudioTypes[j]== MP4_MPEG4_AAC_MAIN_AUDIO_TYPE ||
|
||||
+ mp4AudioTypes[j]== MP4_MPEG4_AAC_LC_AUDIO_TYPE ||
|
||||
+ mp4AudioTypes[j]== MP4_MPEG4_AAC_SSR_AUDIO_TYPE)
|
||||
return(trackID);
|
||||
return(-1);
|
||||
}
|
||||
@@ -126,10 +138,11 @@
|
||||
printf("Track %d, %s", trackID, trackType);
|
||||
if(!strcmp(trackType, MP4_AUDIO_TRACK_TYPE)){//we found audio track !
|
||||
int j=0;
|
||||
- u_int8_t audiotype = MP4GetTrackAudioType(mp4file, trackID);
|
||||
+ u_int8_t audiotype = MP4GetTrackAudioMpeg4Type(mp4file, trackID);
|
||||
while(mp4AudioTypes[j]){ // what kind of audio is ?
|
||||
if(mp4AudioTypes[j] == audiotype){
|
||||
- if(mp4AudioTypes[j] == MP4_MPEG4_AUDIO_TYPE){
|
||||
+ if(mp4AudioTypes[j] == MP4_MPEG4_AUDIO_TYPE ||
|
||||
+ mp4AudioTypes[j] == MP4_MPEG4_AAC_LC_AUDIO_TYPE){
|
||||
audiotype = MP4GetTrackAudioMpeg4Type(mp4file, trackID);
|
||||
g_print(" %s", mpeg4AudioNames[audiotype]);
|
||||
}
|
Loading…
Reference in a new issue