/[gentoo-x86]/sci-misc/mendeleydesktop/mendeleydesktop-1.6.ebuild
Gentoo

Contents of /sci-misc/mendeleydesktop/mendeleydesktop-1.6.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download)
Tue Sep 11 18:17:52 2012 UTC (2 years, 3 months ago) by miknix
Branch: MAIN
Changes since 1.1: +14 -10 lines
Fix 'use' function invocation on global ebuild scope. #434634

(Portage version: 2.1.11.9/cvs/Linux x86_64)

1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/sci-misc/mendeleydesktop/mendeleydesktop-1.6.ebuild,v 1.1 2012/09/10 13:42:02 miknix Exp $
4
5 EAPI="4"
6
7 inherit eutils multilib
8
9 MY_P_AMD64="${P}-linux-x86_64"
10 MY_P_X86="${P}-linux-i486"
11
12 DESCRIPTION="A free research management tool for desktop and web"
13 HOMEPAGE="http://www.mendeley.com/"
14 SRC_URI="amd64? ( ${MY_P_AMD64}.tar.bz2 )
15 x86? ( ${MY_P_X86}.tar.bz2 )
16 amd64-linux? ( ${MY_P_AMD64}.tar.bz2 )
17 x86-linux? ( ${MY_P_X86}.tar.bz2 )"
18
19 LICENSE="Mendeley-EULA"
20 SLOT="0"
21 KEYWORDS="~amd64 ~x86"
22 IUSE=""
23
24 RESTRICT="fetch"
25
26 DEPEND=""
27 RDEPEND=">=x11-libs/qt-core-4.6:4
28 >=x11-libs/qt-gui-4.6:4
29 >=x11-libs/qt-svg-4.6:4
30 >=x11-libs/qt-webkit-4.6:4
31 >=x11-libs/qt-xmlpatterns-4.6:4"
32
33 QA_PRESTRIPPED="
34 /opt/mendeleydesktop/$(get_libdir)/mendeleydesktop/libexec/.*
35 /opt/mendeleydesktop/$(get_libdir)/lib.*so.*"
36
37 pkg_nofetch() {
38 elog "Please download ${A} from:"
39 elog "http://www.mendeley.com/download-mendeley-desktop/"
40 elog "and move it to ${DISTDIR}"
41 }
42
43 src_unpack() {
44 unpack ${A}
45
46 cd "${WORKDIR}"
47
48 if use amd64 || use amd64-linux ; then
49 mv -f "${MY_P_AMD64}" "${P}"
50 else
51 mv -f "${MY_P_X86}" "${P}"
52 fi
53 }
54
55 src_prepare() {
56 # remove bundled Qt libraries
57 rm -rf lib/mendeleydesktop/plugins \
58 || die "failed to remove plugin directory"
59 rm -rf lib/qt || die "failed to remove qt libraries"
60
61 # force use of system Qt libraries
62 sed -i "s:sys\.argv\.count(\"--force-system-qt\") > 0:True:" \
63 bin/mendeleydesktop || die "failed to patch startup script"
64
65 # fix library paths
66 sed -i \
67 -e "s:lib/mendeleydesktop:$(get_libdir)/mendeleydesktop:g" \
68 -e "s:MENDELEY_BASE_PATH + \"/lib/\":MENDELEY_BASE_PATH + \"/$(get_libdir)/\":g" \
69 bin/mendeleydesktop || die "failed to patch library path"
70 }
71
72 src_install() {
73 # install menu
74 domenu share/applications/${PN}.desktop
75
76 # install application icons
77 insinto /usr/share/icons
78 doins -r share/icons/hicolor
79
80 # install default icon
81 insinto /usr/share/pixmaps
82 doins share/icons/hicolor/48x48/apps/${PN}.png
83
84 # install documentation, but no license file
85 dodoc share/doc/${PN}/FAQ.pdf
86 dodoc share/doc/${PN}/Readme.txt
87
88 # install binary
89 into /opt/${PN}
90 dobin bin/*
91
92 # install libraries
93 dolib.so lib/lib*.so*
94
95 # install programs
96 exeinto /opt/mendeleydesktop/$(get_libdir)/mendeleydesktop/libexec
97 doexe lib/mendeleydesktop/libexec/*
98
99 # install shared files
100 insinto /opt/${PN}/share
101 doins -r share/mendeleydesktop
102
103 # make symbolic to known location
104 dosym /opt/${PN}/bin/${PN} /opt/bin/${PN}
105 }

  ViewVC Help
Powered by ViewVC 1.1.20