From: Michael Schroeder Date: Mon, 18 Jan 2010 14:04:14 +0000 (+0100) Subject: - set repository:toolversion to 1.0 in common_write X-Git-Tag: BASE-SuSE-Code-12_1-Branch~161^2~2 X-Git-Url: http://git.ipfire.org/gitweb/?a=commitdiff_plain;h=5d0a993646ad70ecc97610f9b9227c75e2b99516;p=thirdparty%2Flibsolv.git - set repository:toolversion to 1.0 in common_write --- diff --git a/VERSION.cmake b/VERSION.cmake index 87399945..5854b26b 100644 --- a/VERSION.cmake +++ b/VERSION.cmake @@ -46,6 +46,6 @@ SET(LIBSATSOLVER_MAJOR "0") SET(LIBSATSOLVER_MINOR "14") -SET(LIBSATSOLVER_PATCH "12") +SET(LIBSATSOLVER_PATCH "13") -# last released 0.14.12 +# last released 0.14.13 diff --git a/ext/repo_write.c b/ext/repo_write.c index 4fc4f493..68c022c8 100644 --- a/ext/repo_write.c +++ b/ext/repo_write.c @@ -644,7 +644,7 @@ repo_write_collect_needed(struct cbdata *cbdata, Repo *repo, Repodata *data, Rep if (key->name == REPOSITORY_SOLVABLES) return SEARCH_NEXT_KEY; /* we do not want this one */ if (data != data->repo->repodata + data->repo->nrepodata - 1) - if (key->name == REPOSITORY_ADDEDFILEPROVIDES || key->name == REPOSITORY_EXTERNAL || key->name == REPOSITORY_LOCATION || key->name == REPOSITORY_KEYS) + if (key->name == REPOSITORY_ADDEDFILEPROVIDES || key->name == REPOSITORY_EXTERNAL || key->name == REPOSITORY_LOCATION || key->name == REPOSITORY_KEYS || key->name == REPOSITORY_TOOLVERSION) return SEARCH_NEXT_KEY; rm = cbdata->keymap[cbdata->keymapstart[data - data->repo->repodata] + (key - data->keys)]; @@ -754,7 +754,7 @@ repo_write_adddata(struct cbdata *cbdata, Repodata *data, Repokey *key, KeyValue if (key->name == REPOSITORY_SOLVABLES) return SEARCH_NEXT_KEY; if (data != data->repo->repodata + data->repo->nrepodata - 1) - if (key->name == REPOSITORY_ADDEDFILEPROVIDES || key->name == REPOSITORY_EXTERNAL || key->name == REPOSITORY_LOCATION || key->name == REPOSITORY_KEYS) + if (key->name == REPOSITORY_ADDEDFILEPROVIDES || key->name == REPOSITORY_EXTERNAL || key->name == REPOSITORY_LOCATION || key->name == REPOSITORY_KEYS || key->name == REPOSITORY_TOOLVERSION) return SEARCH_NEXT_KEY; rm = cbdata->keymap[cbdata->keymapstart[data - data->repo->repodata] + (key - data->keys)]; diff --git a/package/libsatsolver.changes b/package/libsatsolver.changes index 86af4c42..7feb4d88 100644 --- a/package/libsatsolver.changes +++ b/package/libsatsolver.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Mon Jan 18 14:42:27 CET 2010 - mls@suse.de + +- set repository:toolversion to 1.0 in common_write +- 0.14.13 + ------------------------------------------------------------------- Mon Dec 21 14:29:24 CET 2009 - mls@suse.de diff --git a/src/knownid.h b/src/knownid.h index 0db9a912..a84c893e 100644 --- a/src/knownid.h +++ b/src/knownid.h @@ -233,6 +233,8 @@ KNOWNID(PUBKEY_FINGERPRINT, "pubkey:fingerprint"), KNOWNID(PUBKEY_EXPIRES, "pubkey:expires"), KNOWNID(PUBKEY_SIGNATURES, "pubkey:signatures"), +KNOWNID(REPOSITORY_TOOLVERSION, "repository:toolversion"), + KNOWNID(ID_NUM_INTERNAL, 0) #ifdef KNOWNID_INITIALIZE diff --git a/tools/common_write.c b/tools/common_write.c index 73067bdb..00e1c116 100644 --- a/tools/common_write.c +++ b/tools/common_write.c @@ -17,6 +17,8 @@ #include "repo_write.h" #include "common_write.h" +#define SATSOLVER_TOOLVERSION "1.0" + static Id verticals[] = { SOLVABLE_AUTHORS, SOLVABLE_DESCRIPTION, @@ -76,8 +78,8 @@ keyfilter_attr(Repo *data, Repokey *key, void *kfdata) const char *keyname; if (key->storage == KEY_STORAGE_SOLVABLE) return KEY_STORAGE_DROPPED; - /* those two must only be in the main solv file */ - if (key->name == REPOSITORY_EXTERNAL || key->name == REPOSITORY_ADDEDFILEPROVIDES) + /* those must only be in the main solv file */ + if (key->name == REPOSITORY_EXTERNAL || key->name == REPOSITORY_ADDEDFILEPROVIDES || key->name == REPOSITORY_TOOLVERSION) return KEY_STORAGE_DROPPED; for (i = 0; verticals[i]; i++) if (key->name == verticals[i]) @@ -203,6 +205,7 @@ tool_write(Repo *repo, const char *basename, const char *attrname) memset(&kd, 0, sizeof(kd)); info = repo_add_repodata(repo, 0); + repodata_set_str(info, SOLVID_META, REPOSITORY_TOOLVERSION, SATSOLVER_TOOLVERSION); pool_addfileprovides_ids(repo->pool, 0, &addedfileprovides); if (addedfileprovides && *addedfileprovides) {