rpm 0.0.0 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,26 @@
1
+ module RPM
2
+ module FFI
3
+
4
+ enum :rpmCallbackType, [
5
+ :unknown, 0,
6
+ :inst_progress, (1 << 0),
7
+ :inst_start, (1 << 1),
8
+ :inst_open_file, (1 << 2),
9
+ :inst_close_file, (1 << 3),
10
+ :trans_progress, (1 << 4),
11
+ :trans_start, (1 << 5),
12
+ :trans_stop, (1 << 6),
13
+ :uninst_progress, (1 << 7),
14
+ :uninst_start, (1 << 8),
15
+ :uninst_stop, (1 << 9),
16
+ :repackage_progress, (1 << 10),
17
+ :repackage_start, (1 << 11),
18
+ :repackage_stop, (1 << 12),
19
+ :unpack_error, (1 << 13),
20
+ :cpio_error, (1 << 14),
21
+ :script_error, (1 << 15)]
22
+
23
+ callback :rpmCallbackFunction, [:pointer, :rpmCallbackType, :rpm_loff_t, :rpm_loff_t, :fnpyKey, :rpmCallbackData], :void
24
+
25
+ end
26
+ end
@@ -0,0 +1,22 @@
1
+ module RPM
2
+
3
+ module FFI
4
+
5
+ typedef :pointer, :rpmdb
6
+ typedef :pointer, :rpmdbMatchIterator
7
+
8
+ RegexpMode = enum(:rpmMireMode, [
9
+ :default, :strcmp, :regex, :glob
10
+ ])
11
+
12
+ attach_function 'rpmdbCountPackages', [:rpmdb, :string], :int
13
+ attach_function 'rpmdbGetIteratorOffset', [:rpmdbMatchIterator], :uint
14
+ attach_function 'rpmdbGetIteratorCount', [:rpmdbMatchIterator], :int
15
+ attach_function 'rpmdbSetIteratorRE', [:rpmdbMatchIterator, :rpmTagVal, :rpmMireMode, :string], :int
16
+
17
+ attach_function 'rpmdbInitIterator', [:rpmdb, :rpmDbiTagVal, :pointer, :size_t], :rpmdbMatchIterator
18
+
19
+ attach_function 'rpmdbNextIterator', [:rpmdb], :header
20
+ attach_function 'rpmdbFreeIterator', [:rpmdb], :rpmdbMatchIterator
21
+ end
22
+ end
@@ -0,0 +1,51 @@
1
+
2
+ module RPM
3
+
4
+ module FFI
5
+
6
+ typedef :pointer, :rpmds
7
+
8
+ Sense = enum(:rpmsenseFlags_e, [
9
+ :any, 0,
10
+ :less, (1 << 1),
11
+ :greater, (1 << 2),
12
+ :equal, (1 << 3),
13
+ # bit 4 unused
14
+ :posttrans, (1 << 5),
15
+ :prereq, (1 << 6),
16
+ #
17
+ :pretrans, (1 << 7),
18
+ :interp, (1 << 8),
19
+ :script_pre, (1 << 9),
20
+ :script_post, (1 << 10),
21
+ :script_preun, (1 << 11),
22
+ :script_postun, (1 << 12),
23
+ :script_verify, (1 << 13),
24
+ :script_pre, (1 << 9),
25
+ :script_post, (1 << 10),
26
+ :script_preun, (1 << 11),
27
+ :script_postun, (1 << 12),
28
+ :script_verify, (1 << 13),
29
+ :find_requires, (1 << 14),
30
+ :find_provides, (1 << 15),
31
+ #
32
+ :triggerin, (1 << 16),
33
+ :triggerun, (1 << 17),
34
+ :triggerpostun, (1 << 18),
35
+ :missingok, (1 << 19),
36
+ # 20 23 unused
37
+ :rpmlib, (1 << 24),
38
+ :triggerprein, (1 << 25),
39
+ :keyring, (1 << 26),
40
+ :strong, (1 << 27),
41
+ :config, (1 << 28) ]
42
+ )
43
+ typedef :rpmFlags, :rpmsenseFlags
44
+
45
+ # ...
46
+ attach_function 'rpmdsSingle', [:rpmTagVal, :string, :string, :rpmsenseFlags], :rpmds
47
+ # ...
48
+ attach_function 'rpmdsCompare', [:rpmds, :rpmds], :int
49
+
50
+ end
51
+ end
@@ -0,0 +1,34 @@
1
+
2
+ module RPM
3
+
4
+ module FFI
5
+
6
+ FileAttrs = enum(:rpmfileAttrs, [
7
+ :none, 0,
8
+ :config, (1 << 0),
9
+ :doc, (1 << 1),
10
+ :icon, (1 <<2),
11
+ :missingok, (1 << 3),
12
+ :noreplace, (1 << 4),
13
+ :specfile, (1 << 5),
14
+ :ghost, (1 << 6),
15
+ :license, (1 << 7),
16
+ :readme, (1 << 8),
17
+ :exclude, (1 << 9),
18
+ :unpatched, (1 << 10),
19
+ :pubkey, (1 << 11) ]
20
+ )
21
+ typedef :rpmFlags, :rpmfileAttrs
22
+
23
+ FileState = enum(:rpmfileState,
24
+ :missing, -1,
25
+ :normal, 0,
26
+ :replaced, 1,
27
+ :notinstalled, 2,
28
+ :netshared, 3,
29
+ :wrongcolor, 4
30
+ )
31
+
32
+ typedef :pointer, :rpmRelocation
33
+ end
34
+ end
@@ -0,0 +1,15 @@
1
+
2
+ module RPM
3
+
4
+ module FFI
5
+
6
+ attach_variable :RPMVERSION, :RPMVERSION, :string
7
+ attach_variable :RPMEVR, :rpmEVR, :string
8
+
9
+ attach_function 'rpmReadConfigFiles', [:string, :string], :int
10
+
11
+ # ...
12
+ attach_function 'rpmvercmp', [:string, :string], :int
13
+
14
+ end
15
+ end
@@ -0,0 +1,24 @@
1
+
2
+ module RPM
3
+
4
+ module FFI
5
+
6
+ # rpmlog
7
+ RPMLOG_PRIMASK = 0x07
8
+
9
+ Log = enum(
10
+ :emerg, 0,
11
+ :alert, 1,
12
+ :crit, 2,
13
+ :err, 3,
14
+ :warning, 4,
15
+ :notice, 5,
16
+ :info, 6,
17
+ :debug, 7
18
+ )
19
+
20
+ attach_function 'rpmlogSetMask', [:int], :int
21
+ # TODO: defines to set verbosity
22
+
23
+ end
24
+ end
@@ -0,0 +1,38 @@
1
+
2
+ module RPM
3
+
4
+ module FFI
5
+
6
+ attach_variable :MACROFILES, :macrofiles, :string
7
+ # ...
8
+
9
+ # Markers for sources of macros added throughout rpm.
10
+ RMIL_DEFAULT = -15
11
+ RMIL_MACROFILES = -13
12
+ RMIL_RPMRC = -11
13
+ RMIL_CMDLINE = -7
14
+ RMIL_TARBALL = -5
15
+ RMIL_SPEC = -3
16
+ RMIL_OLDSPEC = -1
17
+ RMIL_GLOBAL = 0
18
+
19
+ # ...
20
+ attach_function 'addMacro', [:pointer, :string, :string, :string, :int], :void
21
+ attach_function 'delMacro', [:pointer, :string], :void
22
+ # ...
23
+ attach_function 'expandMacros', [:pointer, :pointer, :pointer, :size_t], :int
24
+ # ...
25
+ attach_function 'rpmInitMacros', [:pointer, :string], :void
26
+ # ...
27
+
28
+ # RPMIO
29
+ attach_function 'Fstrerror', [:pointer], :string
30
+ # ...
31
+ attach_function 'Fclose', [:pointer], :int
32
+ # ...
33
+ attach_function 'Fopen', [:string, :string], :pointer
34
+ # ...
35
+ attach_function 'Ferror', [:pointer], :int
36
+ end
37
+
38
+ end
@@ -0,0 +1,42 @@
1
+
2
+ module RPM
3
+
4
+ module FFI
5
+
6
+ typedef :pointer, :rpmProblem
7
+
8
+ ProbFilter = enum(:rpmprobFilterFlags_e, [
9
+ :none, 0,
10
+ :ignoreos, (1 << 0),
11
+ :ignorearch, (1 << 1),
12
+ :replacepkg, (1 << 2),
13
+ :forcerelocate, (1 << 3),
14
+ :replacenewfiles, (1 << 4),
15
+ :replaceoldfiles, (1 << 5),
16
+ :oldpackage, (1 << 6),
17
+ :diskspace, (1 << 7),
18
+ :disknodes, (1 << 8) ]
19
+ )
20
+
21
+ typedef :rpmFlags, :rpmprobFilterFlags
22
+
23
+ ProblemType = enum(:rpmProblemType, [
24
+ :badarch,
25
+ :bados,
26
+ :pkg_installed,
27
+ :badrelocate,
28
+ :requires,
29
+ :conflict,
30
+ :new_file_conflict,
31
+ :file_conflict,
32
+ :oldpackage,
33
+ :diskspace,
34
+ :disknodes,
35
+ :obsoletes
36
+ ])
37
+
38
+ attach_function 'rpmProblemGetType', [:rpmProblem], :rpmProblemType
39
+ attach_function 'rpmProblemGetKey', [:rpmProblem], :fnpyKey
40
+ attach_function 'rpmProblemString', [:rpmProblem], :pointer
41
+ end
42
+ end
@@ -0,0 +1,13 @@
1
+ module RPM
2
+
3
+ module FFI
4
+
5
+ typedef :pointer, :rpmps
6
+ typedef :pointer, :rpmpsi
7
+
8
+ attach_function 'rpmpsInitIterator', [:rpmps], :rpmpsi
9
+ attach_function 'rpmpsNextIterator', [:rpmpsi], :int
10
+ attach_function 'rpmpsGetProblem', [:rpmpsi], :rpmProblem
11
+ attach_function 'rpmpsFree', [:rpmps], :rpmps
12
+ end
13
+ end
@@ -0,0 +1,299 @@
1
+ module RPM
2
+
3
+ module FFI
4
+
5
+ Tag = enum(:rpmTag, [
6
+ :not_found, -1,
7
+ :headerimage, 61,
8
+ :headersignatures, 62,
9
+ :headerimmutable, 63,
10
+ :headerregions, 64,
11
+ :headeri18ntable, 100,
12
+ :sig_base, 256,
13
+ :sigsize, 256+1,
14
+ :siglemd5_1, 256+2,
15
+ :sigpgp, 256+3,
16
+ :siglemd5_2, 256+4,
17
+ :sigmd5, 256+5,
18
+ :siggpg, 256+6,
19
+ :sigpgp5, 256+7,
20
+ :badsha1_1, 256+8,
21
+ :badsha1_2, 256+9,
22
+ :pubkeys, 256+10,
23
+ :dsaheader, 256+11,
24
+ :rsaheader, 256+12,
25
+ :sha1header, 256+13,
26
+ :longsigsize, 256+14,
27
+ :longarchivesize, 256+15,
28
+ :name, 1000,
29
+ :version, 1001,
30
+ :release, 1002,
31
+ :epoch, 1003,
32
+ :summary, 1004,
33
+ :description, 1005,
34
+ :buildtime, 1006,
35
+ :buildhost, 1007,
36
+ :installtime, 1008,
37
+ :size, 1009,
38
+ :distribution, 1010,
39
+ :vendor, 1011,
40
+ :gif, 1012,
41
+ :xpm, 1013,
42
+ :license, 1014,
43
+ :packager, 1015,
44
+ :group, 1016,
45
+ :changelog, 1017,
46
+ :source, 1018,
47
+ :patch, 1019,
48
+ :url, 1020,
49
+ :os, 1021,
50
+ :arch, 1022,
51
+ :prein, 1023,
52
+ :postin, 1024,
53
+ :preun, 1025,
54
+ :postun, 1026,
55
+ :oldfilenames, 1027,
56
+ :filesizes, 1028,
57
+ :filestates, 1029,
58
+ :filemodes, 1030,
59
+ :fileuids, 1031,
60
+ :filegids, 1032,
61
+ :filerdevs, 1033,
62
+ :filemtimes, 1034,
63
+ :filedigests, 1035,
64
+ :filemd5s, 1035,
65
+ :filelinktos, 1036,
66
+ :fileflags, 1037,
67
+ :root, 1038,
68
+ :fileusername, 1039,
69
+ :filegroupname, 1040,
70
+ :exclude, 1041,
71
+ :exclusive, 1042,
72
+ :icon, 1043,
73
+ :source, 1044,
74
+ :fileverifyflags, 1045,
75
+ :archivesize, 1046,
76
+ :providename, 1047,
77
+ :requireflags, 1048,
78
+ :requirename, 1049,
79
+ :requireversion, 1050,
80
+ :nosource, 1051,
81
+ :nopatch, 1052,
82
+ :conflictflags, 1053,
83
+ :conflictname, 1054,
84
+ :conflictversion, 1055,
85
+ :defaultprefix, 1056,
86
+ :buildroot, 1057,
87
+ :installprefix, 1058,
88
+ :excludearch, 1059,
89
+ :excludeos, 1060,
90
+ :exclusivearch, 1061,
91
+ :exclusiveos, 1062,
92
+ :autoreqprov, 1063,
93
+ :version, 1064,
94
+ :triggerscripts, 1065,
95
+ :triggername, 1066,
96
+ :triggerversion, 1067,
97
+ :triggerflags, 1068,
98
+ :triggerindex, 1069,
99
+ :verifyscript, 1079,
100
+ :changelogtime, 1080,
101
+ :changelogname, 1081,
102
+ :changelogtext, 1082,
103
+ :brokenmd5, 1083,
104
+ :prereq, 1084,
105
+ :preinprog, 1085,
106
+ :postinprog, 1086,
107
+ :preunprog, 1087,
108
+ :postunprog, 1088,
109
+ :buildarchs, 1089,
110
+ :obsoletename, 1090,
111
+ :verifyscriptprog, 1091,
112
+ :triggerscriptprog, 1092,
113
+ :docdir, 1093,
114
+ :cookie, 1094,
115
+ :filedevices, 1095,
116
+ :fileinodes, 1096,
117
+ :filelangs, 1097,
118
+ :prefixes, 1098,
119
+ :instprefixes, 1099,
120
+ :triggerin, 1100,
121
+ :triggerun, 1101,
122
+ :triggerpostun, 1102,
123
+ :autoreq, 1103,
124
+ :autoprov, 1104,
125
+ :capability, 1105,
126
+ :sourcepackage, 1106,
127
+ :oldorigfilenames, 1107,
128
+ :buildprereq, 1108,
129
+ :buildrequires, 1109,
130
+ :buildconflicts, 1110,
131
+ :buildmacros, 1111,
132
+ :provideflags, 1112,
133
+ :provideversion, 1113,
134
+ :obsoleteflags, 1114,
135
+ :obsoleteversion, 1115,
136
+ :dirindexes, 1116,
137
+ :basenames, 1117,
138
+ :dirnames, 1118,
139
+ :origdirindexes, 1119,
140
+ :origbasenames, 1120,
141
+ :origdirnames, 1121,
142
+ :optflags, 1122,
143
+ :disturl, 1123,
144
+ :payloadformat, 1124,
145
+ :payloadcompressor, 1125,
146
+ :payloadflags, 1126,
147
+ :installcolor, 1127,
148
+ :installtid, 1128,
149
+ :removetid, 1129,
150
+ :sha1rhn, 1130,
151
+ :rhnplatform, 1131,
152
+ :platform, 1132,
153
+ :patchesname, 1133,
154
+ :patchesflags, 1134,
155
+ :patchesversion, 1135,
156
+ :cachectime, 1136,
157
+ :cachepkgpath, 1137,
158
+ :cachepkgsize, 1138,
159
+ :cachepkgmtime, 1139,
160
+ :filecolors, 1140,
161
+ :fileclass, 1141,
162
+ :classdict, 1142,
163
+ :filedependsx, 1143,
164
+ :filedependsn, 1144,
165
+ :dependsdict, 1145,
166
+ :sourcepkgid, 1146,
167
+ :filecontexts, 1147,
168
+ :fscontexts, 1148,
169
+ :recontexts, 1149,
170
+ :policies, 1150,
171
+ :pretrans, 1151,
172
+ :posttrans, 1152,
173
+ :pretransprog, 1153,
174
+ :posttransprog, 1154,
175
+ :disttag, 1155,
176
+ :suggestsname, 1156,
177
+ :suggestsversion, 1157,
178
+ :suggestsflags, 1158,
179
+ :enhancesname, 1159,
180
+ :enhancesversion, 1160,
181
+ :enhancesflags, 1161,
182
+ :priority, 1162,
183
+ :cvsid, 1163,
184
+ :blinkpkgid, 1164,
185
+ :blinkhdrid, 1165,
186
+ :blinknevra, 1166,
187
+ :flinkpkgid, 1167,
188
+ :flinkhdrid, 1168,
189
+ :flinknevra, 1169,
190
+ :packageorigin, 1170,
191
+ :triggerprein, 1171,
192
+ :buildsuggests, 1172,
193
+ :buildenhances, 1173,
194
+ :scriptstates, 1174,
195
+ :scriptmetrics, 1175,
196
+ :buildcpuclock, 1176,
197
+ :filedigestalgos, 1177,
198
+ :variants, 1178,
199
+ :xmajor, 1179,
200
+ :xminor, 1180,
201
+ :repotag, 1181,
202
+ :keywords, 1182,
203
+ :buildplatforms, 1183,
204
+ :packagecolor, 1184,
205
+ :packageprefcolor, 1185,
206
+ :xattrsdict, 1186,
207
+ :filexattrsx, 1187,
208
+ :depattrsdict, 1188,
209
+ :conflictattrsx, 1189,
210
+ :obsoleteattrsx, 1190,
211
+ :provideattrsx, 1191,
212
+ :requireattrsx, 1192,
213
+ :buildprovides, 1193,
214
+ :buildobsoletes, 1194,
215
+ :dbinstance, 1195,
216
+ :nvra, 1196,
217
+ :filenames, 5000,
218
+ :fileprovide, 5001,
219
+ :filerequire, 5002,
220
+ :fsnames, 5003,
221
+ :fssizes, 5004,
222
+ :triggerconds, 5005,
223
+ :triggertype, 5006,
224
+ :origfilenames, 5007,
225
+ :longfilesizes, 5008,
226
+ :longsize, 5009,
227
+ :filecaps, 5010,
228
+ :filedigestalgo, 5011,
229
+ :bugurl, 5012,
230
+ :evr, 5013,
231
+ :nvr, 5014,
232
+ :nevr, 5015,
233
+ :nevra, 5016,
234
+ :headercolor, 5017,
235
+ :verbose, 5018,
236
+ :epochnum, 5019,
237
+ :preinflags, 5020,
238
+ :postinflags, 5021,
239
+ :preunflags, 5022,
240
+ :postunflags, 5023,
241
+ :pretransflags, 5024,
242
+ :posttransflags, 5025,
243
+ :verifyscriptflags, 5026,
244
+ :triggerscriptflags, 5027,
245
+ :collections, 5029,
246
+ :policynames, 5030,
247
+ :policytypes, 5031,
248
+ :policytypesindexes, 5032,
249
+ :policyflags, 5033,
250
+ :vcs, 5034,
251
+ :ordername, 5035,
252
+ :orderversion, 5036,
253
+ :orderflags, 5037,
254
+ :firstfree_tag ]
255
+ )
256
+
257
+ Dbi = enum(:rpmDbiTag_e, [
258
+ :packages, 0,
259
+ :label, 2,
260
+ :name, Tag[:name],
261
+ :basenames, Tag[:basenames],
262
+ :group, Tag[:group],
263
+ :requirename, Tag[:requirename],
264
+ :providename, Tag[:providename],
265
+ :conflictname, Tag[:conflictname],
266
+ :obsoletename, Tag[:obsoletename],
267
+ :triggername, Tag[:triggername],
268
+ :dirnames, Tag[:dirnames],
269
+ :installtid, Tag[:installtid],
270
+ :sigmd5, Tag[:sigmd5],
271
+ :sha1header, Tag[:sha1header] ]
272
+ )
273
+
274
+ TagType = enum( :rpmTagType, [
275
+ :null_type, 0,
276
+ :char_type, 1,
277
+ :int8_type, 2,
278
+ :int16_type, 3,
279
+ :int32_type, 4,
280
+ :int64_type, 5,
281
+ :string_type, 6,
282
+ :bin_type, 7,
283
+ :string_array_type, 8,
284
+ :i18nstring_type, 9 ])
285
+
286
+ TagReturnType = enum(:rpmTagReturnType_e, [
287
+ :any_return_type, 0,
288
+ :scalar_return_type, 0x00010000,
289
+ :array_return_type, 0x00020000,
290
+ :mapping_return_type, 0x00040000,
291
+ :mask_return_type, 0xffff0000
292
+ ]
293
+ )
294
+ typedef :rpmFlags, :rpmTagReturnType
295
+
296
+ attach_function 'rpmTagGetReturnType', [:rpmTagVal], :rpmTagReturnType
297
+
298
+ end
299
+ end
@@ -0,0 +1,37 @@
1
+ module RPM
2
+
3
+ module FFI
4
+
5
+ typedef :pointer, :rpmtd
6
+
7
+ attach_function 'rpmtdNew', [], :pointer
8
+ attach_function 'rpmtdFree', [:rpmtd], :pointer
9
+ attach_function 'rpmtdReset', [:rpmtd], :void
10
+ attach_function 'rpmtdFreeData', [:rpmtd], :void
11
+ attach_function 'rpmtdCount', [:rpmtd], :uint32
12
+ attach_function 'rpmtdTag', [:rpmtd], :rpmTagVal
13
+ attach_function 'rpmtdType', [:rpmtd], TagType
14
+ # ...
15
+ attach_function 'rpmtdInit', [:rpmtd], :int
16
+ attach_function 'rpmtdNext', [:rpmtd], :int
17
+ # ...
18
+ attach_function 'rpmtdNextUint32', [:rpmtd], :pointer
19
+ attach_function 'rpmtdNextUint64', [:rpmtd], :pointer
20
+ attach_function 'rpmtdNextString', [:rpmtd], :string
21
+ attach_function 'rpmtdGetChar', [:rpmtd], :pointer
22
+ attach_function 'rpmtdGetUint16', [:rpmtd], :pointer
23
+ attach_function 'rpmtdGetUint32', [:rpmtd], :pointer
24
+ attach_function 'rpmtdGetUint64', [:rpmtd], :pointer
25
+ attach_function 'rpmtdGetString', [:rpmtd], :string
26
+ attach_function 'rpmtdGetNumber', [:rpmtd], :uint64
27
+ # ...
28
+ attach_function 'rpmtdFromUint8', [:rpmtd, :rpmTagVal, :pointer, :rpm_count_t], :int
29
+ attach_function 'rpmtdFromUint16', [:rpmtd, :rpmTagVal, :pointer, :rpm_count_t], :int
30
+ attach_function 'rpmtdFromUint32', [:rpmtd, :rpmTagVal, :pointer, :rpm_count_t], :int
31
+ attach_function 'rpmtdFromUint64', [:rpmtd, :rpmTagVal, :pointer, :rpm_count_t], :int
32
+ attach_function 'rpmtdFromString', [:rpmtd, :rpmTagVal, :string], :int
33
+ attach_function 'rpmtdFromStringArray', [:rpmtd, :rpmTagVal, :pointer, :rpm_count_t], :int
34
+ # ...
35
+
36
+ end
37
+ end
@@ -0,0 +1,70 @@
1
+ module RPM
2
+
3
+ module FFI
4
+
5
+ TransFlags = enum(:rpmtransFlags_e, [
6
+ :none, 0,
7
+ :test, (1 << 0),
8
+ :build_probs, (1 << 1),
9
+ :noscripts, (1 << 2),
10
+ :justdb, (1 << 3),
11
+ :notriggers, (1 << 4),
12
+ :nodocs, (1 << 5),
13
+ :allfiles, (1 << 6),
14
+ # bit 7 unused
15
+ :nocontexts, (1 << 8),
16
+ # bits 9-15 unused
17
+ :notriggerprein, (1 << 16),
18
+ :nopre, (1 << 17),
19
+ :nopost, (1 << 18),
20
+ :notriggerin, (1 << 19),
21
+ :notriggerun, (1 << 20),
22
+ :nopreun, (1 << 21),
23
+ :nopostun, (1 << 22),
24
+ :notriggerpostun, (11 << 23),
25
+ # bits 24-25 unused
26
+ :nocollections, (1 << 26),
27
+ :nomd5, (1 << 27),
28
+ :nofiledigest, (1 << 27),
29
+ # bits 28-29 unused
30
+ :noconfigs, (1 << 30),
31
+ :deploops, (1 << 31) ]
32
+ )
33
+
34
+ typedef :pointer, :rpmts
35
+ typedef :pointer, :rpmps
36
+ typedef :rpmFlags, :rpmtransFlags
37
+
38
+ attach_function 'rpmtsCheck', [:rpmts], :int
39
+ attach_function 'rpmtsOrder', [:rpmts], :int
40
+ attach_function 'rpmtsRun', [:rpmts, :rpmps, :int], :int
41
+ attach_function 'rpmtsLink', [:rpmts], :rpmts
42
+ attach_function 'rpmtsCloseDB', [:rpmts], :int
43
+ attach_function 'rpmtsOpenDB', [:rpmts, :int], :int
44
+ attach_function 'rpmtsInitDB', [:rpmts, :int], :int
45
+ attach_function 'rpmtsGetDBMode', [:rpmts], :int
46
+ attach_function 'rpmtsSetDBMode', [:rpmts, :int], :int
47
+ attach_function 'rpmtsRebuildDB', [:rpmts], :int
48
+ attach_function 'rpmtsVerifyDB', [:rpmts], :int
49
+ attach_function 'rpmtsInitIterator', [:rpmts, :rpmDbiTagVal, :pointer, :int], :rpmdbMatchIterator
50
+ # ...
51
+ attach_function 'rpmtsProblems', [:rpmts], :rpmps
52
+ # more...
53
+ attach_function 'rpmtsFree', [:rpmts], :pointer
54
+ #..
55
+ attach_function 'rpmtsSetNotifyCallback', [:rpmts, :rpmCallbackFunction, :rpmCallbackData], :int
56
+ #...
57
+ attach_function 'rpmtsRootDir', [:rpmts], :string
58
+ attach_function 'rpmtsSetRootDir', [:rpmts, :string], :int
59
+ #...
60
+ attach_function 'rpmtsGetRdb', [:rpmts], :rpmdb
61
+ # ..
62
+ attach_function 'rpmtsFlags', [:rpmts], :rpmtransFlags
63
+ attach_function 'rpmtsSetFlags', [:rpmts, :rpmtransFlags], :rpmtransFlags
64
+ #...
65
+ attach_function 'rpmtsCreate', [], :rpmts
66
+ attach_function 'rpmtsAddInstallElement', [:rpmts, :header, :fnpyKey, :int, :rpmRelocation], :int
67
+ # ...
68
+
69
+ end
70
+ end