1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
|
--- bin/setup.in
+++ bin/setup.in
@@ -28,6 +28,7 @@
ENABLE_ODK='@ENABLE_ODK@'
USE_PREBUILD_UNOWINREG_DLL='@USE_PREBUILD_UNOWINREG_DLL@'
ENABLE_MONO='@ENABLE_MONO@'
+ENABLE_QUICKSTART='@ENABLE_QUICKSTART@'
ENABLE_GRAPHITE='@ENABLE_GRAPHITE@'
GRAPHITE_SRC='@GRAPHITE_SRC@'
PROPAGATED_ARGS="@PROPAGATED_ARGS@"
--- bin/package-ooo
+++ bin/package-ooo
@@ -15,6 +15,14 @@
rm -Rf $OOINSTDIR;
set -e
+echo "Building $OOINSTDIR/ooo-wrapper$BINSUFFIX";
+sed -e "s|@OOINSTBASE@|$OOINSTBASE|g
+ s|@SYSCONFDIR@|$SYSCONFDIR|g
+ s|@BINSUFFIX@|$BINSUFFIX|g
+ s|@OOO_BUILDVERSION@|$OOO_BUILDVERSION|g
+ s|@OOOINSTALLDIRNAME@|$OOOINSTALLDIRNAME|g
+ s|@VENDORNAME@|$VENDORNAME|g" $TOOLSDIR/bin/ooo-wrapper.in \
+ >| "$OOBUILDDIR/ooo-wrapper$BINSUFFIX" || exit 1;
mkdir -p $PREFIX/bin
sed -e "s|@OOINSTBASE@|$OOINSTBASE|g" $TOOLSDIR/bin/ootool.in \
@@ -28,6 +36,20 @@
sed -e "s|@OOINSTBASE@|$OOINSTBASE|g" $TOOLSDIR/bin/oosmoketest.in \
>| "$OOBUILDDIR/oosmoketest$BINSUFFIX" || exit 1;
+
+create_simple_wrapper()
+{
+ cat <<EOT >$2
+#!/bin/sh
+
+# Keep in ~sync with ooo-wrapper
+
+SystemInstallDir="$OOINSTBASE"
+
+exec "$1" "\$@"
+EOT
+ chmod 755 $2
+}
create_qstart_wrapper()
{
@@ -45,50 +67,60 @@
chmod +x $2
}
-# directory for man
-mkdir -p $MANDIR/man1
-
-# startup wrappers
-for app in calc draw impress math web writer base; do
- create_qstart_wrapper "$PREFIX/bin/oo${app}${BINSUFFIX}" "-${app}" "" || exit 1;
-done
-create_qstart_wrapper "$PREFIX/bin/oofromtemplate${BINSUFFIX}" "" "slot:5500" || exit 1;
-create_qstart_wrapper "$PREFIX/bin/ooffice${BINSUFFIX}" "" "" || exit 1;
-if test "z$VENDORNAME" = "zNovell" -o "z$VENDORNAME" = "zPLD" \
- -o "z$VENDORNAME" = "zDebian" \
- -o "z$VENDORNAME" = "zMandriva"; then
- for app in calc draw impress math web writer base fromtemplate ffice ; do
- echo ".so man1/openoffice$BINSUFFIX.1" >| $MANDIR/man1/oo${app}$BINSUFFIX.1;
- done
-fi
-
-# /usr/bin/ooffice symlink is necessary by java UNO components to find
-# the UNO installation using $PATH, see
-# http://udk.openoffice.org/common/man/spec/transparentofficecomponents.html
-# Note: if you want to support parallel installation of more OOo versions
-# you cannot include this link directly into the package
-# For example, the Novell package mark this symlink as %ghost
-# and update it in %post and %postun
-ln -sf $OOINSTBASE/program/soffice $PREFIX/bin/soffice
-
-# no man-page so ...
-if test "z$VENDORNAME" != "zDebian" -a "z$VENDORNAME" != "zMandriva"; then
- install_script $TOOLSDIR/bin/ooconfig $PREFIX/bin/ooconfig
- install_script $OOBUILDDIR/ootool$BINSUFFIX $PREFIX/bin/ootool$BINSUFFIX
-fi
-
-if test "z$VENDORNAME" = "zMandriva"; then
- install_script $TOOLSDIR/bin/ooconfig $PREFIX/bin/ooconfig$BINSUFFIX
- install_script $OOBUILDDIR/ootool$BINSUFFIX $PREFIX/bin/ootool$BINSUFFIX
-fi
-
-# create bash completion
-mkdir -p $OODESTDIR/etc/bash_completion.d
-gen_bash_comp_opts=--binsuffix="$BINSUFFIX"
-if test "z$ENABLE_OPENXML" = "zyes" ; then
- gen_bash_comp_opts="$gen_bash_comp_opts --enable-openxml"
-fi
-$TOOLSDIR/bin/generate-bash-completion $gen_bash_comp_opts $TOOLSDIR/bin/bash-completion.in $OODESTDIR/etc/bash_completion.d/ooffice${BINSUFFIX}.sh
+# Skip the versioning and linking dance of the wrapper script for Red Hat
+if test "z$VENDORNAME" = "zRedHat"; then
+ install_script $OOBUILDDIR/ooo-wrapper$BINSUFFIX $PREFIX/bin/ooffice
+ for app in calc draw impress html math writer; do
+ ln -sf /usr/bin/ooffice $PREFIX/bin/oo${app}
+ done
+else
+ mkdir -p $MANDIR/man1
+ if test "z$ENABLE_QUICKSTART" = "z"; then
+ install_script $OOBUILDDIR/ooo-wrapper$BINSUFFIX $PREFIX/bin/ooo-wrapper$BINSUFFIX
+ for app in base calc draw fromtemplate impress math web writer ffice; do
+ ln -sf ooo-wrapper${BINSUFFIX} $PREFIX/bin/oo${app}${BINSUFFIX}
+ if test "z$VENDORNAME" = "zNovell" -o "z$VENDORNAME" = "zPLD" \
+ -o "z$VENDORNAME" = "zDebian"; then
+ echo ".so man1/openoffice$BINSUFFIX.1" >| $MANDIR/man1/oo${app}$BINSUFFIX.1;
+ fi
+ done
+ else
+ for app in calc draw impress math web writer base; do
+ create_qstart_wrapper "$PREFIX/bin/oo${app}${BINSUFFIX}" "-${app}" "" || exit 1;
+ done
+ create_qstart_wrapper "$PREFIX/bin/oofromtemplate${BINSUFFIX}" "" "slot:5500" || exit 1;
+ create_qstart_wrapper "$PREFIX/bin/ooffice${BINSUFFIX}" "" "" || exit 1;
+ if test "z$VENDORNAME" = "zNovell" -o "z$VENDORNAME" = "zPLD" \
+ -o "z$VENDORNAME" = "zDebian"; then
+ for app in calc draw impress math web writer base fromtemplate ffice ; do
+ echo ".so man1/openoffice$BINSUFFIX.1" >| $MANDIR/man1/oo${app}$BINSUFFIX.1;
+ done
+ fi
+ fi
+
+ # /usr/bin/ooffice symlink is necessary by java UNO components to find
+ # the UNO installation using $PATH, see
+ # http://udk.openoffice.org/common/man/spec/transparentofficecomponents.html
+ # Note: if you want to support parallel installation of more OOo versions
+ # you cannot include this link directly into the package
+ # For example, the Novell package mark this symlink as %ghost
+ # and update it in %post and %postun
+ ln -sf $OOINSTBASE/program/soffice $PREFIX/bin/soffice
+
+ # no man-page so ...
+ if test "z$VENDORNAME" != "zDebian"; then
+ install_script $TOOLSDIR/bin/ooconfig $PREFIX/bin/ooconfig
+ install_script $OOBUILDDIR/ootool$BINSUFFIX $PREFIX/bin/ootool$BINSUFFIX
+ fi
+
+ # create bash completion
+ mkdir -p $OODESTDIR/etc/bash_completion.d
+ if test "z$ENABLE_QUICKSTART" = "z"; then
+ $TOOLSDIR/bin/generate-bash-completion --binsuffix="$BINSUFFIX" $TOOLSDIR/bin/bash-completion.in $OODESTDIR/etc/bash_completion.d/ooo-wrapper$BINSUFFIX.sh
+ else
+ $TOOLSDIR/bin/generate-bash-completion --binsuffix="$BINSUFFIX" $TOOLSDIR/bin/bash-completion.in $OODESTDIR/etc/bash_completion.d/ooffice${BINSUFFIX}.sh
+ fi
+fi
if test "z$VENDORNAME" != "zRedHat"; then
mkdir -p $MANDIR/man1
@@ -622,8 +664,14 @@
directory=$1
shift
mkdir -m755 -p "$directory"/usr/bin
+ if test "$ENABLE_QUICKSTART" = ""; then
+ mkdir -m755 -p "$directory"/usr/share/man/man1
+ fi
while test -n "$1"; do
mv usr/*bin/"$1$BINSUFFIX" "$directory"/usr/bin
+ if test "$ENABLE_QUICKSTART" = ""; then
+ mv usr/share/man/man1/"$1$BINSUFFIX.1" "$directory"/usr/share/man/man1
+ fi
shift
done
}
@@ -634,6 +682,11 @@
move_wrappers pkg/openoffice.org-impress ooimpress
move_wrappers pkg/openoffice.org-math oomath
move_wrappers pkg/openoffice.org-draw oodraw
+ if test "$ENABLE_QUICKSTART" = ""; then
+ for F in bin/ooo-wrapper; do
+ mv usr/$F$BINSUFFIX pkg/openoffice.org-common/usr/bin
+ done
+ fi
# Core package contains arch dependent files
#mkdir -m755 -p pkg/openoffice.org-core/$OOINSTBASE/program/filter
@@ -662,8 +715,13 @@
mv usr/share/man/man1/openoffice$BINSUFFIX.1 \
pkg/openoffice.org-common/usr/share/man/man1
mkdir -p pkg/openoffice.org-common/etc/bash_completion.d
- mv etc/bash_completion.d/ooffice$BINSUFFIX.sh \
- pkg/openoffice.org-common/etc/bash_completion.d
+ if test "$ENABLE_QUICKSTART" = ""; then
+ mv etc/bash_completion.d/ooo-wrapper$BINSUFFIX.sh \
+ pkg/openoffice.org-common/etc/bash_completion.d
+ else
+ mv etc/bash_completion.d/ooffice$BINSUFFIX.sh \
+ pkg/openoffice.org-common/etc/bash_completion.d
+ fi
mv .$OOINSTBASE/program/java-set-classpath \
pkg/openoffice.org-common/$OOINSTBASE/program
if [ -e .$OOINSTBASE/program/kdebe1.uno.so ]; then \
--- configure.in
+++ configure.in
@@ -204,6 +204,11 @@
AC_ARG_ENABLE(gtk,
[
--disable-gtk Disables gtk+ native widgets.],
+,)
+
+AC_ARG_ENABLE(quickstart,
+[
+ --disable-quickstart Disables tiny stub factory/splash X11+glib app build.]
,)
AC_ARG_ENABLE(kde,
@@ -587,6 +592,30 @@
AC_MSG_RESULT($OOO_WIDGET_FLAGS)
AC_SUBST(OOO_WIDGET_FLAGS)
+
+AC_MSG_CHECKING([for quick-start])
+ENABLE_QUICKSTART=
+if test "$enable_quickstart" != "no"; then
+ ENABLE_QUICKSTART=TRUE
+ AC_MSG_RESULT([enabled])
+else
+ AC_MSG_RESULT([disabled])
+fi
+AC_SUBST(ENABLE_QUICKSTART)
+
+PKG_CHECK_MODULES( libstartup_notification, [ libstartup-notification-1.0 ],
+ have_startup_notification=true, have_startup_notification=false )
+
+AC_MSG_CHECKING([for startup notification in dekstop files])
+if test "$have_startup_notification" = "true" -a \
+ "$ENABLE_QUICKSTART" != "TRUE" ; then
+ STARTUPNOTIFY='true'
+ AC_MSG_RESULT([enabled])
+else
+ STARTUPNOTIFY='false'
+ AC_MSG_RESULT([disabled])
+fi
+AC_SUBST(STARTUPNOTIFY)
if test "z$BUILD_WIN32" = "zyes" -a "z$enable_cairo" = "z" ; then
AC_MSG_WARN([On Cygwin, automatically using --disable-cairo])
--- desktop/base.desktop.in.in
+++ desktop/base.desktop.in.in
@@ -8,7 +8,7 @@
Icon=ooo-base@OOO_BINSUFFIX@.png
Type=Application
Categories=Office;Database
-StartupNotify=false
+StartupNotify=@STARTUPNOTIFY@
MimeType=application/vnd.oasis.opendocument.database;application/vnd.sun.xml.base
_Name=OpenOffice.org Base
_GenericName=Database
--- desktop/calc.desktop.in.in
+++ desktop/calc.desktop.in.in
@@ -8,7 +8,7 @@
Type=Application
InitialPreference=6
Categories=Office;Spreadsheet
-StartupNotify=false
+StartupNotify=@STARTUPNOTIFY@
MimeType=application/vnd.oasis.opendocument.spreadsheet;application/vnd.oasis.opendocument.spreadsheet-template;application/vnd.sun.xml.calc;application/vnd.sun.xml.calc.template;application/vnd.stardivision.calc;application/vnd.stardivision.chart;application/msexcel;application/vnd.ms-excel;text/x-comma-separated-values;text/x-csv;application/vnd.lotus-1-2-3;text/spreadsheet;application/excel;application/x-excel;application/x-ms-excel;application/x-msexcel;application/x-sylk;application/x-xls;application/xls@ADD_OPENXML_SPREADSHEET_MIME@
_Name=OpenOffice.org Calc
_GenericName=Spreadsheet
--- desktop/draw.desktop.in.in
+++ desktop/draw.desktop.in.in
@@ -7,7 +7,7 @@
Icon=ooo-draw@OOO_BINSUFFIX@.png
Type=Application
Categories=Graphics;VectorGraphics
-StartupNotify=false
+StartupNotify=@STARTUPNOTIFY@
InitialPreference=6
MimeType=application/vnd.oasis.opendocument.graphics;application/vnd.oasis.opendocument.graphics-template;application/vnd.sun.xml.draw;application/vnd.sun.xml.draw.template;application/vnd.stardivision.draw
_Name=OpenOffice.org Draw
--- desktop/impress.desktop.in.in
+++ desktop/impress.desktop.in.in
@@ -7,7 +7,7 @@
Icon=ooo-impress@OOO_BINSUFFIX@.png
Type=Application
Categories=Office;Presentation
-StartupNotify=false
+StartupNotify=@STARTUPNOTIFY@
MimeType=application/vnd.oasis.opendocument.presentation;application/vnd.oasis.opendocument.presentation-template;application/vnd.sun.xml.impress;application/vnd.sun.xml.impress.template;application/vnd.stardivision.impress;application/mspowerpoint;application/vnd.ms-powerpoint@ADD_OPENXML_PRESENTATION_MIME@
InitialPreference=5
_Name=OpenOffice.org Impress
--- desktop/math.desktop.in.in
+++ desktop/math.desktop.in.in
@@ -7,7 +7,7 @@
Exec=oomath@OOO_BINSUFFIX@ %U
Icon=ooo-math@OOO_BINSUFFIX@.png
Type=Application
-StartupNotify=false
+StartupNotify=@STARTUPNOTIFY@
MimeType=application/vnd.oasis.opendocument.formula;application/vnd.sun.xml.math;application/vnd.stardivision.math
_Name=OpenOffice.org Math
_GenericName=Formula
--- desktop/template.desktop.in.in
+++ desktop/template.desktop.in.in
@@ -8,7 +8,7 @@
Icon=ooo-template@OOO_BINSUFFIX@.png
Type=Application
Categories=X-SuSE-Core-Office;Office;
-StartupNotify=false
+StartupNotify=@STARTUPNOTIFY@
_Name=OpenOffice.org
_GenericName=Office Suite
--- desktop/web.desktop.in.in
+++ desktop/web.desktop.in.in
@@ -7,7 +7,7 @@
Icon=ooo-web@OOO_BINSUFFIX@.png
Type=Application
Categories=Network;WebDevelopment
-StartupNotify=false
+StartupNotify=@STARTUPNOTIFY@
MimeType=application/vnd.oasis.opendocument.text-web
_Name=OpenOffice.org Writer/Web
_GenericName=Web Page Creation
--- desktop/writer.desktop.in.in
+++ desktop/writer.desktop.in.in
@@ -7,7 +7,7 @@
Icon=ooo-writer@OOO_BINSUFFIX@.png
Type=Application
Categories=Office;WordProcessor
-StartupNotify=false
+StartupNotify=@STARTUPNOTIFY@
MimeType=application/vnd.oasis.opendocument.text;application/vnd.oasis.opendocument.text-template;application/vnd.oasis.opendocument.text-master;application/vnd.sun.xml.writer;application/vnd.sun.xml.writer.template;application/vnd.sun.xml.writer.global;application/vnd.stardivision.writer;application/msword;application/vnd.ms-word;application/x-doc;text/rtf;application/rtf@ADD_OPENXML_WORD_MIME@
InitialPreference=5
_Name=OpenOffice.org Writer
|