let ipkg fail when a package file to be installed is not found
[openwrt/svn-archive/archive.git] / openwrt / package / busybox / patches / 912-ipkg-no_warnings.patch
1 #
2 # remove (numerous) compile warnings
3 #
4 diff -ruN busybox-1.1.2+ipkg-0.99.162/archival/libipkg/file_util.c busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/file_util.c
5 --- busybox-1.1.2+ipkg-0.99.162/archival/libipkg/file_util.c 2006-05-09 02:06:48.000000000 +0200
6 +++ busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/file_util.c 2006-05-09 02:16:48.000000000 +0200
7 @@ -123,7 +123,7 @@
8
9 int file_mkdir_hier(const char *path, long mode)
10 {
11 - return bb_make_directory(path, mode, FILEUTILS_RECUR);
12 + return bb_make_directory((char *)path, mode, FILEUTILS_RECUR);
13 }
14
15 char *file_md5sum_alloc(const char *file_name)
16 diff -ruN busybox-1.1.2+ipkg-0.99.162/archival/libipkg/ipkg_cmd.c busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/ipkg_cmd.c
17 --- busybox-1.1.2+ipkg-0.99.162/archival/libipkg/ipkg_cmd.c 2006-05-09 02:23:37.000000000 +0200
18 +++ busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/ipkg_cmd.c 2006-05-09 02:23:17.000000000 +0200
19 @@ -246,7 +246,7 @@
20 in = fopen (tmp_file_name, "r");
21 out = fopen (list_file_name, "w");
22 if (in && out)
23 - inflate_unzip (in, out);
24 + inflate_unzip (fileno(in), fileno(out));
25 else
26 err = 1;
27 if (in)
28 @@ -894,14 +894,13 @@
29 pkg_vec_free(available);
30 } else {
31 pkg_vec_t *installed_pkgs = pkg_vec_alloc();
32 - int i;
33 int flagged_pkg_count = 0;
34 int removed;
35
36 pkg_hash_fetch_all_installed(&conf->pkg_hash, installed_pkgs);
37
38 for (i = 0; i < installed_pkgs->len; i++) {
39 - pkg_t *pkg = installed_pkgs->pkgs[i];
40 + pkg = installed_pkgs->pkgs[i];
41 if (pkg->state_flag & SF_USER) {
42 flagged_pkg_count++;
43 } else {
44 @@ -921,7 +920,7 @@
45 do {
46 removed = 0;
47 for (i = 0; i < installed_pkgs->len; i++) {
48 - pkg_t *pkg = installed_pkgs->pkgs[i];
49 + pkg = installed_pkgs->pkgs[i];
50 if (!(pkg->state_flag & SF_USER)
51 && !pkg_has_installed_dependents(conf, pkg->parent, pkg, NULL)) {
52 removed++;
53 @@ -976,7 +975,7 @@
54 {
55 int i;
56 pkg_t *pkg;
57 - const char *flags = argv[0];
58 + char *flags = argv[0];
59
60 global_conf = conf;
61 signal(SIGINT, sigint_handler);
62 diff -ruN busybox-1.1.2+ipkg-0.99.162/archival/libipkg/ipkg_conf.c busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/ipkg_conf.c
63 --- busybox-1.1.2+ipkg-0.99.162/archival/libipkg/ipkg_conf.c 2006-05-09 02:12:04.000000000 +0200
64 +++ busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/ipkg_conf.c 2006-05-09 02:16:48.000000000 +0200
65 @@ -542,14 +542,14 @@
66 if (strcmp(type, "option") == 0) {
67 ipkg_conf_set_option(options, name, value);
68 } else if (strcmp(type, "src") == 0) {
69 - if (!nv_pair_list_find(pkg_src_list, name)) {
70 + if (!nv_pair_list_find((nv_pair_list_t *)pkg_src_list, name)) {
71 pkg_src_list_append (pkg_src_list, name, value, extra, 0);
72 } else {
73 ipkg_message(conf, IPKG_ERROR, "ERROR: duplicate src declaration. Skipping:\n\t src %s %s\n",
74 name, value);
75 }
76 } else if (strcmp(type, "src/gz") == 0) {
77 - if (!nv_pair_list_find(pkg_src_list, name)) {
78 + if (!nv_pair_list_find((nv_pair_list_t *)pkg_src_list, name)) {
79 pkg_src_list_append (pkg_src_list, name, value, extra, 1);
80 } else {
81 ipkg_message(conf, IPKG_ERROR, "ERROR: duplicate src declaration. Skipping:\n\t src %s %s\n",
82 diff -ruN busybox-1.1.2+ipkg-0.99.162/archival/libipkg/ipkg_download.c busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/ipkg_download.c
83 --- busybox-1.1.2+ipkg-0.99.162/archival/libipkg/ipkg_download.c 2006-05-09 02:12:04.000000000 +0200
84 +++ busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/ipkg_download.c 2006-05-09 02:22:51.000000000 +0200
85 @@ -166,7 +166,7 @@
86 if (err)
87 return err;
88 pkg->local_filename = strdup(url);
89 - ipkg_message(conf, IPKG_DEBUG2, "Package %s provided by hand \(%s\).\n", pkg->name,pkg->local_filename);
90 + ipkg_message(conf, IPKG_DEBUG2, "Package %s provided by hand (%s).\n", pkg->name,pkg->local_filename);
91 pkg->provided_by_hand = 1;
92
93 } else {
94 diff -ruN busybox-1.1.2+ipkg-0.99.162/archival/libipkg/libipkg.c busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/libipkg.c
95 --- busybox-1.1.2+ipkg-0.99.162/archival/libipkg/libipkg.c 2006-05-09 02:12:05.000000000 +0200
96 +++ busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/libipkg.c 2006-05-09 02:16:48.000000000 +0200
97 @@ -445,7 +445,7 @@
98 int
99 ipkg_op (int argc, char *argv[])
100 {
101 - int err, optind;
102 + int err, opt_index;
103 args_t args;
104 char *cmd_name;
105 ipkg_cmd_t *cmd;
106 @@ -453,13 +453,13 @@
107
108 args_init (&args);
109
110 - optind = args_parse (&args, argc, argv);
111 - if (optind == argc || optind < 0)
112 + opt_index = args_parse (&args, argc, argv);
113 + if (opt_index == argc || opt_index < 0)
114 {
115 args_usage ("ipkg must have one sub-command argument");
116 }
117
118 - cmd_name = argv[optind++];
119 + cmd_name = argv[opt_index++];
120 /* Pigi: added a flag to disable the checking of structures if the command does not need to
121 read anything from there.
122 */
123 @@ -509,7 +509,7 @@
124 args_usage (NULL);
125 }
126
127 - if (cmd->requires_args && optind == argc)
128 + if (cmd->requires_args && opt_index == argc)
129 {
130 fprintf (stderr,
131 "%s: the ``%s'' command requires at least one argument\n",
132 @@ -517,7 +517,7 @@
133 args_usage (NULL);
134 }
135
136 - err = ipkg_cmd_exec (cmd, &ipkg_conf, argc - optind, (const char **) (argv + optind), NULL);
137 + err = ipkg_cmd_exec (cmd, &ipkg_conf, argc - opt_index, (const char **) (argv + opt_index), NULL);
138
139 ipkg_conf_deinit (&ipkg_conf);
140
141 diff -ruN busybox-1.1.2+ipkg-0.99.162/archival/libipkg/md5.c busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/md5.c
142 --- busybox-1.1.2+ipkg-0.99.162/archival/libipkg/md5.c 2006-05-09 02:06:48.000000000 +0200
143 +++ busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/md5.c 2006-05-09 02:16:48.000000000 +0200
144 @@ -25,7 +25,6 @@
145 int md5_stream(FILE *stream, void *resblock)
146 {
147 int fd;
148 - int sum;
149
150 if( (fd = fileno(stream)) == -1 ) {
151 bb_error_msg("bad file descriptor");
152 diff -ruN busybox-1.1.2+ipkg-0.99.162/archival/libipkg/pkg.c busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/pkg.c
153 --- busybox-1.1.2+ipkg-0.99.162/archival/libipkg/pkg.c 2006-05-09 02:12:05.000000000 +0200
154 +++ busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/pkg.c 2006-05-09 02:16:48.000000000 +0200
155 @@ -528,6 +528,7 @@
156 char * pkg_formatted_field(pkg_t *pkg, const char *field )
157 {
158 static size_t LINE_LEN = 128;
159 + char line_str[LINE_LEN];
160 char * temp = (char *)malloc(1);
161 int len = 0;
162 int flag_provide_false = 0;
163 @@ -567,7 +568,6 @@
164 if (strcasecmp(field, "Conffiles") == 0) {
165 /* Conffiles */
166 conffile_list_elt_t *iter;
167 - char confstr[LINE_LEN];
168
169 if (pkg->conffiles.head == NULL) {
170 return temp;
171 @@ -588,15 +588,14 @@
172 strncpy(temp, "Conffiles:\n", 12);
173 for (iter = pkg->conffiles.head; iter; iter = iter->next) {
174 if (iter->data->name && iter->data->value) {
175 - snprintf(confstr, LINE_LEN, "%s %s\n", iter->data->name, iter->data->value);
176 - strncat(temp, confstr, strlen(confstr));
177 + snprintf(line_str, LINE_LEN, "%s %s\n", iter->data->name, iter->data->value);
178 + strncat(temp, line_str, strlen(line_str));
179 }
180 }
181 } else if (strcasecmp(field, "Conflicts") == 0) {
182 int i;
183
184 if (pkg->conflicts_count) {
185 - char conflictstr[LINE_LEN];
186 len = 14 ;
187 for(i = 0; i < pkg->conflicts_count; i++) {
188 len = len + (strlen(pkg->conflicts_str[i])+5);
189 @@ -609,8 +608,8 @@
190 temp[0]='\0';
191 strncpy(temp, "Conflicts:", 11);
192 for(i = 0; i < pkg->conflicts_count; i++) {
193 - snprintf(conflictstr, LINE_LEN, "%s %s", i == 0 ? "" : ",", pkg->conflicts_str[i]);
194 - strncat(temp, conflictstr, strlen(conflictstr));
195 + snprintf(line_str, LINE_LEN, "%s %s", i == 0 ? "" : ",", pkg->conflicts_str[i]);
196 + strncat(temp, line_str, strlen(line_str));
197 }
198 strncat(temp, "\n", strlen("\n"));
199 }
200 @@ -625,7 +624,6 @@
201 int i;
202
203 if (pkg->depends_count) {
204 - char depstr[LINE_LEN];
205 len = 14 ;
206 for(i = 0; i < pkg->depends_count; i++) {
207 len = len + (strlen(pkg->depends_str[i])+4);
208 @@ -638,8 +636,8 @@
209 temp[0]='\0';
210 strncpy(temp, "Depends:", 10);
211 for(i = 0; i < pkg->depends_count; i++) {
212 - snprintf(depstr, LINE_LEN, "%s %s", i == 0 ? "" : ",", pkg->depends_str[i]);
213 - strncat(temp, depstr, strlen(depstr));
214 + snprintf(line_str, LINE_LEN, "%s %s", i == 0 ? "" : ",", pkg->depends_str[i]);
215 + strncat(temp, line_str, strlen(line_str));
216 }
217 strncat(temp, "\n", strlen("\n"));
218 }
219 @@ -804,7 +802,6 @@
220 /* Replaces | Recommends*/
221 if (strcasecmp (field, "Replaces") == 0) {
222 if (pkg->replaces_count) {
223 - char replstr[LINE_LEN];
224 len = 14;
225 for (i = 0; i < pkg->replaces_count; i++) {
226 len = len + (strlen(pkg->replaces_str[i])+5);
227 @@ -817,14 +814,13 @@
228 temp[0]='\0';
229 strncpy(temp, "Replaces:", 12);
230 for (i = 0; i < pkg->replaces_count; i++) {
231 - snprintf(replstr, LINE_LEN, "%s %s", i == 0 ? "" : ",", pkg->replaces_str[i]);
232 - strncat(temp, replstr, strlen(replstr));
233 + snprintf(line_str, LINE_LEN, "%s %s", i == 0 ? "" : ",", pkg->replaces_str[i]);
234 + strncat(temp, line_str, strlen(line_str));
235 }
236 strncat(temp, "\n", strlen("\n"));
237 }
238 } else if (strcasecmp (field, "Recommends") == 0) {
239 if (pkg->recommends_count) {
240 - char recstr[LINE_LEN];
241 len = 15;
242 for(i = 0; i < pkg->recommends_count; i++) {
243 len = len + (strlen( pkg->recommends_str[i])+5);
244 @@ -837,8 +833,8 @@
245 temp[0]='\0';
246 strncpy(temp, "Recommends:", 13);
247 for(i = 0; i < pkg->recommends_count; i++) {
248 - snprintf(recstr, LINE_LEN, "%s %s", i == 0 ? "" : ",", pkg->recommends_str[i]);
249 - strncat(temp, recstr, strlen(recstr));
250 + snprintf(line_str, LINE_LEN, "%s %s", i == 0 ? "" : ",", pkg->recommends_str[i]);
251 + strncat(temp, line_str, strlen(line_str));
252 }
253 strncat(temp, "\n", strlen("\n"));
254 }
255 @@ -907,7 +903,6 @@
256 } else if (strcasecmp(field, "Suggests") == 0) {
257 if (pkg->suggests_count) {
258 int i;
259 - char sugstr[LINE_LEN];
260 len = 13;
261 for(i = 0; i < pkg->suggests_count; i++) {
262 len = len + (strlen(pkg->suggests_str[i])+5);
263 @@ -920,8 +915,8 @@
264 temp[0]='\0';
265 strncpy(temp, "Suggests:", 10);
266 for(i = 0; i < pkg->suggests_count; i++) {
267 - snprintf(sugstr, LINE_LEN, "%s %s", i == 0 ? "" : ",", pkg->suggests_str[i]);
268 - strncat(temp, sugstr, strlen(sugstr));
269 + snprintf(line_str, LINE_LEN, "%s %s", i == 0 ? "" : ",", pkg->suggests_str[i]);
270 + strncat(temp, line_str, strlen(line_str));
271 }
272 strncat(temp, "\n", strlen("\n"));
273 }
274 @@ -1140,10 +1135,8 @@
275 return 0;
276 }
277
278 -int pkg_name_version_and_architecture_compare(void *p1, void *p2)
279 +int pkg_name_version_and_architecture_compare(pkg_t *a, pkg_t *b)
280 {
281 - const pkg_t *a = *(const pkg_t **)p1;
282 - const pkg_t *b = *(const pkg_t **)p2;
283 int namecmp;
284 int vercmp;
285 if (!a->name || !b->name) {
286 @@ -1170,10 +1163,8 @@
287 return 0;
288 }
289
290 -int abstract_pkg_name_compare(void *p1, void *p2)
291 +int abstract_pkg_name_compare(abstract_pkg_t *a, abstract_pkg_t *b)
292 {
293 - const abstract_pkg_t *a = *(const abstract_pkg_t **)p1;
294 - const abstract_pkg_t *b = *(const abstract_pkg_t **)p2;
295 if (!a->name || !b->name) {
296 fprintf(stderr, "abstract_pkg_name_compare: a=%p a->name=%p b=%p b->name=%p\n",
297 a, a->name, b, b->name);
298 @@ -1193,7 +1184,7 @@
299 #endif
300
301 if (pkg->epoch) {
302 - sprintf_alloc(&epoch_str, "%d:", pkg->epoch);
303 + sprintf_alloc(&epoch_str, "%d:", (int)(pkg->epoch));
304 } else {
305 epoch_str = strdup("");
306 }
307 diff -ruN busybox-1.1.2+ipkg-0.99.162/archival/libipkg/pkg.h busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/pkg.h
308 --- busybox-1.1.2+ipkg-0.99.162/archival/libipkg/pkg.h 2006-05-09 02:12:05.000000000 +0200
309 +++ busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/pkg.h 2006-05-09 02:16:48.000000000 +0200
310 @@ -194,8 +194,8 @@
311 char *pkg_version_str_alloc(pkg_t *pkg);
312
313 int pkg_compare_versions(const pkg_t *pkg, const pkg_t *ref_pkg);
314 -int pkg_name_version_and_architecture_compare(void *a, void *b);
315 -int abstract_pkg_name_compare(void *a, void *b);
316 +int pkg_name_version_and_architecture_compare(pkg_t *a, pkg_t *b);
317 +int abstract_pkg_name_compare(abstract_pkg_t *a, abstract_pkg_t *b);
318
319 char * pkg_formatted_info(pkg_t *pkg );
320 char * pkg_formatted_field(pkg_t *pkg, const char *field );
321 diff -ruN busybox-1.1.2+ipkg-0.99.162/archival/libipkg/pkg_depends.c busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/pkg_depends.c
322 --- busybox-1.1.2+ipkg-0.99.162/archival/libipkg/pkg_depends.c 2006-05-09 02:12:05.000000000 +0200
323 +++ busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/pkg_depends.c 2006-05-09 02:16:48.000000000 +0200
324 @@ -68,7 +68,7 @@
325 pkg_vec_t *unsatisfied, char *** unresolved)
326 {
327 pkg_t * satisfier_entry_pkg;
328 - register int i, j, k;
329 + register int i, j, k, l;
330 int count, found;
331 char ** the_lost;
332 abstract_pkg_t * ab_pkg;
333 @@ -113,7 +113,6 @@
334 abstract_pkg_vec_t *ab_provider_vec = abpkg->provided_by;
335 int nposs = ab_provider_vec->len;
336 abstract_pkg_t **ab_providers = ab_provider_vec->pkgs;
337 - int l;
338 for (l = 0; l < nposs; l++) {
339 pkg_vec_t *test_vec = ab_providers[l]->pkgs;
340 /* if no depends on this one, try the first package that Provides this one */
341 @@ -137,10 +136,9 @@
342 tmp_vec,
343 &newstuff);
344 if (newstuff == NULL) {
345 - int i;
346 int ok = 1;
347 - for (i = 0; i < rc; i++) {
348 - pkg_t *p = tmp_vec->pkgs[i];
349 + for (l = 0; l < rc; l++) {
350 + pkg_t *p = tmp_vec->pkgs[l];
351 if (p->state_want == SW_INSTALL)
352 continue;
353 ipkg_message(conf, IPKG_DEBUG, "not installing %s due to requirement for %s\n", pkg_scout->name, p->name);
354 @@ -814,27 +812,27 @@
355 * [npredepends+nrecommends,npredepends+nrecommends+nsuggests) -> returns recommends_str[index]
356 * [npredepends+nrecommends+nsuggests,npredepends+nrecommends+nsuggests+ndepends) -> returns depends_str[index]
357 */
358 -char *pkg_depend_str(pkg_t *pkg, int index)
359 +char *pkg_depend_str(pkg_t *pkg, int pkg_index)
360 {
361 - if (index < pkg->pre_depends_count) {
362 - return pkg->pre_depends_str[index];
363 + if (pkg_index < pkg->pre_depends_count) {
364 + return pkg->pre_depends_str[pkg_index];
365 }
366 - index -= pkg->pre_depends_count;
367 + pkg_index -= pkg->pre_depends_count;
368
369 - if (index < pkg->recommends_count) {
370 - return pkg->recommends_str[index];
371 + if (pkg_index < pkg->recommends_count) {
372 + return pkg->recommends_str[pkg_index];
373 }
374 - index -= pkg->recommends_count;
375 + pkg_index -= pkg->recommends_count;
376
377 - if (index < pkg->suggests_count) {
378 - return pkg->suggests_str[index];
379 + if (pkg_index < pkg->suggests_count) {
380 + return pkg->suggests_str[pkg_index];
381 }
382 - index -= pkg->suggests_count;
383 + pkg_index -= pkg->suggests_count;
384
385 - if (index < pkg->depends_count) {
386 - return pkg->depends_str[index];
387 + if (pkg_index < pkg->depends_count) {
388 + return pkg->depends_str[pkg_index];
389 }
390 - fprintf(stderr, "pkg_depend_str: index %d out of range for pkg=%s\n", index, pkg->name);
391 + fprintf(stderr, "pkg_depend_str: index %d out of range for pkg=%s\n", pkg_index, pkg->name);
392 return NULL;
393 }
394
395 diff -ruN busybox-1.1.2+ipkg-0.99.162/archival/libipkg/pkg_depends.h busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/pkg_depends.h
396 --- busybox-1.1.2+ipkg-0.99.162/archival/libipkg/pkg_depends.h 2006-05-09 02:06:48.000000000 +0200
397 +++ busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/pkg_depends.h 2006-05-09 02:16:48.000000000 +0200
398 @@ -92,7 +92,7 @@
399 */
400 int pkg_conflicts(pkg_t *pkg, pkg_t *conflicts);
401
402 -char *pkg_depend_str(pkg_t *pkg, int index);
403 +char *pkg_depend_str(pkg_t *pkg, int pkg_index);
404 void buildDependedUponBy(pkg_t * pkg, abstract_pkg_t * ab_pkg);
405 void freeDepends(pkg_t *pkg);
406 void printDepends(pkg_t * pkg);
407 diff -ruN busybox-1.1.2+ipkg-0.99.162/archival/libipkg/pkg_hash.c busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/pkg_hash.c
408 --- busybox-1.1.2+ipkg-0.99.162/archival/libipkg/pkg_hash.c 2006-05-09 02:12:05.000000000 +0200
409 +++ busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/pkg_hash.c 2006-05-09 02:17:35.000000000 +0200
410 @@ -143,7 +143,7 @@
411 pkg_t *pkg_hash_fetch_best_installation_candidate(ipkg_conf_t *conf, abstract_pkg_t *apkg,
412 int (*constraint_fcn)(pkg_t *pkg, void *cdata), void *cdata, int quiet)
413 {
414 - int i;
415 + int i, j;
416 int nprovides = 0;
417 int nmatching = 0;
418 pkg_vec_t *matching_pkgs = pkg_vec_alloc();
419 @@ -209,11 +209,10 @@
420 /* now check for supported architecture */
421 {
422 int max_count = 0;
423 - int i;
424
425 /* count packages matching max arch priority and keep track of last one */
426 - for (i = 0; i < vec->len; i++) {
427 - pkg_t *maybe = vec->pkgs[i];
428 + for (j = 0; j < vec->len; j++) {
429 + pkg_t *maybe = vec->pkgs[j];
430 ipkg_message(conf, IPKG_DEBUG, " %s arch=%s arch_priority=%d version=%s \n",
431 maybe->name, maybe->architecture, maybe->arch_priority, maybe->version);
432 if (maybe->arch_priority > 0) {
433 diff -ruN busybox-1.1.2+ipkg-0.99.162/archival/libipkg/pkg_vec.h busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/pkg_vec.h
434 --- busybox-1.1.2+ipkg-0.99.162/archival/libipkg/pkg_vec.h 2006-05-09 02:06:48.000000000 +0200
435 +++ busybox-1.1.2+ipkg-0.99.162-no_warnings/archival/libipkg/pkg_vec.h 2006-05-09 02:16:48.000000000 +0200
436 @@ -35,6 +35,8 @@
437 };
438 typedef struct abstract_pkg_vec abstract_pkg_vec_t;
439
440 +typedef int (*pkg_compar_t)(pkg_t *, pkg_t *);
441 +typedef int (*abstract_pkg_compar_t)(abstract_pkg_t *, abstract_pkg_t *);
442
443 pkg_vec_t * pkg_vec_alloc(void);
444 void pkg_vec_free(pkg_vec_t *vec);