build/interdep.c: upgrade "dependency needs Epoch" warning to error
This commit is contained in:
parent
df6da6843a
commit
2f8008125d
@ -63,7 +63,7 @@ void addRequires(struct Req *r, Package pkg1, Package pkg2)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static
|
static
|
||||||
void makeReq1(struct Req *r, Package pkg1, Package pkg2, int warn)
|
void makeReq1(struct Req *r, Package pkg1, Package pkg2, int warn, int *errors)
|
||||||
{
|
{
|
||||||
int c = 0;
|
int c = 0;
|
||||||
const char **reqNv = NULL;
|
const char **reqNv = NULL;
|
||||||
@ -99,9 +99,11 @@ void makeReq1(struct Req *r, Package pkg1, Package pkg2, int warn)
|
|||||||
if (strcmp(reqR, provR))
|
if (strcmp(reqR, provR))
|
||||||
continue;
|
continue;
|
||||||
addRequires(r, pkg1, pkg2);
|
addRequires(r, pkg1, pkg2);
|
||||||
if (warn && colon == NULL && headerIsEntry(pkg2->header, RPMTAG_EPOCH))
|
if (warn && colon == NULL && headerIsEntry(pkg2->header, RPMTAG_EPOCH)) {
|
||||||
fprintf(stderr, "warning: %s: dependency on %s needs Epoch\n",
|
fprintf(stderr, "error: %s: dependency on %s needs Epoch\n",
|
||||||
pkgName(pkg1), pkgName(pkg2));
|
pkgName(pkg1), pkgName(pkg2));
|
||||||
|
*errors = 1;
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
const HFD_t hfd = (HFD_t) headerFreeData;
|
const HFD_t hfd = (HFD_t) headerFreeData;
|
||||||
@ -191,8 +193,8 @@ struct Req *makeRequires(Spec spec, int warn, int *errors)
|
|||||||
Package pkg1, pkg2;
|
Package pkg1, pkg2;
|
||||||
for (pkg1 = spec->packages; pkg1; pkg1 = pkg1->next)
|
for (pkg1 = spec->packages; pkg1; pkg1 = pkg1->next)
|
||||||
for (pkg2 = pkg1->next; pkg2; pkg2 = pkg2->next) {
|
for (pkg2 = pkg1->next; pkg2; pkg2 = pkg2->next) {
|
||||||
makeReq1(r, pkg1, pkg2, warn & 1);
|
makeReq1(r, pkg1, pkg2, warn & 1, errors);
|
||||||
makeReq1(r, pkg2, pkg1, warn & 1);
|
makeReq1(r, pkg2, pkg1, warn & 1, errors);
|
||||||
}
|
}
|
||||||
int propagated;
|
int propagated;
|
||||||
do {
|
do {
|
||||||
@ -221,7 +223,6 @@ struct Req *makeRequires(Spec spec, int warn, int *errors)
|
|||||||
return r;
|
return r;
|
||||||
|
|
||||||
const char *allowed = rpmExpand("%{?_allowed_nonstrict_interdeps}", NULL);
|
const char *allowed = rpmExpand("%{?_allowed_nonstrict_interdeps}", NULL);
|
||||||
*errors = 0;
|
|
||||||
for (pkg1 = spec->packages; pkg1; pkg1 = pkg1->next)
|
for (pkg1 = spec->packages; pkg1; pkg1 = pkg1->next)
|
||||||
for (pkg2 = pkg1->next; pkg2; pkg2 = pkg2->next) {
|
for (pkg2 = pkg1->next; pkg2; pkg2 = pkg2->next) {
|
||||||
if (!Requires(r, pkg1, pkg2) && depRequires(pkg1, pkg2))
|
if (!Requires(r, pkg1, pkg2) && depRequires(pkg1, pkg2))
|
||||||
@ -712,7 +713,7 @@ void pruneExtraRDeps(struct Req *r, Spec spec)
|
|||||||
|
|
||||||
int processInterdep(Spec spec)
|
int processInterdep(Spec spec)
|
||||||
{
|
{
|
||||||
int errors;
|
int errors = 0;
|
||||||
struct Req *r = makeRequires(spec, 1, &errors);
|
struct Req *r = makeRequires(spec, 1, &errors);
|
||||||
pruneDebuginfoSrc(r, spec);
|
pruneDebuginfoSrc(r, spec);
|
||||||
liftDebuginfoDeps(r, spec);
|
liftDebuginfoDeps(r, spec);
|
||||||
|
Loading…
Reference in New Issue
Block a user