/[gentoo-x86]/app-office/libreoffice-bin/libreoffice-bin-3.4.3-r1.ebuild
Gentoo

Contents of /app-office/libreoffice-bin/libreoffice-bin-3.4.3-r1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (hide annotations) (download)
Sat Sep 3 11:56:58 2011 UTC (3 years ago) by scarabeus
Branch: MAIN
Changes since 1.1: +5 -52 lines
Depend on split libreoffice-l10n package instead of installing the languages here.

(Portage version: 2.2.0_alpha52/cvs/Linux x86_64)

1 scarabeus 1.1 # Copyright 1999-2011 Gentoo Foundation
2     # Distributed under the terms of the GNU General Public License v2
3 scarabeus 1.2 # $Header: /var/cvsroot/gentoo-x86/app-office/libreoffice-bin/libreoffice-bin-3.4.3-r1.ebuild,v 1.1 2011/09/02 10:53:52 scarabeus Exp $
4 scarabeus 1.1
5     EAPI="3"
6    
7     inherit eutils fdo-mime gnome2-utils pax-utils prefix rpm multilib
8    
9 scarabeus 1.2 IUSE="gnome java"
10 scarabeus 1.1
11     MY_PV="${PV/_/-}"
12     MY_PV2="${PV}rc2"
13     BVER="3.4.3-302"
14     BVER2="3.4-302"
15     BASIS="libobasis3.4"
16     BASIS2="basis3.4"
17     NM="libreoffice"
18     NM1="${NM}"
19     NM2="${NM1}3.4"
20     FILEPATH="http://download.documentfoundation.org/${NM}/stable/${PV}/rpm/"
21     if [ "${ARCH}" = "amd64" ] ; then
22     XARCH="x86_64"
23     PACKED="LibO_${MY_PV2}_Linux_x86-64"
24     else
25     XARCH="i586"
26     PACKED="LibO_${MY_PV2}_Linux_x86"
27     fi
28     UP="${PACKED}_install-rpm_en-US/RPMS"
29    
30     DESCRIPTION="LibreOffice productivity suite."
31     HOMEPAGE="http://www.libreoffice.org"
32 scarabeus 1.2 SRC_URI="amd64? ( ${FILEPATH}/x86_64/LibO_${PV}_Linux_x86-64_install-rpm_en-US.tar.gz )
33     x86? ( ${FILEPATH}/x86/LibO_${PV}_Linux_x86_install-rpm_en-US.tar.gz )"
34 scarabeus 1.1
35     LICENSE="LGPL-3"
36     SLOT="0"
37     KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
38    
39     RDEPEND="!app-office/libreoffice
40     !app-office/openoffice
41     !app-office/openoffice-bin
42     !prefix? ( sys-libs/glibc )
43 scarabeus 1.2 >=app-office/libreoffice-l10n-${PV}
44 scarabeus 1.1 app-arch/unzip
45     app-arch/zip
46     >=dev-lang/perl-5.0
47     >=media-libs/freetype-2.1.10-r2
48     x11-libs/libXaw
49     x11-libs/libXinerama"
50    
51     DEPEND="${RDEPEND}
52     sys-apps/findutils"
53    
54     PDEPEND="java? ( >=virtual/jre-1.5 )"
55    
56     RESTRICT="strip"
57    
58     QA_EXECSTACK="usr/$(get_libdir)/${NM}/${BASIS2}/program/*
59     usr/$(get_libdir)/${NM}/ure/lib/*"
60     QA_TEXTRELS="usr/$(get_libdir)/${NM}/ure/lib/*"
61     QA_PRESTRIPPED="usr/$(get_libdir)/${NM}/${BASIS2}/program/*
62     usr/$(get_libdir)/${NM}/${BASIS2}/program/python-core-2.6.1/lib/lib-dynload/*
63     usr/$(get_libdir)/${NM}/program/*
64     usr/$(get_libdir)/${NM}/ure/bin/*
65     usr/$(get_libdir)/${NM}/ure/lib/*"
66    
67     src_unpack() {
68    
69     unpack ${A}
70    
71     cp "${FILESDIR}"/{50-${PN},wrapper.in} "${T}"
72     eprefixify "${T}"/{50-${PN},wrapper.in}
73    
74     for i in base binfilter calc core01 core02 core03 core04 core05 core06 \
75     core07 draw graphicfilter images impress math ogltrans ooofonts \
76     ooolinguistic pyuno testtool writer xsltfilter ; do
77     rpm_unpack "./${UP}/${BASIS}-${i}-${BVER}.${XARCH}.rpm"
78     done
79    
80     rpm_unpack "./${UP}/${NM2}-${BVER}.${XARCH}.rpm"
81     rpm_unpack "./${UP}/${NM2}-ure-${BVER}.${XARCH}.rpm"
82    
83     for j in base calc draw impress math writer; do
84     rpm_unpack "./${UP}/${NM2}-${j}-${BVER}.${XARCH}.rpm"
85     done
86    
87     rpm_unpack "./${UP}/desktop-integration/${NM2}-freedesktop-menus-${BVER2}.noarch.rpm"
88    
89     use gnome && rpm_unpack "./${UP}/${BASIS}-gnome-integration-${BVER}.${XARCH}.rpm"
90     use java && rpm_unpack "./${UP}/${BASIS}-javafilter-${BVER}.${XARCH}.rpm"
91    
92     # Extensions
93     for k in beanshell-script-provider javascript-script-provider mediawiki-publisher nlpsolver pdf-import presentation-minimizer presenter-screen python-script-provider report-builder; do
94     rpm_unpack "./${UP}/${BASIS}-extension-${k}-${BVER}.${XARCH}.rpm"
95     done
96    
97     # English support installed by default
98     rpm_unpack "./${UP}/${BASIS}-en-US-${BVER}.${XARCH}.rpm"
99     rpm_unpack "./${UP}/${NM2}-en-US-${BVER}.${XARCH}.rpm"
100     rpm_unpack "./${UP}/${NM2}-dict-en-${BVER}.${XARCH}.rpm"
101     for s in base binfilter calc math res writer ; do
102     rpm_unpack "./${UP}/${BASIS}-en-US-${s}-${BVER}.${XARCH}.rpm"
103     done
104    
105     }
106    
107     src_install () {
108    
109     INSTDIR="/usr/$(get_libdir)/${NM}"
110     dodir ${INSTDIR}
111     mv "${WORKDIR}"/opt/${NM2}/* "${ED}${INSTDIR}" || die
112    
113     #Menu entries, icons and mime-types
114     cd "${ED}${INSTDIR}/share/xdg/"
115     for desk in base calc draw impress javafilter math printeradmin qstart startcenter writer; do
116     if [ "${desk}" = "javafilter" ] ; then
117     use java || { rm -f javafilter.desktop; continue; }
118     fi
119     mv ${desk}.desktop ${NM1}-${desk}.desktop
120     sed -i -e s/${NM2}/${NM}/g ${NM1}-${desk}.desktop || die
121     domenu ${NM1}-${desk}.desktop
122     done
123     insinto /usr/share
124     doins -r "${WORKDIR}"/usr/share/icons
125     doins -r "${WORKDIR}"/usr/share/mime
126    
127     # Install wrapper script
128     newbin "${T}/wrapper.in" ${NM1}
129     sed -i -e s/LIBDIR/$(get_libdir)/g "${ED}/usr/bin/${NM1}" || die
130    
131     dosym ${INSTDIR}/program/spadmin /usr/bin/${NM1}-printeradmin
132    
133     rm -f "${ED}${INSTDIR}/basis-link" || die
134     dosym ${INSTDIR}/${BASIS2} ${INSTDIR}/basis-link
135    
136     # Non-java weirdness see bug #99366
137     use !java && rm -f "${ED}${INSTDIR}/ure/bin/javaldx"
138    
139     # install the unopkg binary
140     dosym ${INSTDIR}/program/unopkg /usr/bin/unopkg
141    
142     # prevent revdep-rebuild from attempting to rebuild all the time
143     insinto /etc/revdep-rebuild && doins "${T}/50-${PN}"
144    
145     }
146    
147     pkg_preinst() {
148    
149     use gnome && gnome2_icon_savelist
150    
151     }
152    
153     pkg_postinst() {
154    
155     fdo-mime_desktop_database_update
156     fdo-mime_mime_database_update
157     use gnome && gnome2_icon_cache_update
158    
159     pax-mark -m "${EPREFIX}"/usr/$(get_libdir)/${NM}/program/soffice.bin
160    
161     }
162    
163     pkg_postrm() {
164    
165     fdo-mime_desktop_database_update
166     use gnome && gnome2_icon_cache_update
167    
168     }

  ViewVC Help
Powered by ViewVC 1.1.20