# $Id$ PNAME="citrix-plugin-speechmike" PVER="0.4" PBUILD="r1" SPLIT_PACKAGES="speechmike-config-tools citrix-plugin-speechmike" PCAT="net-misc" HOMEPAGE="http://magellan-linux.de" CONFIG_DEPEND=">= virtual/glibc" PLUGIN_DEPEND=">= net-misc/ica-client-12" SDEPEND="${CONFIG_DEPEND} ${PLUGIN_DEPEND}" SRCFILE="${PNAME}-${PVER}.tar.bz2" SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" sminclude mbuild mtools SRC_URI=( mirror://${PNAME}/${SRCFILE} ) UP2DATE="echo ${PVER}" split_info_speechmike-config-tools() { DESCRIPTION="Philips SpeechMike config helper tools." DEPEND="${CONFIG_DEPEND}" } split_info_citrix-plugin-speechmike() { DESCRIPTION="Philips SpeechMike Driver and SDK for Citrix." DEPEND="== ${PCAT}/speechmike-config-tools-${PVER} ${PLUGIN_DEPEND}" } src_compile() { cd ${SRCDIR} mmake ICAROOTDIR=/opt/ica-client || die } src_install_speechmike-config-tools() { cd ${SRCDIR} mmake ICAROOTDIR=/opt/ica-client DESTDIR=${BINDIR} install-config-tools || die } src_install_citrix-plugin-speechmike() { cd ${SRCDIR} mmake ICAROOTDIR=/opt/ica-client DESTDIR=${BINDIR} install || die # remove config tools mdelete /usr/bin/nuainitool || die mdelete /usr/bin/speechmike-config || die } postinstall_citrix-plugin-speechmike() { if [[ -z ${MROOT} ]] || [[ ${MROOT} = / ]] then [[ -x /usr/bin/speechmike-config ]] && /usr/bin/speechmike-config install # restart tmpfiles service to generate missing tmpfiles systemctl restart systemd-tmpfiles-setup.service fi mstartunit dpmmountd DPMMountd } postremove_citrix-plugin-speechmike() { if [[ -z ${MROOT} ]] || [[ ${MROOT} = / ]] then # do nothing on update [[ -x /usr/sbin/DPMMountd ]] && return [[ -x /usr/bin/speechmike-config ]] && /usr/bin/speechmike-config remove fi mstopunit dpmmountd DPMMountd }