Prune audio/clementine-player
[dports.git] / audio / mbrolavox / Makefile
1 # Created by: trevor
2 # $FreeBSD$
3
4 PORTNAME=       mbrolavox
5 PORTVERSION=    3.0.1
6 PORTREVISION=   1
7 CATEGORIES=     audio accessibility
8 DISTFILES=      #
9 DIST_SUBDIR=    ${PORTNAME}
10
11 MAINTAINER=     ports@FreeBSD.org
12 COMMENT=        Voices for MBROLA voice synthesizer
13
14 USES=           zip:infozip
15 NO_BUILD=       yes
16 NO_ARCH=        yes
17 RESTRICTED=     No commercial nor military use, no sale
18 WRKSRC=         ${WRKDIR}/voices
19 PORTDATA=       *
20
21 VOICESCONF=     ${.CURDIR}/voices.conf
22
23 .include "Makefile.options"
24
25 .include <bsd.port.options.mk>
26
27 .for ii in ${PORT_OPTIONS}
28 .   if defined(FILE_${ii})
29 MASTER_SITES+=  http://www.tcts.fpms.ac.be/synthesis/mbrola/dba/${ii}/:${ii} \
30                 http://www.festvox.org/mbrola/dba/${ii}/:${ii} \
31                 http://mambo.ucsc.edu/psl/mbrola/dba/${ii}/:${ii}
32 DISTFILES+=     ${FILE_${ii}}:${ii}
33 FILEDIRS+=      ${ii}
34 MYFILES+=       ${FILE_${ii}}
35 .   endif
36 .endfor
37
38 .if empty(DISTFILES)
39 IGNORE= requires that at least one OPTION is selected
40 .endif
41
42 do-extract:
43         @${MKDIR} ${WRKSRC}
44 .for ii in ${MYFILES}
45         @${UNZIP_CMD} -qo ${DISTDIR}/${DIST_SUBDIR}/${ii} -d ${WRKSRC}
46 .endfor
47
48 do-install:
49         @cd ${WRKSRC} && ${COPYTREE_SHARE} . ${STAGEDIR}${DATADIR}
50
51 # Generates OPTIONS file from voices.conf -- really for maintainer use
52 # Only included for compatibility with anyone who wants to modify voices.conf
53
54 Makefile.options: ${.TARGET}.unsorted
55         ${ECHO_CMD} '# $$Free''BSD$$' > ${.TARGET}
56         ${ECHO_CMD} "# Autogenerated from ${VOICESCONF} using make ${.TARGET}" \
57                 >> ${.TARGET}
58         ${SORT} ${.ALLSRC} >> ${.TARGET}
59
60 Makefile.options.unsorted: ${VOICESCONF}
61         : > ${.TARGET}
62         IFS='|'; while read opt file define default; do \
63                 optdefine="$$optdefine $$opt"; \
64                 ${ECHO_CMD} "$${opt}_DESC=      $$define" >> ${.TARGET}; \
65                 ${ECHO_CMD} "FILE_$${opt}=      $$file" >> ${.TARGET}; \
66                 case $$default in \
67                 [Oo][Nn]) optdefault="$$optdefault $$opt" ;; \
68                 *) ;; \
69                 esac; \
70         done < ${.ALLSRC}; \
71         ${ECHO_CMD} $$optdefine | /usr/bin/fold -sw 50 | \
72                 ${SED} 's,^[[:space:]]*,OPTIONS_DEFINE+=        ,;s,[[:space:]]*$$,,' >> ${.TARGET}; \
73         [ -z "$$optdefault" ] || \
74                 ${ECHO_CMD} $$optdefault | /usr/bin/fold -sw 50 | \
75                 ${SED} 's,^[[:space:]]*,OPTIONS_DEFAULT+=       ,' >> ${.TARGET}
76
77 .include <bsd.port.mk>