1
0
mirror of https://github.com/openSUSE/libsolv.git synced 2026-02-05 12:45:46 +01:00

Replace 'redhat-release' with generic 'system-release'

fedora-release and mageia-release offer generic 'system-release'
Provides that can be used to determine the release version of the
distribution. Derivatives of Fedora (including RHEL) also offer this
generic capability in their distribution release packages.
This commit is contained in:
Neal Gompa
2017-08-06 00:06:56 -04:00
parent de2991f836
commit f96788c665

View File

@@ -48,7 +48,7 @@ yum_substitute(Pool *pool, char *line)
queue_init(&q);
rpmstate = rpm_state_create(pool, pool_get_rootdir(pool));
rpm_installedrpmdbids(rpmstate, "Providename", "redhat-release", &q);
rpm_installedrpmdbids(rpmstate, "Providename", "system-release", &q);
if (q.count)
{
void *handle;
@@ -62,7 +62,7 @@ yum_substitute(Pool *pool, char *line)
queue_free(&q);
if (!releaseevr)
{
fprintf(stderr, "no installed package provides 'redhat-release', cannot determine $releasever\n");
fprintf(stderr, "no installed package provides 'system-release', cannot determine $releasever\n");
exit(1);
}
}