# Copyright 1999-2005 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: inherit eutils java-pkg MY_PVR=${PVR/rc/RC} DESCRIPTION="MSN and Jabber client in Java" HOMEPAGE="http://www.mercury.to/" ##Mercury.to does not provided http or ftp links LICENSE="mercury" SLOT="0" KEYWORDS="~x86 ~amd64" RESTRICT="fetch nostrip" IUSE="cam" SRC_URI=" ${MY_PVR}.zip cam? ( JavaLibs-linux.jar ) cam? ( VidConf-libs.jar ) cam? ( NativeLibs-linux.zip )" DEPEND="app-arch/unzip >=virtual/jdk-1.4" RDEPEND=">=virtual/jre-1.4 =dev-java/jgoodies-looks-1.3* dev-java/jmf-bin =dev-java/jdictrayapi-0.8.7 dev-java/xpp3 ~dev-java/jdom-1.0" S=${WORKDIR} pkg_nofetch() { einfo "Goto http://www.mercury.to/ and download ${MY_PVR} manual update file" einfo "It is a torrent download, so you must use a BitTorrent-like client" einfo "For information about this tecnology, look at Mercury official site" einfo "You must put the downloaded file in ${DISTDIR}" if use cam; then einfo "" einfo "For cam support You also have to download a directory with" einfo "some files inside via this torrent:" einfo "http://www.mercury.to/torrents/VidConf_Files.torrent" einfo "You have to copy the files inside the directory you downloaded in" einfo "${DISTDIR}" einfo "WARNING: you DON'T HAVE TO COPY the directory itself, only the files inside!" fi } src_unpack() { unpack ${MY_PVR}.zip cd ${S} rm -f *.dll *.so } src_install() { #Start installing stuff insinto /opt/${PN}/resources doins -r resources/* dojar lib/* if use cam; then # Mercury needs this package on another dir, so I can't use dojar functions #java-pkg_dojar ${DISTDIR}/JavaLibs-linux.jar #java-pkg_dojar ${DISTDIR}/VidConf-libs.jar insinto /opt/${PN}/lib doins ${DISTDIR}/JavaLibs-linux.jar doins ${DISTDIR}/VidConf-libs.jar # Same as above #unpack NativeLibs-linux.zip #java-pkg_doso *.so insinto /opt/${PN} unpack NativeLibs-linux.zip doins libjm*.so fi insinto /usr/share/pixmaps newins ${FILESDIR}/icon32.gif mercury.gif exeinto /opt/bin newexe ${FILESDIR}/mercury.sh mercury make_desktop_entry mercury "Mercury MSN client" /usr/share/pixmaps/mercury.gif # Adding env.d LDPATH setting to prevent a Mercury bug echo 'LDPATH="/opt/mercury-bin"' > 30mercury doenvd 30mercury } pkg_postinst() { einfo "If this is an AMD64 system, you should read this article" einfo "http://forum.mercury.to/index.php?act=ST&f=7&t=8691&hl=amd64&s=11e37dc56c71980182aa476f3e350b86" einfo "before running Mercury." }