aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2012-01-14 21:44:08 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2012-01-29 11:32:12 +0000
commit938526a52dcc86ed59dc8bf6b0a67c33325e3254 (patch)
tree941620af4ca17f4e6ccc75e2cecff639a40d182d
parente821f4eb3b1a9f8f6d52b3c81ababd5aaf54963c (diff)
downloadpaludis-938526a52dcc86ed59dc8bf6b0a67c33325e3254.tar.gz
paludis-938526a52dcc86ed59dc8bf6b0a67c33325e3254.tar.xz
Make dir over symlink to dir fatal for exheres-0
-rw-r--r--paludis/repositories/e/eapi.cc11
-rw-r--r--paludis/repositories/e/eapi.hh3
-rw-r--r--paludis/repositories/e/eapis/0.conf1
-rw-r--r--paludis/repositories/e/eapis/exheres-0.conf1
-rw-r--r--paludis/repositories/e/exndbam_repository.cc6
-rw-r--r--paludis/repositories/e/vdb_repository.cc6
6 files changed, 22 insertions, 6 deletions
diff --git a/paludis/repositories/e/eapi.cc b/paludis/repositories/e/eapi.cc
index a467359..b67f7ba 100644
--- a/paludis/repositories/e/eapi.cc
+++ b/paludis/repositories/e/eapi.cc
@@ -337,6 +337,16 @@ namespace
merger_options += destringify<MergerOption>(*t);
}
+ FSMergerOptions fs_merger_options;
+ {
+ std::list<std::string> fs_merger_options_tokens;
+ tokenise_whitespace(check_get(k, "fs_merger_options"), std::back_inserter(fs_merger_options_tokens));
+ for (std::list<std::string>::const_iterator t(fs_merger_options_tokens.begin()),
+ t_end(fs_merger_options_tokens.end()) ;
+ t != t_end ; ++t)
+ fs_merger_options += destringify<FSMergerOption>(*t);
+ }
+
return std::make_shared<SupportedEAPI>(make_named_values<SupportedEAPI>(
n::allow_tokens_in_mask_files() = destringify_key<bool>(k, "allow_tokens_in_mask_files"),
n::annotations() = make_annotations(k),
@@ -349,6 +359,7 @@ namespace
n::ebuild_metadata_variables() = make_ebuild_metadata_variables(k),
n::ebuild_options() = make_ebuild_options(k),
n::ebuild_phases() = make_ebuild_phases(k),
+ n::fs_merger_options() = fs_merger_options,
n::is_pbin() = destringify_key<bool>(k, "is_pbin"),
n::iuse_flag_parse_options() = iuse_flag_parse_options,
n::merger_options() = merger_options,
diff --git a/paludis/repositories/e/eapi.hh b/paludis/repositories/e/eapi.hh
index 4159b8d..996e75b 100644
--- a/paludis/repositories/e/eapi.hh
+++ b/paludis/repositories/e/eapi.hh
@@ -31,6 +31,7 @@
#include <paludis/name.hh>
#include <paludis/dep_spec-fwd.hh>
#include <paludis/merger-fwd.hh>
+#include <paludis/fs_merger-fwd.hh>
#include <memory>
namespace paludis
@@ -126,6 +127,7 @@ namespace paludis
typedef Name<struct name_flat_list_index> flat_list_index;
typedef Name<struct name_fs_location_description> fs_location_description;
typedef Name<struct name_fs_location_name> fs_location_name;
+ typedef Name<struct name_fs_merger_options> fs_merger_options;
typedef Name<struct name_general_author> general_author;
typedef Name<struct name_general_date> general_date;
typedef Name<struct name_general_description> general_description;
@@ -298,6 +300,7 @@ namespace paludis
NamedValue<n::ebuild_metadata_variables, std::shared_ptr<const EAPIEbuildMetadataVariables> > ebuild_metadata_variables;
NamedValue<n::ebuild_options, std::shared_ptr<const EAPIEbuildOptions> > ebuild_options;
NamedValue<n::ebuild_phases, std::shared_ptr<const EAPIEbuildPhases> > ebuild_phases;
+ NamedValue<n::fs_merger_options, FSMergerOptions> fs_merger_options;
NamedValue<n::is_pbin, bool> is_pbin;
NamedValue<n::iuse_flag_parse_options, IUseFlagParseOptions> iuse_flag_parse_options;
NamedValue<n::merger_options, MergerOptions> merger_options;
diff --git a/paludis/repositories/e/eapis/0.conf b/paludis/repositories/e/eapis/0.conf
index 427d174..1c6d319 100644
--- a/paludis/repositories/e/eapis/0.conf
+++ b/paludis/repositories/e/eapis/0.conf
@@ -10,6 +10,7 @@ dependency_spec_tree_parse_options =
iuse_flag_parse_options =
version_spec_options =
merger_options = rewrite_symlinks allow_empty_dirs
+fs_merger_options =
breaks_portage = false
rdepend_defaults_to_depend = true
use_expand_separator = _
diff --git a/paludis/repositories/e/eapis/exheres-0.conf b/paludis/repositories/e/eapis/exheres-0.conf
index 6d678f6..7b03a83 100644
--- a/paludis/repositories/e/eapis/exheres-0.conf
+++ b/paludis/repositories/e/eapis/exheres-0.conf
@@ -16,6 +16,7 @@ iuse_flag_parse_options = strict_parsing
version_spec_options = flexible_dashes flexible_dots ignore_case \
letters_anywhere dotted_suffixes
merger_options = preserve_mtimes
+fs_merger_options = dir_over_sym_dir_is_error
breaks_portage = true
want_portage_emulation_vars = false
require_use_expand_in_iuse = true
diff --git a/paludis/repositories/e/exndbam_repository.cc b/paludis/repositories/e/exndbam_repository.cc
index d06deea..4b249a7 100644
--- a/paludis/repositories/e/exndbam_repository.cc
+++ b/paludis/repositories/e/exndbam_repository.cc
@@ -428,8 +428,8 @@ ExndbamRepository::merge(const MergeParams & m)
}
}
- bool fix_mtimes(std::static_pointer_cast<const ERepositoryID>(
- m.package_id())->eapi()->supported()->ebuild_options()->fix_mtimes());
+ auto eapi(std::static_pointer_cast<const ERepositoryID>(m.package_id())->eapi()->supported());
+ auto fix_mtimes(eapi->ebuild_options()->fix_mtimes());
NDBAMMerger merger(
make_named_values<NDBAMMergerParams>(
@@ -438,7 +438,7 @@ ExndbamRepository::merge(const MergeParams & m)
n::contents_file() = target_ver_dir / "contents",
n::environment() = _imp->params.environment(),
n::fix_mtimes_before() = fix_mtimes ? m.build_start_time() : Timestamp(0, 0),
- n::fs_merger_options() = FSMergerOptions(),
+ n::fs_merger_options() = eapi->fs_merger_options(),
n::get_new_ids_or_minus_one() = std::bind(&get_new_ids_or_minus_one, _imp->params.environment(), std::placeholders::_1),
n::image() = m.image_dir(),
n::install_under() = FSPath("/"),
diff --git a/paludis/repositories/e/vdb_repository.cc b/paludis/repositories/e/vdb_repository.cc
index 3bc800f..21c3838 100644
--- a/paludis/repositories/e/vdb_repository.cc
+++ b/paludis/repositories/e/vdb_repository.cc
@@ -658,8 +658,8 @@ VDBRepository::merge(const MergeParams & m)
vdb_dir /= stringify(m.package_id()->name().category());
vdb_dir /= (stringify(m.package_id()->name().package()) + "-" + stringify(m.package_id()->version()));
- bool fix_mtimes(std::static_pointer_cast<const ERepositoryID>(
- m.package_id())->eapi()->supported()->ebuild_options()->fix_mtimes());
+ auto eapi(std::static_pointer_cast<const ERepositoryID>(m.package_id())->eapi()->supported());
+ auto fix_mtimes(eapi->ebuild_options()->fix_mtimes());
VDBMerger merger(
make_named_values<VDBMergerParams>(
@@ -668,7 +668,7 @@ VDBRepository::merge(const MergeParams & m)
n::contents_file() = vdb_dir / "CONTENTS",
n::environment() = _imp->params.environment(),
n::fix_mtimes_before() = fix_mtimes ? m.build_start_time() : Timestamp(0, 0),
- n::fs_merger_options() = FSMergerOptions(),
+ n::fs_merger_options() = eapi->fs_merger_options(),
n::image() = m.image_dir(),
n::merged_entries() = m.merged_entries(),
n::options() = m.options(),