# Copyright 1999-2007 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ inherit eutils DESCRIPTION="Much more than an answering machine, VOCP transforms your computer into a full-featured call answering and voice messaging system." HOMEPAGE="http://www.vocpsystem.com/" SRC_URI="mirror://sourceforge/vocp/VOCP-${PV}.tar.bz2" LICENSE="GPL-2" SLOT="0" KEYWORDS="~amd64 ~x86" IUSE="X vhosts tts" DEPEND="dev-lang/perl" RDEPEND="net-dialup/mgetty media-sound/vorbis-tools media-sound/lame virtual/mta dev-perl/MIME-tools dev-perl/Modem-Vgetty dev-perl/XML-Mini X? ( dev-perl/Audio-DSP dev-perl/perl-tk ) vhosts? ( dev-perl/crypt-cbc dev-perl/Crypt-Blowfish ) tts? ( app-accessibility/festival )" pkg_setup() { enewgroup vocp } src_unpack() { unpack ${A} epatch "${FILESDIR}"/${P}-install.patch } src_compile() { cd "${S}"/prog/VOCP export PERL_MM_USE_DEFAULT=1 perl Makefile.PL PREFIX=/usr INSTALLDIRS=vendor DESTDIR="${D}" make } src_install() { export VOCP_GROUP=vocp export VOCP_BASEDIR="${D}" use tts && export VOCP_HAVE_TTS=y einfo "Running patched install_vocp.pl script..." perl ./install_vocp.pl einfo "Installing VOCP Perl modules..." cd "${S}"/prog/VOCP make install cd "${S}" dodoc CHANGELOG README doc/* } pkg_postinst() { enewgroup vocp echo einfo "You will find the main vocp program and configuration files in the" einfo "/etc/vocp directory. The VOCP support programs (xVOCP, VOCPhax," einfo "etc.), documentation and VOCPweb will be located under /usr/share/vocp." echo einfo "You now need to configure the system to your tastes but you should have" einfo "a working system, with voice mail, pager and command shells!" echo einfo "As root, edit /etc/vocp/vocp.conf and follow the instructions within." echo einfo "If you need to change the audio file format, please use" einfo " /usr/share/vocp/install_vocp.pl" einfo "and select the appropriate format for your hardware." echo ewarn "Please make sure you read the documentation in /usr/share/doc/${P}/doc" ewarn "to complete the installation. VOCP and required packages have been" ewarn "installed, but not configured." echo }