aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2006-06-11 15:49:06 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2006-06-11 15:49:06 +0000
commit6169ea393b161e69f184e19dd8aeed54b10cf1c0 (patch)
tree0c38f204f023d15a9e7c1720c06c4220338bca8c
parentdb2031e30ae841d229ed510edc7b53584be4f829 (diff)
downloadpaludis-6169ea393b161e69f184e19dd8aeed54b10cf1c0.tar.gz
paludis-6169ea393b161e69f184e19dd8aeed54b10cf1c0.tar.xz
Show the location of the repository config file rather than the repository in eclassdir / profiledir deprecated notices
-rw-r--r--paludis/portage_repository.cc10
1 files changed, 6 insertions, 4 deletions
diff --git a/paludis/portage_repository.cc b/paludis/portage_repository.cc
index b7323a7..5b3b79a 100644
--- a/paludis/portage_repository.cc
+++ b/paludis/portage_repository.cc
@@ -1171,8 +1171,10 @@ PortageRepository::make_portage_repository(
const PackageDatabase * const db,
const std::map<std::string, std::string> & m)
{
- Context context("When making Portage repository from repo_file '" +
- (m.end() == m.find("repo_file") ? std::string("?") : m.find("repo_file")->second) + "':");
+ std::string repo_file(m.end() == m.find("repo_file") ? std::string("?") :
+ m.find("repo_file")->second);
+
+ Context context("When making Portage repository from repo_file '" + repo_file + "':");
std::string location;
if (m.end() == m.find("location") || ((location = m.find("location")->second)).empty())
@@ -1184,7 +1186,7 @@ PortageRepository::make_portage_repository(
create_inserter<FSEntry>(std::back_inserter(*profiles)));
if (m.end() != m.find("profile") && ! m.find("profile")->second.empty())
{
- Log::get_instance()->message(ll_warning, "Key 'profile' in '" + location + "' is deprecated, "
+ Log::get_instance()->message(ll_warning, "Key 'profile' in '" + repo_file + "' is deprecated, "
"use 'profiles = " + m.find("profile")->second + "' instead");
if (profiles->empty())
profiles->append(m.find("profile")->second);
@@ -1200,7 +1202,7 @@ PortageRepository::make_portage_repository(
create_inserter<FSEntry>(std::back_inserter(*eclassdirs)));
if (m.end() != m.find("eclassdir") && ! m.find("eclassdir")->second.empty())
{
- Log::get_instance()->message(ll_warning, "Key 'eclassdir' in '" + location + "' is deprecated, "
+ Log::get_instance()->message(ll_warning, "Key 'eclassdir' in '" + repo_file + "' is deprecated, "
"use 'eclassdirs = " + m.find("eclassdir")->second + "' instead");
if (eclassdirs->empty())
eclassdirs->append(m.find("eclassdir")->second);