diff options
-rw-r--r-- | paludis/repositories/e/exndbam_repository.cc | 14 | ||||
-rw-r--r-- | paludis/repositories/e/vdb_repository.cc | 14 |
2 files changed, 28 insertions, 0 deletions
diff --git a/paludis/repositories/e/exndbam_repository.cc b/paludis/repositories/e/exndbam_repository.cc index 71a9624ac..c4e816015 100644 --- a/paludis/repositories/e/exndbam_repository.cc +++ b/paludis/repositories/e/exndbam_repository.cc @@ -413,6 +413,20 @@ ExndbamRepository::merge(const MergeParams & m) { } } + else + { + /* nasty: make CONFIG_PROTECT etc available for hooks */ + try + { + config_protect = snoop_variable_from_environment_file(m.environment_file(), "CONFIG_PROTECT"); + config_protect_mask = snoop_variable_from_environment_file(m.environment_file(), "CONFIG_PROTECT_MASK"); + } + catch (const Exception & e) + { + Log::get_instance()->message("e.exndbam_repository.config_protect_unfetchable", ll_warning, lc_context) + << "Could not load CONFIG_PROTECT for merge checks due to exception '" + e.message() + "' (" + e.what() + ")"; + } + } bool fix_mtimes(std::static_pointer_cast<const ERepositoryID>( m.package_id())->eapi()->supported()->ebuild_options()->fix_mtimes()); diff --git a/paludis/repositories/e/vdb_repository.cc b/paludis/repositories/e/vdb_repository.cc index 373b7dd6c..00f734a4a 100644 --- a/paludis/repositories/e/vdb_repository.cc +++ b/paludis/repositories/e/vdb_repository.cc @@ -638,6 +638,20 @@ VDBRepository::merge(const MergeParams & m) { } } + else + { + /* nasty: make CONFIG_PROTECT etc available for hooks */ + try + { + config_protect = snoop_variable_from_environment_file(m.environment_file(), "CONFIG_PROTECT"); + config_protect_mask = snoop_variable_from_environment_file(m.environment_file(), "CONFIG_PROTECT_MASK"); + } + catch (const Exception & e) + { + Log::get_instance()->message("e.exndbam_repository.config_protect_unfetchable", ll_warning, lc_context) + << "Could not load CONFIG_PROTECT for merge checks due to exception '" + e.message() + "' (" + e.what() + ")"; + } + } FSPath vdb_dir(_imp->params.location()); vdb_dir /= stringify(m.package_id()->name().category()); |