2001-10-16 15:21:53 +02:00
|
|
|
# New ports collection makefile for: liba52
|
|
|
|
# Date created: Tue Oct 16 10:43:56 BRST 2001
|
|
|
|
# Whom: Mario Sergio Fujikawa Ferreira <lioux@FreeBSD.org>
|
|
|
|
#
|
|
|
|
# $FreeBSD$
|
|
|
|
#
|
|
|
|
|
|
|
|
PORTNAME= liba52
|
2002-08-07 02:12:48 +02:00
|
|
|
PORTVERSION= 0.7.4
|
2004-02-04 06:21:48 +01:00
|
|
|
PORTREVISION= 1
|
2001-10-16 15:21:53 +02:00
|
|
|
CATEGORIES= audio
|
|
|
|
MASTER_SITES= http://liba52.sourceforge.net/files/
|
|
|
|
DISTNAME= a52dec-${PORTVERSION:S/.b/b/}
|
|
|
|
|
|
|
|
MAINTAINER= lioux@FreeBSD.org
|
2003-02-23 20:58:35 +01:00
|
|
|
COMMENT= A free library for decoding ATSC A/52 streams, aka AC-3
|
2001-10-16 15:21:53 +02:00
|
|
|
|
2001-12-02 18:41:02 +01:00
|
|
|
USE_GMAKE= yes
|
2002-07-03 19:33:24 +02:00
|
|
|
USE_REINPLACE= yes
|
2001-10-16 15:21:53 +02:00
|
|
|
GNU_CONFIGURE= yes
|
|
|
|
CONFIGURE_ARGS= --disable-oss --enable-shared
|
2004-03-14 07:17:56 +01:00
|
|
|
USE_LIBTOOL_VER= 13
|
2003-02-06 11:20:25 +01:00
|
|
|
INSTALLS_SHLIB= yes
|
2001-10-16 15:21:53 +02:00
|
|
|
|
2003-03-26 19:21:52 +01:00
|
|
|
.if !defined(WITHOUT_DJBFFT) && !defined(PACKAGE_BUILDING)
|
2002-05-16 00:54:33 +02:00
|
|
|
BUILD_DEPENDS+= ${LOCALBASE}/lib/libdjbfft.a:${PORTSDIR}/math/djbfft
|
2002-05-16 04:16:24 +02:00
|
|
|
RUN_DEPENDS+= ${LOCALBASE}/lib/libdjbfft.a:${PORTSDIR}/math/djbfft
|
2002-05-16 00:54:33 +02:00
|
|
|
|
2003-10-27 10:11:28 +01:00
|
|
|
CONFIGURE_ENV+= CFLAGS="${CFLAGS} -I${LOCALBASE}/include" \
|
2002-05-16 00:54:33 +02:00
|
|
|
LDFLAGS="${LDFLAGS} -L${LOCALBASE}/lib"
|
|
|
|
CONFIGURE_ARGS+= --enable-djbfft
|
|
|
|
.endif
|
|
|
|
|
2001-10-16 15:21:53 +02:00
|
|
|
MAN1= a52dec.1 extract_a52.1
|
|
|
|
|
2001-10-26 18:13:20 +02:00
|
|
|
HEADER_FILES= liba52/a52_internal.h
|
|
|
|
|
2001-10-16 15:21:53 +02:00
|
|
|
pre-everything::
|
|
|
|
.ifndef(WITH_OPTIMIZED_CFLAGS)
|
|
|
|
@${ECHO_MSG} ">>>"
|
|
|
|
@${ECHO_MSG} ">>> You can enable extra optimizations by defining WITH_OPTIMIZED_CFLAGS."
|
|
|
|
@${ECHO_MSG} ">>> For example, 'make WITH_OPTIMIZED_CFLAGS=yes'"
|
|
|
|
@${ECHO_MSG} ">>>"
|
|
|
|
.endif
|
2002-05-16 00:54:33 +02:00
|
|
|
.ifndef(WITHOUT_DJBFFT)
|
|
|
|
@${ECHO_MSG} '>>>'
|
|
|
|
@${ECHO_MSG} '>>> You can disable djbfft optimized FFT routines by defining WITHOUT_DJBFFT.'
|
|
|
|
@${ECHO_MSG} ">>> For example, 'make WITHOUT_DJBFFT=yes'"
|
|
|
|
@${ECHO_MSG} '>>>'
|
|
|
|
.endif
|
2001-10-16 15:21:53 +02:00
|
|
|
|
2002-01-20 19:56:47 +01:00
|
|
|
post-patch:
|
|
|
|
.ifndef(WITH_OPTIMIZED_CFLAGS)
|
2002-07-03 19:33:24 +02:00
|
|
|
@${REINPLACE_CMD} -E -e 's!-O3!${CFLAGS}!' -e 's!-mcpu=[^"]+"!"!' \
|
2002-01-20 19:56:47 +01:00
|
|
|
${CONFIGURE_WRKSRC}/${CONFIGURE_SCRIPT}
|
|
|
|
.endif
|
2002-05-16 00:54:33 +02:00
|
|
|
.ifndef(WITHOUT_DJBFFT)
|
2002-07-03 19:33:24 +02:00
|
|
|
@${REINPLACE_CMD} -E -e 's|(fftc4.h)|djbfft/\1|' ${WRKSRC}/liba52/imdct.c
|
2002-05-16 00:54:33 +02:00
|
|
|
.endif
|
2002-01-20 19:56:47 +01:00
|
|
|
|
2001-10-16 15:21:53 +02:00
|
|
|
post-configure:
|
2003-06-27 00:58:32 +02:00
|
|
|
@${LN} -sf ${LIBTOOL} ${WRKSRC}/libtool
|
2001-10-16 15:21:53 +02:00
|
|
|
|
|
|
|
post-install:
|
|
|
|
.ifndef(NOPORTDOCS)
|
|
|
|
@${MKDIR} ${DOCSDIR}
|
|
|
|
@${INSTALL_DATA} ${WRKSRC}/doc/liba52.txt ${DOCSDIR}
|
|
|
|
.endif
|
2001-10-26 18:13:20 +02:00
|
|
|
.for file in ${HEADER_FILES}
|
|
|
|
@${INSTALL_DATA} ${WRKSRC}/${file} ${PREFIX}/include/a52dec
|
|
|
|
.endfor
|
2001-10-16 15:21:53 +02:00
|
|
|
|
|
|
|
.include <bsd.port.mk>
|