diff options
author | jpaetzel <jpaetzel@FreeBSD.org> | 2010-08-18 00:13:59 +0800 |
---|---|---|
committer | jpaetzel <jpaetzel@FreeBSD.org> | 2010-08-18 00:13:59 +0800 |
commit | 9fcb56c431a48d0e48c9098ffa55e9d8e89d16d6 (patch) | |
tree | e28b8224c6a68dc2d7a8046eca4ab440652fdaaf /audio | |
parent | 2bad7959e0d783a18509f7cb401cef291133a7d3 (diff) | |
download | freebsd-ports-gnome-9fcb56c431a48d0e48c9098ffa55e9d8e89d16d6.tar.gz freebsd-ports-gnome-9fcb56c431a48d0e48c9098ffa55e9d8e89d16d6.tar.zst freebsd-ports-gnome-9fcb56c431a48d0e48c9098ffa55e9d8e89d16d6.zip |
Update this port to better fit the net/freeswitch metaport
PR: ports/149526
Submitted by: Eric F Crist <ecrist@secure-computing.net>
Diffstat (limited to 'audio')
-rw-r--r-- | audio/freeswitch-sounds/Makefile | 67 |
1 files changed, 33 insertions, 34 deletions
diff --git a/audio/freeswitch-sounds/Makefile b/audio/freeswitch-sounds/Makefile index 98fc96ab9f31..32356fc25d22 100644 --- a/audio/freeswitch-sounds/Makefile +++ b/audio/freeswitch-sounds/Makefile @@ -5,20 +5,21 @@ # $FreeBSD$ # -PORTNAME= freeswitch -PORTVERSION= 1.0.13 -CATEGORIES= audio +PORTNAME= freeswitch-sounds +PORTVERSION= 1.0.13 +CATEGORIES= audio MASTER_SITES= http://files.freeswitch.org/ -PKGNAMESUFFIX= -sounds -DIST_SUBDIR= freeswitch-sounds +DIST_SUBDIR= freeswitch-sounds -MAINTAINER= ecrist@secure-computing.net -COMMENT= FreeSwitch Sounds (All Bitrates) +MAINTAINER= ecrist@secure-computing.net +COMMENT= FreeSwitch Sounds (All Bitrates) -PLIST= ${WRKDIR}/plist -NO_WRKSUBDIR= yes +PLIST= ${WRKDIR}/plist +NO_WRKSUBDIR= yes -OPTIONS= 8K "Compile sounds for 8K" on \ +BASE_PORTNAME= freeswitch + +OPTIONS= 8K "Compile sounds for 8K" on \ 16K "Compile sounds for 16K" on \ 32K "Compile sounds for 32K" on \ 48K "Compile sounds for 48K" on \ @@ -27,37 +28,35 @@ OPTIONS= 8K "Compile sounds for 8K" on \ .include <bsd.port.options.mk> .if defined(WITH_ENGLISH) -DISTFILES+= ${PORTNAME}${PKGNAMESUFFIX}-en-us-callie-48000-${PORTVERSION}${EXTRACT_SUFX} +DISTFILES+= ${PORTNAME}-en-us-callie-48000-${PORTVERSION}${EXTRACT_SUFX} .endif .if defined(WITH_RUSSIAN) -DISTFILES+= ${PORTNAME}${PKGNAMESUFFIX}-ru-RU-elena-48000-1.0.12${EXTRACT_SUFX} +DISTFILES+= ${PORTNAME}-ru-RU-elena-48000-1.0.12${EXTRACT_SUFX} .endif .if ! defined(WITH_ENGLISH) && ! defined(WITH_RUSSIAN) -BROKEN= "You must build with either English, Russian, or both" +BROKEN= you must build with either English, Russian, or both .endif .if ! defined(WITH_8K) && ! defined(WITH_16K) && ! defined(WITH_32K) && \ ! defined(WITH_48K) -BROKEN= "You must build with at least one of 8K, 16K, 32K, or 48K sounds" +BROKEN= you must build with at least one of 8K, 16K, 32K, or 48K sounds .endif .if defined(WITH_8K) -BUILD_DEPENDS+= sox:${PORTSDIR}/audio/sox -BITRATES+= 8000 +BUILD_DEPENDS+= sox:${PORTSDIR}/audio/sox +BITRATES+= 8000 .endif .if defined(WITH_16K) -BUILD_DEPENDS+= sox:${PORTSDIR}/audio/sox -BITRATES+= 16000 +BUILD_DEPENDS+= sox:${PORTSDIR}/audio/sox +BITRATES+= 16000 .endif .if defined(WITH_32K) -BUILD_DEPENDS+= sox:${PORTSDIR}/audio/sox -BITRATES+= 32000 +BUILD_DEPENDS+= sox:${PORTSDIR}/audio/sox +BITRATES+= 32000 .endif .if defined(WITH_48K) -BITRATES+= 48000 +BITRATES+= 48000 .endif -#RUN_DEPENDS+= freeswitch:${PORTSDIR}/net/freeswitch-core - do-build: @${ECHO_MSG} "Building for bitrates: ${BITRATES}" if [ "${WITH_ENGLISH}" != "" -a ! -e "${WRKDIR}/ENGLISH.done" ]; then \ @@ -68,9 +67,9 @@ do-build: else \ for dir in `ls ${WRKSRC}/en/us/callie/`; do \ ${MKDIR} ${WRKDIR}/tmp/en/us/callie/$${dir}/$${rate}/; \ - echo "@rmdir ${LOCALBASE}/share/freeswitch/sounds/en/us/callie/$${dir}/$${rate}/" >> ${PLIST}; \ + echo "@rmdir share/${BASE_PORTNAME}/sounds/en/us/callie/$${dir}/$${rate}/" >> ${PLIST}; \ for filename in `ls ${WRKSRC}/en/us/callie/$${dir}/48000`; do \ - echo "${LOCALBASE}/share/freeswitch/sounds/en/us/callie/$${dir}/$${rate}/$${filename}" >> ${PLIST}; \ + echo "share/${BASE_PORTNAME}/sounds/en/us/callie/$${dir}/$${rate}/$${filename}" >> ${PLIST}; \ if [ ! -e "${WRKDIR}/tmp/en/us/callie/$${dir}/$${rate}/$${filename}" ]; then \ ${ECHO_MSG} "${LOCALBASE}/bin/sox -v 0.2 ${WRKSRC}/en/us/callie/$${dir}/48000/$${filename} -r $${rate} -c 1 ${WRKDIR}/tmp/en/us/callie/$${dir}/$${rate}/$${filename}"; \ ${LOCALBASE}/bin/sox -v 0.2 "${WRKSRC}/en/us/callie/$${dir}/48000/$${filename}" -r $${rate} -c 1 "${WRKDIR}/tmp/en/us/callie/$${dir}/$${rate}/$${filename}"; \ @@ -89,9 +88,9 @@ do-build: else \ for dir in `ls ${WRKSRC}/ru/RU/elena/`; do \ ${MKDIR} ${WRKDIR}/tmp/ru/RU/elena/$${dir}/$${rate}/; \ - echo "@rmdir ${DATADIR}/sounds/ru/RU/elena/$${dir}/$${rate}/" >> ${PLIST}; \ + echo "@rmdir share/${BASE_PORTNAME}/sounds/ru/RU/elena/$${dir}/$${rate}/" >> ${PLIST}; \ for filename in `ls ${WRKSRC}/ru/RU/elena/$${dir}/48000`; do \ - echo "${DATADIR}/sounds/ru/RU/elena/$${dir}/$${rate}/$${filename}" >> ${PLIST}; \ + echo "share/${BASE_PORTNAME}/sounds/ru/RU/elena/$${dir}/$${rate}/$${filename}" >> ${PLIST}; \ if [ ! -e "${WRKDIR}/tmp/ru/RU/elena/$${dir}/$${rate}/$${filename}" ]; then \ ${ECHO_MSG} "${LOCALBASE}/bin/sox -v 0.2 ${WRKSRC}/ru/RU/elena/$${dir}/48000/$${filename} -r $${rate} -c 1 ${WRKDIR}/tmp/ru/RU/elena/$${dir}/$${rate}/$${filename}"; \ ${LOCALBASE}/bin/sox -v 0.2 "${WRKSRC}/ru/RU/elena/$${dir}/48000/$${filename}" -r $${rate} -c 1 "${WRKDIR}/tmp/ru/RU/elena/$${dir}/$${rate}/$${filename}"; \ @@ -107,16 +106,16 @@ pre-install: @${RM} -rf ${PLIST} @cd ${WRKDIR}/tmp && ${FIND} * ! -type d | ${SORT} >> ${PLIST}; \ ${ECHO} .freeswitch-sounds >> ${PLIST}; \ - ${SED} -i "" -e "s:^:%%DATADIR%%/sounds/:" ${PLIST}; \ - ${FIND} * -type d ! -empty | ${SORT} -r | ${SED} -e "s:^:@dirrm %%DATADIR%%/sounds/:" | ${GREP} / >> ${PLIST}; \ - ${ECHO} "@dirrmtry %%DATADIR%%/sounds 2> /dev/null || /usr/bin/true" >> ${PLIST}; \ - ${ECHO} "@dirrmtry %%DATADIR%% 2> /dev/null || /usr/bin/true" >> ${PLIST}; + ${SED} -i "" -e "s:^:share/${BASE_PORTNAME}/sounds/:" ${PLIST}; \ + ${FIND} * -type d ! -empty | ${SORT} -r | ${SED} -e "s:^:@dirrm share/${BASE_PORTNAME}/sounds/:" | ${GREP} / >> ${PLIST}; \ + ${ECHO} "@dirrmtry share/${BASE_PORTNAME}/sounds 2> /dev/null || /usr/bin/true" >> ${PLIST}; \ + ${ECHO} "@dirrmtry share/${BASE_PORTNAME} 2> /dev/null || /usr/bin/true" >> ${PLIST}; ${CHMOD} -R 0755 ${WRKDIR}/tmp/ do-install: @${ECHO_MSG} "Installing files..." - ${MKDIR} ${DATADIR}/sounds - ${TOUCH} ${DATADIR}/sounds/.freeswitch-sounds - (cd ${WRKDIR}/tmp/ &&${COPYTREE_SHARE} \* ${DATADIR}/sounds/) + ${MKDIR} ${PREFIX}/share/${BASE_PORTNAME}/sounds + ${TOUCH} ${PREFIX}/share/${BASE_PORTNAME}/sounds/.freeswitch-sounds + (cd ${WRKDIR}/tmp/ &&${COPYTREE_SHARE} \* ${PREFIX}/share/${BASE_PORTNAME}/sounds/) .include <bsd.port.mk> |