summaryrefslogtreecommitdiffstats
path: root/audio/gtkpod/Makefile
diff options
context:
space:
mode:
authorpav <pav@FreeBSD.org>2004-05-12 08:43:58 +0000
committerpav <pav@FreeBSD.org>2004-05-12 08:43:58 +0000
commit45ca8fa87bb06e71638574563f0eb2a0e8c94e93 (patch)
tree193d610d569bb1b3fc9fb475ea5d74bfc3ea0ab2 /audio/gtkpod/Makefile
parent01083168f0b7c2a4071e8c5a9a71f50c2f46a587 (diff)
downloadFreeBSD-ports-45ca8fa87bb06e71638574563f0eb2a0e8c94e93.zip
FreeBSD-ports-45ca8fa87bb06e71638574563f0eb2a0e8c94e93.tar.gz
- Add AAC support, optionally either with faad or mpeg4ip
PR: ports/66356 Submitted by: ume Approved by: maintainer
Diffstat (limited to 'audio/gtkpod/Makefile')
-rw-r--r--audio/gtkpod/Makefile42
1 files changed, 31 insertions, 11 deletions
diff --git a/audio/gtkpod/Makefile b/audio/gtkpod/Makefile
index f661dcf..b55e2a4 100644
--- a/audio/gtkpod/Makefile
+++ b/audio/gtkpod/Makefile
@@ -18,16 +18,6 @@ COMMENT= GUI for Apple iPods using GTK2
LIB_DEPENDS= id3tag.2:${PORTSDIR}/audio/libid3tag
RUN_DEPENDS= mp3gain:${PORTSDIR}/audio/mp3gain
-.if defined(WITH_AAC)
-BROKEN= "need mpeg4ip-1.0 for AAC support."
-#LIB_DEPENDS+= mp4v2.1:${PORTSDIR}/multimedia/mpeg4ip
-#.else
-#pre-everything::
-# @${ECHO_MSG}
-# @${ECHO_MSG} "To enable AAC support define the WITH_AAC knob."
-# @${ECHO_MSG}
-.endif
-
USE_REINPLACE= yes
USE_X_PREFIX= yes
@@ -35,9 +25,39 @@ USE_GMAKE= yes
USE_GNOME= gtk20
GNU_CONFIGURE= yes
+.include <bsd.port.pre.mk>
+
+.if exists(${LOCALBASE}/lib/libmp4v2.so)
+.if exists(${LOCALBASE}/include/mpeg4ip_config.h)
+WITH_AAC= YES
+.else
+WITH_FAAD= YES
+.endif
+.endif
+.if defined(WITH_AAC) && defined(WITH_FAAD)
+BROKEN= "WITH_AAC and WITH_FAAD are exclusive."
+.endif
+.if defined(WITH_AAC)
+LIB_DEPENDS+= mp4v2.0:${PORTSDIR}/multimedia/mpeg4ip
+.endif
+.if defined(WITH_FAAD)
+LIB_DEPENDS+= mp4v2.0:${PORTSDIR}/audio/faad
+.endif
+
CONFIGURE_ENV+= CPPFLAGS="-I${LOCALBASE}/include"
CONFIGURE_ENV+= LDFLAGS="-L${LOCALBASE}/lib"
+.if !defined(WITH_AAC) && !defined(WITH_FAAD)
+pre-everything::
+ @${ECHO_MSG}
+ @${ECHO_MSG} "To enable AAC support with mpeg4ip define the WITH_AAC knob."
+ @${ECHO_MSG} "To enable AAC support with faad2 define the WITH_FAAD knob."
+ @${ECHO_MSG}
+.endif
+
+post-patch:
+ @${CP} ${FILESDIR}/systems.h ${WRKSRC}/src
+
pre-configure:
# install locale correctly (share dir instead of lib dir)
@${REINPLACE_CMD} -e 's|DATADIRNAME=lib|DATADIRNAME=share|' \
@@ -53,4 +73,4 @@ post-install:
@${INSTALL_DATA} ${WRKSRC}/TODOandBUGS.txt ${DOCSDIR}
.endif
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
OpenPOWER on IntegriCloud