/
common-inc.rnc
71 lines (62 loc) · 1.89 KB
/
common-inc.rnc
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
# private is not an XML namespace, just a holder for reusable
# attribute/element sets
private.positive = xsd:positiveInteger { pattern="[1-9][0-9]*" }
private.nonnegative = "0" | private.positive
# Unix timestamp (seconds since epoch)
# For our purposes, this is always positive
private.unixts = private.positive
private.size = private.nonnegative
private.checksum =
(attribute type { "md5" }, xsd:string { length="32" pattern="[0-9a-f]*" }) |
(attribute type { "sha" }, xsd:string { length="40" pattern="[0-9a-f]*" }) |
(attribute type { "sha256" }, xsd:string { length="64" pattern="[0-9a-f]*" }) |
(attribute type { "sha" }, xsd:string { length="32" pattern="[0-9a-f]*" })
# The last option is totally broken, but is in the wild!!! :(
private.evr =
attribute epoch { private.nonnegative }?,
attribute ver { text },
attribute rel { text }?
private.localizedtext = attribute lang { "en" | "de" }, text
private.archenum = "noarch"
| "i386"
| "i486"
| "i586"
| "i686"
| "athlon"
| "x86_64"
| "pentium3"
| "pentium4"
| "s390"
| "s390x"
| "ppc"
| "ppc64"
| "ia64"
| "alphaev67"
| "alphaev6"
| "alphapca56"
| "alphaev56"
| "alphaev5"
| "alpha"
| "sparc64v"
| "sparcv9v"
| "sparc64"
| "sparcv9"
| "sparcv8"
| "sparc"
| "aarch64"
| "armv7tnhl"
| "armv7thl"
| "armv7nhl"
| "armv7hl"
| "armv7l"
| "armv6l"
| "armv5tejl"
| "armv5tel"
| "armv5l"
| "armv4tl"
| "armv4l"
| "armv3l"
| "sh3"
| "sh4"
| "sh4a"
| "src"