package_manager.py: Add a name for the generated dnf repo.

This adds repo_name as the name, which is the same as the
repo ID and hence a bit pointless, but it stops dnf from
complaining that the repo doesn't have a configured name.

(From OE-Core rev: c92cff23893e87cfb7ef9f77b16761310104543a)

Signed-off-by: Ian.Arkver <ian.arkver.dev@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Ian.Arkver 2017-04-11 14:25:39 +01:00 committed by Richard Purdie
parent 620655697d
commit f2e41a197f
1 changed files with 1 additions and 1 deletions

View File

@ -555,7 +555,7 @@ class RpmPM(PackageManager):
repo_uris = [uri + "/" + arch for arch in feed_archs.split()]
else:
repo_uris = [uri]
open(oe.path.join(self.target_rootfs, "etc", "yum.repos.d", repo_name + ".repo"), 'w').write("[%s]\nbaseurl=%s\n" % (repo_name, " ".join(repo_uris)))
open(oe.path.join(self.target_rootfs, "etc", "yum.repos.d", repo_name + ".repo"), 'w').write("[%s]\nname=%s\nbaseurl=%s\n" % (repo_name, repo_name, " ".join(repo_uris)))
def _prepare_pkg_transaction(self):
os.environ['D'] = self.target_rootfs