Magellan Linux

Annotation of /trunk/todo/openoffice/openoffice-2.4.1-r1.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2504 - (hide annotations) (download)
Thu Jul 9 20:11:27 2009 UTC (14 years, 11 months ago) by niro
File size: 4565 byte(s)
-moved to 'todo'
1 niro 2 # $Header: /magellan-cvs/smage/openoffice/openoffice-2.3.1-r1.smage2,v 1.2 2008/02/19 18:48:49 niro Exp $
2    
3     PNAME="openoffice"
4     PVER="2.4.1"
5     PBUILD="r1"
6    
7     PCATEGORIE="app-office"
8     STATE="unstable"
9    
10     DESCRIPTION="OpenOffice ${PVER}."
11     HOMEPAGE="http://www.openoffice.org/"
12    
13     DEPEND=">= virtual/glibc
14     >= dev-lang/perl-5
15     >= x11-libs/libXaw-1
16     >= app-arch/zip-2
17     >= app-arch/unzip-5
18     >= virtual/java"
19    
20     SDEPEND=">= sys-apps/findutils-4.1
21     >= sys-apps/sed-4
22     >= app-arch/rpm2targz-9.0"
23    
24     # must be /opt/openoffice-${PVER}
25     OO_HOME="/opt/openoffice-${PVER}"
26     # svn revision (used in SRC_DIR name)
27     OO_SVNBUILD="9238"
28     # build id of the core rpms
29     OO_BUILD="${OO_SVNBUILD}.i586"
30     # build id of the freedesktop-menus rpm (may differ with the other rpms)
31     OO_MENU_BUILD="${OO_SVNBUILD}.noarch"
32     # revision codename of OOo
33     OO_REVISION="OOG680_m9"
34     # version of our OOo wrapper
35     OO_WRAPPER_VER="2.2-1"
36    
37     # provide OO_HOME in the mage-file for use in postinstall()
38     SPECIAL_VARS="OO_HOME"
39    
40     SRCFILE="OOo_${PVER}_LinuxIntel_install_en-US.tar.gz"
41     SRCDIR="${BUILDDIR}/${OO_REVISION}_native_packed-1_en-US.${OO_SVNBUILD}/RPMS"
42    
43     sminclude mtools xdg
44    
45     SRC_URI=(
46     ftp://ftp.tu-chemnitz.de/pub/openoffice/stable/${PVER}/${SRCFILE}
47     mirror://${PNAME}/${SRCFILE}
48     mirror://${PNAME}/ooffice-wrapper-${OO_WRAPPER_VER}
49     )
50    
51     src_prepare()
52     {
53     munpack ${SRCFILE} || die
54     cd ${SRCDIR}
55    
56     # unpack the real bin-files
57     for i in base \
58     calc \
59     core{0{1,2,3{,u},4{,u},5{,u},6,7,8,9},10} \
60     draw \
61     emailmerge \
62     graphicfilter \
63     impress \
64     math \
65     pyuno \
66     testtool \
67     writer \
68     xsltfilter
69     do
70     rpm2targz openoffice.org-${i}-${PVER}-${OO_BUILD}.rpm || die "rpm ${i}"
71     tar xvzf openoffice.org-${i}-${PVER}-${OO_BUILD}.tar.gz || die "tar ${i}"
72     done
73    
74     # generic desktop menus
75     rpm2targz desktop-integration/openoffice.org-freedesktop-menus-${PVER:0:3}-${OO_MENU_BUILD}.rpm || die
76     tar xvzf openoffice.org-freedesktop-menus-${PVER:0:3}-${OO_MENU_BUILD}.tar.gz || die
77    
78     # kde integration
79     rpm2targz openoffice.org-kde-integration-${PVER}-${OO_BUILD}.rpm || die
80     tar xvzf openoffice.org-kde-integration-${PVER}-${OO_BUILD}.tar.gz || die
81    
82     # gnome intration
83     rpm2targz openoffice.org-gnome-integration-${PVER}-${OO_BUILD}.rpm || die
84     tar xvzf openoffice.org-gnome-integration-${PVER}-${OO_BUILD}.tar.gz || die
85    
86     # java support
87     rpm2targz openoffice.org-javafilter-${PVER}-${OO_BUILD}.rpm || die
88     tar xvzf openoffice.org-javafilter-${PVER}-${OO_BUILD}.tar.gz || die
89    
90     # get rid of all rpms and tar.gzs
91     rm ${SRCDIR}/*.rpm || die
92     rm ${SRCDIR}/*.tar.gz || die
93     }
94    
95     src_install ()
96     {
97     cd ${SRCDIR}
98    
99     # needed directories
100     minstalldir ${OO_HOME} || die
101     minstalldir /usr/bin || die
102     minstalldir /usr/share/applications || die
103     minstalldir /usr/share/icons || die
104     minstalldir /usr/share/mime || die
105     minstalldir /usr/share/mimelnk/application || die
106    
107     # install binaries
108     mv ${SRCDIR}/opt/openoffice.org${PVER:0:3}/* ${BINDIR}${OO_HOME} || die
109     mv ${SRCDIR}/usr/share/icons/* ${BINDIR}/usr/share/icons || die
110    
111     # menu entries
112     cd ${BINDIR}${OO_HOME}/share/xdg/
113    
114     # fix and install all desktop icons
115     local i
116     for i in base calc draw impress math writer printeradmin
117     do
118     sed -i "s:openoffice.org${PVER:0:3}:ooffice:g" ${i}.desktop || die
119    
120     # but the printeradmin is a special case
121     [[ ${i} = printeradmin ]] && { sed -i "s:^\(Exec=\).*:\1oopadmin:" ${i}.desktop || die; }
122    
123     mv ${i}.desktop openoffice.org-${PVER:0:3}-${i}.desktop || die
124     minstallxdg openoffice.org-${PVER:0:3}-${i}.desktop || die
125     done
126    
127     # install wrapper script
128     minstallexec -s ooffice-wrapper-${OO_WRAPPER_VER} /usr/bin/ooffice || die
129     sed -i "s:<pv>:${PVER}:g" ${BINDIR}/usr/bin/ooffice || die
130    
131     # create component symlinks
132     for app in calc draw impress math writer web padmin
133     do
134     mlink ooffice /usr/bin/oo${app} || die
135     done
136     }
137    
138     # >= kernel-2.6.11-r1 segfaults
139     # http://linux.derkeiler.com/Mailing-Lists/Kernel/2005-01/8751.html
140     postinstall()
141     {
142     echo
143     echo -en ${COLRED}
144     echo "OpenOffice.org may segfault on systems running kernel-2.6.11-r1 and higher."
145     echo -en ${COLDEFAULT}
146     echo
147     echo "OOo needs write access to the dri interface or it will segfault."
148     echo "See 'http://linux.derkeiler.com/Mailing-Lists/Kernel/2005-01/8751.html'"
149     echo "for more information about this issue"
150     echo
151     echo "Adding your user to the 'video' group will solve this issue."
152     echo
153     echo "To add more fonts to OOo like the Microsoft Corefonts,"
154     echo "run '${OO_HOME}/spadmin' and click on fonts to install them."
155     echo "Normally the fonts got installed in the /usr/share/fonts directory on your system."
156     echo
157     # echo "[ Press any key to continue ]"
158     # read
159     }

Properties

Name Value
svn:keywords Id