readme.txt
1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements. See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership. The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance
9 * with the License. You may obtain a copy of the License at
10 *
11 * http://www.apache.org/licenses/LICENSE-2.0
12 *
13 * Unless required by applicable law or agreed to in writing,
14 * software distributed under the License is distributed on an
15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16 * KIND, either express or implied. See the License for the
17 * specific language governing permissions and limitations
18 * under the License.
19 *
20 *************************************************************/
21
22There are three extensions in various versions:
23
241 version_XXX/plain.oxt has no dependencies and no license.
252a version_XXX/dependency.oxt has an unsatisfied dependency and no license.
262b version_nodependencies_XXX/dependency.oxt is identical to 2a but without the
27 dependency.
283 version_XXX/license.oxt has no dependencies and a license.
29
30The different versions are:
31
32A version_none contains no version element (treated as version "0").
33B version_badelement contains a bad <version val="1"/> (not allowed by the
34 specification, but treated by the current implementation as version "0").
35C version_badvalue contains a bad <version value="1.a"/> (not allowed by the
36 specification, but treated by the current implementation as version "1").
37D version_0.0 contains <version value="0.0"/> (same as version "0").
38E version_1.2.3 contains <version value="1.2.3"/>.
39F version_1.2.4.7 contains <version value="1.2.4.7"/>.
40G version_1.02.4.7.0 contains <version value="1.02.4.7.0"/> (same as version
41 "1.2.4.7").
42H version_1.2.15.3 contains <version value="1.2.15.3"/>.
43
44The total order among the various versions is thus
45
46 A = B = D < C < E < F = G < H.
47
48Things to watch for:
49
50- If version y of extension e is to be installed and version x < y of
51 extension e is already installed, then
52 unopkg add e
53 will replace x with y.
54
55- If version y of extension e is to be installed and version x >= y of
56 extension e is already installed, then
57 unopkg add e
58 will fail with an error message.
59
60- If version y of extension e is to be installed and any version x of
61 extension e is already installed, then
62 unopkg add -f e
63 will replace x with y.
64
65- If version y of extension e is to be installed and any version x of
66 extension e is already installed, then
67 unopkg gui "Add..."
68 and
69 soffice "Tools - Package Manager... - Add..."
70 will query with a dialog whether to replace x with y. The dialog will have
71 "OK" (replace) preselected if x < y, and "Cancel" otherwise.
72
73- If replacing an installed version x of an extension e with a version y fails
74 because y has unsatisfied dependencies, or because y has a license to which the
75 user does not agree, version x is left installed afterwards.
76
77- Checking for already installed versions of an extension is only done within a
78 single layer (unopkg versus unopkg --shared; "My Packages" versus
79 "OpenOffice Packages" in unopkg gui/soffice), not across layers.
80