| 1 |
# Copyright 1999-2012 Gentoo Foundation
|
| 2 |
# Distributed under the terms of the GNU General Public License v2
|
| 3 |
# $Header: /var/cvsroot/gentoo-x86/net-im/skype/skype-4.0.0.7-r2.ebuild,v 1.4 2012/06/15 11:50:32 ssuominen Exp $
|
| 4 |
|
| 5 |
EAPI=4
|
| 6 |
inherit eutils gnome2-utils pax-utils
|
| 7 |
|
| 8 |
DESCRIPTION="An P2P Internet Telephony (VoiceIP) client"
|
| 9 |
HOMEPAGE="http://www.skype.com/"
|
| 10 |
SKYPE_URI="http://download.${PN}.com/linux"
|
| 11 |
SRC_URI="!qt-static? ( ${SKYPE_URI}/${P}.tar.bz2 )
|
| 12 |
qt-static? ( ${SKYPE_URI}/${PN}_static-${PV}.tar.bz2 )"
|
| 13 |
|
| 14 |
LICENSE="${P}-copyright ${P}-third-party_attributions.txt"
|
| 15 |
SLOT="0"
|
| 16 |
KEYWORDS="~amd64 ~x86"
|
| 17 |
IUSE="pax_kernel qt-static"
|
| 18 |
|
| 19 |
QA_PREBUILT=opt/bin/${PN}
|
| 20 |
RESTRICT="mirror strip" #299368
|
| 21 |
|
| 22 |
EMUL_X86_VER=20120520
|
| 23 |
|
| 24 |
RDEPEND="virtual/ttf-fonts
|
| 25 |
amd64? (
|
| 26 |
>=app-emulation/emul-linux-x86-baselibs-${EMUL_X86_VER}
|
| 27 |
>=app-emulation/emul-linux-x86-soundlibs-${EMUL_X86_VER}
|
| 28 |
>=app-emulation/emul-linux-x86-xlibs-${EMUL_X86_VER}
|
| 29 |
!qt-static? ( >=app-emulation/emul-linux-x86-qtlibs-${EMUL_X86_VER} )
|
| 30 |
)
|
| 31 |
x86? (
|
| 32 |
media-libs/alsa-lib
|
| 33 |
x11-libs/libX11
|
| 34 |
x11-libs/libXext
|
| 35 |
x11-libs/libXScrnSaver
|
| 36 |
x11-libs/libXv
|
| 37 |
qt-static? (
|
| 38 |
>=dev-libs/glib-2.28
|
| 39 |
media-libs/fontconfig
|
| 40 |
>=media-libs/freetype-2
|
| 41 |
>=media-libs/tiff-3.9.5-r3:3
|
| 42 |
sys-libs/zlib
|
| 43 |
x11-libs/libICE
|
| 44 |
x11-libs/libSM
|
| 45 |
x11-libs/libXrender
|
| 46 |
)
|
| 47 |
!qt-static? (
|
| 48 |
x11-libs/qt-core:4
|
| 49 |
x11-libs/qt-dbus:4
|
| 50 |
x11-libs/qt-gui:4[accessibility,dbus]
|
| 51 |
)
|
| 52 |
)"
|
| 53 |
|
| 54 |
src_unpack() {
|
| 55 |
unpack ${A}
|
| 56 |
[[ -d ${S} ]] || { mv skype* "${S}" || die; }
|
| 57 |
}
|
| 58 |
|
| 59 |
src_compile() {
|
| 60 |
type -P lrelease >/dev/null && lrelease lang/*.ts
|
| 61 |
rm -f lang/*.ts
|
| 62 |
}
|
| 63 |
|
| 64 |
src_install() {
|
| 65 |
into /opt
|
| 66 |
dobin ${PN}
|
| 67 |
fowners root:audio /opt/bin/${PN}
|
| 68 |
|
| 69 |
insinto /etc/dbus-1/system.d
|
| 70 |
doins ${PN}.conf
|
| 71 |
|
| 72 |
insinto /usr/share/skype
|
| 73 |
doins -r avatars lang sounds
|
| 74 |
|
| 75 |
dodoc README
|
| 76 |
|
| 77 |
local res
|
| 78 |
for res in 16 32 48; do
|
| 79 |
newicon -s ${res} icons/SkypeBlue_${res}x${res}.png ${PN}.png
|
| 80 |
done
|
| 81 |
|
| 82 |
make_desktop_entry ${PN} 'Skype VoIP' ${PN} 'Network;InstantMessaging;Telephony'
|
| 83 |
|
| 84 |
if use pax_kernel; then
|
| 85 |
pax-mark Cm "${ED}"/opt/bin/${PN} || die
|
| 86 |
eqawarn "You have set USE=pax_kernel meaning that you intend to run"
|
| 87 |
eqawarn "${PN} under a PaX enabled kernel. To do so, we must modify"
|
| 88 |
eqawarn "the ${PN} binary itself and this *may* lead to breakage! If"
|
| 89 |
eqawarn "you suspect that ${PN} is being broken by this modification,"
|
| 90 |
eqawarn "please open a bug."
|
| 91 |
fi
|
| 92 |
}
|
| 93 |
|
| 94 |
pkg_preinst() {
|
| 95 |
gnome2_icon_savelist
|
| 96 |
|
| 97 |
rm -rf "${EROOT}"/usr/share/${PN} #421165
|
| 98 |
}
|
| 99 |
|
| 100 |
pkg_postinst() {
|
| 101 |
gnome2_icon_cache_update
|
| 102 |
|
| 103 |
# http://bugs.gentoo.org/360815
|
| 104 |
elog "For webcam support, see \"LD_PRELOAD\" section of \"README.lib\" document provided by"
|
| 105 |
elog "media-libs/libv4l package and \"README\" document of this package."
|
| 106 |
if use amd64; then
|
| 107 |
elog "You can install app-emulation/emul-linux-x86-medialibs package for the 32bit"
|
| 108 |
elog "libraries from the media-libs/libv4l package."
|
| 109 |
fi
|
| 110 |
}
|
| 111 |
|
| 112 |
pkg_postrm() {
|
| 113 |
gnome2_icon_cache_update
|
| 114 |
}
|