xbps-rindex: remove -c --clean mode and adapt to the new libxbps API.

- Removed -c --clean mode. It's not too useful and adds a considerable
  amount of gratuitous code. It takes almost the same time than
  adding all pkgs from scratch.

- When creating the repository data always add the meta plist at the
  2nd position in the archive, to optimize its access.

- Misc improvements.
This commit is contained in:
Juan RP
2013-10-07 10:23:14 +02:00
parent 1f270e3a1a
commit f3b0b19258
9 changed files with 124 additions and 312 deletions

View File

@@ -119,10 +119,6 @@ remove_obsoletes(struct xbps_handle *xhp, const char *repodir)
}
return 0;
}
if ((repo->idx = xbps_repo_get_plist(repo, XBPS_REPOIDX)) == NULL) {
xbps_repo_close(repo);
return -1;
}
if (chdir(repodir) == -1) {
fprintf(stderr, "xbps-rindex: cannot chdir to %s: %s\n",
repodir, strerror(errno));