diff options
Diffstat (limited to 'trunk/app-office/openoffice-voikko/openoffice-voikko-2.1.ebuild')
-rw-r--r-- | trunk/app-office/openoffice-voikko/openoffice-voikko-2.1.ebuild | 133 |
1 files changed, 0 insertions, 133 deletions
diff --git a/trunk/app-office/openoffice-voikko/openoffice-voikko-2.1.ebuild b/trunk/app-office/openoffice-voikko/openoffice-voikko-2.1.ebuild deleted file mode 100644 index aa6dbec..0000000 --- a/trunk/app-office/openoffice-voikko/openoffice-voikko-2.1.ebuild +++ /dev/null @@ -1,133 +0,0 @@ -# Copyright 1999-2007 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: $ - -inherit eutils versionator multilib - -MY_P="${P/office-voikko/office.org-voikko}" -MY_PN="${PN/office-voikko/office.org-voikko}" - -DESCRIPTION="Voikko—Free Finnish spell checking and hyphenation for OpenOffice" -HOMEPAGE="http://voikko.sf.net/" -SRC_URI="mirror://sourceforge/voikko/${MY_P}.tar.gz" -LICENSE="GPL-2" -SLOT="0" -KEYWORDS="-x86" # This’s broken till SDK is fixed and whatnot - -#DEPEND="|| ( >=app-office/openoffice-2 ( -# >=app-office/openoffice-bin-2 app-office/openoffice-sdk -# ) -# ) -DEPEND="|| ( >=app-office/openoffice-2 >=app-office/openoffice-bin-2 ) - app-office/openoffice-sdk - app-text/voikko - sys-apps/grep - sys-apps/sed - sys-apps/sysvinit - !app-office/oo2-voikko" -RDEPEND="|| ( >=app-office/openoffice-2 >=app-office/openoffice-bin-2 ) - app-text/voikko" - -S="${WORKDIR}/${MY_P}" - -pkg_setup() { - # This check originates from soikko times I think... - # Also, pidof belongs to sysvinit, dep? - if pidof soffice.bin >/dev/null; then - die "${PN} can’t be installed while OpenOffice.org is running." - fi - # We need OpenOffice SDK initialisation sh script executable - # If we could trust openoffice use +odk work, this was unnecessary: - if [[ ! -x "${ROOT}/usr/lib/openoffice/program/setsdkenv_unix.sh" ]] ; then - die "Couldn’t find open office SDK settings from \ - ${ROOT}/usr/lib/openoffice/program/setsdkenv_unix.sh" - else - export SDKENV="${ROOT}/usr/lib/openoffice/program/setsdkenv_unix.sh" - fi - if [[ ! -x "${ROOT}/usr/$(get_libdir)/openoffice/program/unopkg" ]] ; then - die "Couldn’t find unopkg binary" - else - export UNOPKG="${ROOT}/usr/$(get_libdir)/openoffice/program/unopkg" - fi - - # Open Office must be installed with SDK - if has_version app-office/openoffice ; then - if ! built_with_use app-office/openoffice odk ; then - ewarn "OpenOffice should be built with USE flag “odk”" - ewarn "for building uno package from source to work" - fi - fi - einfo "Searching OpenOffice.org SDK environment..." - source "${SDKENV}" - einfo "SDK set to: OO_SDK_HOME=${OO_SDK_HOME}" -} - -src_install() { - dodoc README ChangeLog || die "docs missing" - dodir /usr/lib/${P} - insinto /usr/lib/${P} - doins build/voikko.oxt -} - -# FIXME: installation of an unopkg is troublesome, move to src_install when -# OO.o supports it somehow sanely -pkg_postinst() { - - # N.B.: uno packages meddle with $HOME, let’s fool it - HOME="${S}" - cd "${S}" - # Yay, OO.o package installation requires .ooo-2.0 directory from once - # started instance of the program. How fun! - tar jxf "${FILESDIR}/ooo-2.0-home.tar.bz2" - - # select component - COMPONENT="${ROOT}/usr/lib/${P}/voikko.oxt" - PKG=$(basename "${COMPONENT}") - - # Global scope in install-oo2-voikko - if [[ -e "${HOME}/.openoffice.org2/.lock" ]] ; - then - die "lockfile from previous failed installation attempt found in \ - ${HOME}/.openoffice.org2/.lock, please clean and retry" - fi - # register() - if [[ "${COMPONENT}" == "" ]] ; - then - die "UNO component not found" - fi - einfo "Trying to register uno package ${COMPONENT}..." - HOME=${HOME} "${UNOPKG}" add --shared "${COMPONENT}" - if [[ $? == 0 ]] ; - then - einfo "Voikko package (${PKG}) registered succesfully" - else - die "Couldn’t register ${PN} package (${PKG})" - fi - elog "Please note that ${PN} is very dependent on ABI compatible " - elog "version of OpenOffice.org to exist on system when removing voikko!" - elog "Before incompatible update or removal of OpenOffice you must" - elog "unmerge ${PN}!" - -} - -pkg_prerm() { - #unregister() - UNOPKG_LIST="$(${UNOPKG} list --shared 2> /dev/null)" - if [[ $? != 0 ]] ; then - ewarn "Couldn’t list existing packages..." - fi - PKG=$(echo ${UNOPKG_LIST} | egrep -m1 "^Identifier: (org.puimula.ooovoikko|org.openoffice.legacy.openoffice.org-voikko.*.uno.pkg)" | sed -ne "s/^Identifier: \\(.*\\)/\\1/p") - if [ "${PKG}" != "" ]; then - einfo "Removing uno package ${PKG}..." - if "${UNOPKG}" remove --shared ${PKG} &>/dev/null - then - einfo "${PN} package (${PKG}) unregistered succesfully" - else - die "Couldn’t uninstall existing ${PN} packages" - fi - else - ewarn "Couldn’t find existing ${PN} packages." - ewarn "You may need to \`unopkg remove\` them manually." - fi -} - |