stable/net-im/netiq-messenger-client/netiq-messenger-client-2.2.1.20111007.ebuild

93 lines
3.3 KiB
Bash
Raw Normal View History

2014-08-16 09:01:13 +02:00
# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
EAPI="2"
NOVELL_BUILDID="CRebpCxNTRQ~"
NOVELL_FILE="patchfiles/nm221_full_linux_multi.tar.gz"
RESTRICT="mirror strip"
inherit novell rpm java-pkg-2 eutils versionator
MY_PV=$(replace_version_separator 3 '-')
MY_PV="${MY_PV/_p/-}"
DESCRIPTION="Novell Groupwise Messenger"
HOMEPAGE="http://www.novell.com"
SRC_URI="http://${NOVELL_ACCOUNT_USERNAME}:${NOVELL_ACCOUNT_PASSWORD}@cdn.novell.com/prot/${NOVELL_BUILDID}/${NOVELL_FILE}"
LICENSE="Novell-Messenger-22"
SLOT="0"
KEYWORDS="~x86 ~amd64"
IUSE="linguas_en linguas_hu linguas_ar
linguas_cs linguas_da linguas_de linguas_es linguas_fi
linguas_fr linguas_he linguas_it linguas_ja linguas_ko
linguas_nl linguas_no linguas_pl linguas_pt linguas_ru
linguas_sv linguas_zh_CN linguas_zh_TW"
DEPEND=">=virtual/jre-1.6
media-libs/jpeg:62
amd64? ( =app-emulation/emul-linux-x86-java-1.6* )"
S=${WORKDIR}/nmclient
src_unpack() {
unpack ${A} || die
mkdir -p ${WORKDIR}/${PN}-${MY_PV}
cd ${PN}-${MY_PV}
rpm_unpack ../work/nm221_full_linux_multi/client/xplat/linux/RPMS/${PN}-${MY_PV}.i586.rpm || die "rpm unpack failed"
}
src_compile() { :; }
src_install() {
has_multilib_profile && ABI="x86"
for x in en hu ar cs da de es fi fr he it ja ko nl no pl pt ru sv zh_CN zh_TW ; do
if use linguas_${x}
then
[[ ${x} == "zh_CN" ]] && x="zhcn"
[[ ${x} == "zh_TW" ]] && x="zhtw"
docinto ${x}
dodoc ${WORKDIR}/${PN}-${MY_PV}/opt/novell/messenger/client/docs/${x}/*.htm
fi
done
java-pkg_jarinto /opt/novell/messenger/client/$(get_libdir)
for x in jh.jar nmclhlp.jar nmclient.jar; do
java-pkg_dojar ${WORKDIR}/${PN}-${MY_PV}/opt/novell/messenger/client/${x}
done
java-pkg_sointo /opt/novell/messenger/client/$(get_libdir)
for x in libeggtray.so libidlex.so; do
java-pkg_doso ${WORKDIR}/${PN}-${MY_PV}/opt/novell/messenger/client/${x}
done
insinto ${JAVA_PKG_JARDEST}
doins ${WORKDIR}/${PN}-${MY_PV}/opt/novell/messenger/client/*.wav
insinto ${JAVA_PKG_JARDEST}/icons
doins ${WORKDIR}/${PN}-${MY_PV}/opt/novell/messenger/client/icons/*
doicon ${WORKDIR}/${PN}-${MY_PV}/opt/novell/messenger/client/nmclient.png
# insinto ${JAVA_PKG_JARDEST}/docs
into /opt/novell/messenger/client
java-pkg_dolauncher nmclient --main com.novell.messenger.client.Messenger \
-pre ${FILESDIR}/nmclient-2.0-pre \
--java_args "-Xms5M -Dawt.toolkit=sun.awt.motif.MToolkit"
make_desktop_entry /opt/novell/messenger/client/bin/nmclient "GroupWise Messenger" nmclient.png Network
dosym /opt/novell/messenger/client/bin/nmclient /opt/bin/nmclient
}
pkg_nofetch() {
einfo "This files require you to register at ${HOMEPAGE} (free account)"
einfo "Please download following file:"
einfo " - ${NOVELL_FILE}"
einfo "from http://download.novell.com/Download?buildid=${NOVELL_BUILDID}"
einfo "and place it in ${DISTDIR}"
einfo ""
einfo "To get rid of downloading files from ${HOMEPAGE}"
einfo "you can create a file /etc/portage/novell.acc"
einfo "containing the the novell account infos with following commands"
einfo "# echo \"NOVELL_ACCOUNT_USERNAME=\\\"balduin\\\"\" >> /etc/portage/novell.acc"
einfo "# echo \"NOVELL_ACCOUNT_PASSWORD=\\\"derfisch\\\"\" >> /etc/portage/novell.acc"
}