aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2008-04-26 13:59:04 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2008-04-26 13:59:04 +0000
commit118de550d2dc5508ff4446bdf7f2ddf7b497b9ba (patch)
tree5ced2de062474cb8e6537e68d71cbc7c5a80e802
parentf76a3a0a7b38b5a3652a9e9bcb13942483f7c53a (diff)
downloadpaludis-118de550d2dc5508ff4446bdf7f2ddf7b497b9ba.tar.gz
paludis-118de550d2dc5508ff4446bdf7f2ddf7b497b9ba.tar.xz
paludis::tr1:: is dead. We no longer support compilers that don't do tr1 (that means you, gcc-3).
-rw-r--r--NEWS4
-rw-r--r--configure.ac120
-rw-r--r--doc/api/cplusplus/examples/example_action.cc4
-rw-r--r--doc/api/cplusplus/examples/example_contents.cc6
-rw-r--r--doc/api/cplusplus/examples/example_dep_label.cc4
-rw-r--r--doc/api/cplusplus/examples/example_dep_spec.cc4
-rw-r--r--doc/api/cplusplus/examples/example_dep_spec_flattener.cc6
-rw-r--r--doc/api/cplusplus/examples/example_dep_tag.cc8
-rw-r--r--doc/api/cplusplus/examples/example_dep_tree.cc22
-rw-r--r--doc/api/cplusplus/examples/example_environment.cc6
-rw-r--r--doc/api/cplusplus/examples/example_formatter.cc4
-rw-r--r--doc/api/cplusplus/examples/example_mask.cc4
-rw-r--r--doc/api/cplusplus/examples/example_match_package.cc6
-rw-r--r--doc/api/cplusplus/examples/example_metadata_key.cc22
-rw-r--r--doc/api/cplusplus/examples/example_package_database.cc4
-rw-r--r--doc/api/cplusplus/examples/example_package_id.cc4
-rw-r--r--doc/api/cplusplus/examples/example_query.cc6
-rw-r--r--doc/api/cplusplus/examples/example_query_delegate.cc20
-rw-r--r--doc/api/cplusplus/examples/example_repository.cc6
-rw-r--r--doc/api/cplusplus/examples/example_stringify_formatter.cc4
-rw-r--r--doc/api/cplusplus/examples/example_version_spec.cc2
-rw-r--r--doc/configuration/hooks.html.part2
-rwxr-xr-xmisc/make_sr.bash6
-rw-r--r--paludis/action-fwd.hh4
-rw-r--r--paludis/action.cc4
-rw-r--r--paludis/action.hh6
-rw-r--r--paludis/args/dep_list_args_group.cc16
-rw-r--r--paludis/args/install_args_group.cc6
-rw-r--r--paludis/args/install_args_group.hh4
-rw-r--r--paludis/args/man.cc6
-rw-r--r--paludis/condition_tracker.cc34
-rw-r--r--paludis/condition_tracker.hh22
-rw-r--r--paludis/contents.cc8
-rw-r--r--paludis/contents.hh8
-rw-r--r--paludis/dep_label-fwd.hh14
-rw-r--r--paludis/dep_label.cc40
-rw-r--r--paludis/dep_label.hh10
-rw-r--r--paludis/dep_list-fwd.hh1
-rw-r--r--paludis/dep_list.cc163
-rw-r--r--paludis/dep_list.hh51
-rw-r--r--paludis/dep_list.sr10
-rw-r--r--paludis/dep_list_TEST.cc106
-rw-r--r--paludis/dep_list_TEST.hh8
-rw-r--r--paludis/dep_list_TEST_blockers.cc20
-rw-r--r--paludis/dep_list_exceptions.cc4
-rw-r--r--paludis/dep_list_exceptions.hh2
-rw-r--r--paludis/dep_spec-fwd.hh4
-rw-r--r--paludis/dep_spec.cc136
-rw-r--r--paludis/dep_spec.hh77
-rw-r--r--paludis/dep_spec_TEST.cc8
-rw-r--r--paludis/dep_spec_flattener.cc6
-rw-r--r--paludis/dep_spec_flattener.hh4
-rw-r--r--paludis/dep_tag.cc42
-rw-r--r--paludis/dep_tag.hh16
-rw-r--r--paludis/dep_tag.sr2
-rw-r--r--paludis/distribution.cc11
-rw-r--r--paludis/distribution.hh4
-rw-r--r--paludis/environment.hh28
-rw-r--r--paludis/environment_implementation.cc30
-rw-r--r--paludis/environment_implementation.hh16
-rw-r--r--paludis/environment_maker.cc4
-rw-r--r--paludis/environment_maker.hh6
-rw-r--r--paludis/environments/adapted/adapted_environment.cc41
-rw-r--r--paludis/environments/adapted/adapted_environment.hh32
-rw-r--r--paludis/environments/adapted/adapted_environment_TEST.cc4
-rw-r--r--paludis/environments/no_config/no_config_environment.cc52
-rw-r--r--paludis/environments/no_config/no_config_environment.hh28
-rw-r--r--paludis/environments/no_config/no_config_environment.sr2
-rw-r--r--paludis/environments/no_config/no_config_environment_TEST.cc4
-rw-r--r--paludis/environments/paludis/bashable_conf.cc4
-rw-r--r--paludis/environments/paludis/bashable_conf.hh11
-rw-r--r--paludis/environments/paludis/keywords_conf.cc21
-rw-r--r--paludis/environments/paludis/keywords_conf.hh4
-rw-r--r--paludis/environments/paludis/licenses_conf.cc19
-rw-r--r--paludis/environments/paludis/mirrors_conf.cc17
-rw-r--r--paludis/environments/paludis/mirrors_conf.hh4
-rw-r--r--paludis/environments/paludis/package_mask_conf.cc20
-rw-r--r--paludis/environments/paludis/paludis_config.cc88
-rw-r--r--paludis/environments/paludis/paludis_config.hh16
-rw-r--r--paludis/environments/paludis/paludis_environment.cc76
-rw-r--r--paludis/environments/paludis/paludis_environment.hh28
-rw-r--r--paludis/environments/paludis/paludis_environment_TEST.cc26
-rw-r--r--paludis/environments/paludis/registration.cc6
-rw-r--r--paludis/environments/paludis/repository_config_entry.sr2
-rw-r--r--paludis/environments/paludis/use_conf.cc27
-rw-r--r--paludis/environments/paludis/use_conf.hh4
-rw-r--r--paludis/environments/paludis/use_config_entry.sr22
-rw-r--r--paludis/environments/paludis/world.cc32
-rw-r--r--paludis/environments/paludis/world.hh6
-rw-r--r--paludis/environments/portage/portage_environment.cc106
-rw-r--r--paludis/environments/portage/portage_environment.hh22
-rw-r--r--paludis/environments/portage/portage_environment_TEST.cc20
-rw-r--r--paludis/environments/portage/registration.cc6
-rw-r--r--paludis/environments/test/test_environment.cc40
-rw-r--r--paludis/environments/test/test_environment.hh22
-rw-r--r--paludis/files.m41
-rw-r--r--paludis/find_unused_packages_task.cc8
-rw-r--r--paludis/find_unused_packages_task.hh2
-rw-r--r--paludis/formatter.hh8
-rw-r--r--paludis/fuzzy_finder.cc22
-rw-r--r--paludis/fuzzy_finder_TEST.cc14
-rw-r--r--paludis/handled_information.cc10
-rw-r--r--paludis/handled_information.hh6
-rw-r--r--paludis/hashed_containers.cc128
-rw-r--r--paludis/hashed_containers.hh423
-rw-r--r--paludis/hashed_containers_TEST.cc63
-rw-r--r--paludis/hook.hh5
-rw-r--r--paludis/hooker.cc57
-rw-r--r--paludis/hooker.hh6
-rw-r--r--paludis/install_task.cc111
-rw-r--r--paludis/install_task.hh20
-rw-r--r--paludis/literal_metadata_key.cc34
-rw-r--r--paludis/literal_metadata_key.hh12
-rw-r--r--paludis/mask-fwd.hh4
-rw-r--r--paludis/mask.hh6
-rw-r--r--paludis/match_package.cc6
-rw-r--r--paludis/match_package.hh4
-rw-r--r--paludis/merger.cc206
-rw-r--r--paludis/merger.hh9
-rw-r--r--paludis/merger_TEST.cc2
-rw-r--r--paludis/metadata_key.cc10
-rw-r--r--paludis/metadata_key.hh28
-rw-r--r--paludis/metadata_key_holder.cc16
-rw-r--r--paludis/metadata_key_holder.hh6
-rw-r--r--paludis/name.cc7
-rw-r--r--paludis/name.sr4
-rw-r--r--paludis/ndbam-fwd.hh6
-rw-r--r--paludis/ndbam.cc47
-rw-r--r--paludis/ndbam.hh18
-rw-r--r--paludis/ndbam_merger.cc7
-rw-r--r--paludis/ndbam_merger.hh4
-rw-r--r--paludis/ndbam_unmerger.cc27
-rw-r--r--paludis/ndbam_unmerger.hh10
-rw-r--r--paludis/override_functions.cc6
-rw-r--r--paludis/package_database.cc95
-rw-r--r--paludis/package_database.hh14
-rw-r--r--paludis/package_database_TEST.cc64
-rw-r--r--paludis/package_id-fwd.hh8
-rw-r--r--paludis/package_id.cc60
-rw-r--r--paludis/package_id.hh61
-rw-r--r--paludis/python_hooks.cc8
-rw-r--r--paludis/qa.cc20
-rw-r--r--paludis/qa.sr14
-rw-r--r--paludis/query.cc160
-rw-r--r--paludis/query.hh24
-rw-r--r--paludis/query_delegate.cc28
-rw-r--r--paludis/query_delegate.hh20
-rw-r--r--paludis/query_visitor.cc22
-rw-r--r--paludis/query_visitor.hh4
-rw-r--r--paludis/range_rewriter.cc40
-rw-r--r--paludis/range_rewriter.hh2
-rw-r--r--paludis/range_rewriter_TEST.cc8
-rw-r--r--paludis/report_task.cc30
-rw-r--r--paludis/report_task.hh20
-rw-r--r--paludis/repositories/cran/cran_dep_parser.cc10
-rw-r--r--paludis/repositories/cran/cran_dep_parser.hh4
-rw-r--r--paludis/repositories/cran/cran_installed_repository.cc71
-rw-r--r--paludis/repositories/cran/cran_installed_repository.hh18
-rw-r--r--paludis/repositories/cran/cran_installed_repository_TEST.cc6
-rw-r--r--paludis/repositories/cran/cran_package_id.cc121
-rw-r--r--paludis/repositories/cran/cran_package_id.hh50
-rw-r--r--paludis/repositories/cran/cran_repository.cc78
-rw-r--r--paludis/repositories/cran/cran_repository.hh22
-rw-r--r--paludis/repositories/cran/cran_repository_TEST.cc10
-rw-r--r--paludis/repositories/cran/keys.cc28
-rw-r--r--paludis/repositories/cran/keys.hh16
-rw-r--r--paludis/repositories/cran/package_dep_spec.cc30
-rw-r--r--paludis/repositories/e/aa_visitor_TEST.cc4
-rw-r--r--paludis/repositories/e/check_fetched_files_visitor.cc12
-rw-r--r--paludis/repositories/e/check_fetched_files_visitor.hh6
-rw-r--r--paludis/repositories/e/conditional_dep_spec.cc6
-rw-r--r--paludis/repositories/e/conditional_dep_spec.hh2
-rw-r--r--paludis/repositories/e/dep_parser.cc164
-rw-r--r--paludis/repositories/e/dep_parser.hh28
-rw-r--r--paludis/repositories/e/dep_parser_TEST.cc98
-rw-r--r--paludis/repositories/e/dep_spec_pretty_printer.cc6
-rw-r--r--paludis/repositories/e/dep_spec_pretty_printer.hh2
-rw-r--r--paludis/repositories/e/dep_spec_pretty_printer_TEST.cc30
-rw-r--r--paludis/repositories/e/dependencies_rewriter.cc10
-rw-r--r--paludis/repositories/e/e_installed_repository.cc70
-rw-r--r--paludis/repositories/e/e_installed_repository.hh22
-rw-r--r--paludis/repositories/e/e_installed_repository_id.cc154
-rw-r--r--paludis/repositories/e/e_installed_repository_id.hh66
-rw-r--r--paludis/repositories/e/e_key.cc186
-rw-r--r--paludis/repositories/e/e_key.hh68
-rw-r--r--paludis/repositories/e/e_mask.cc18
-rw-r--r--paludis/repositories/e/e_mask.hh10
-rw-r--r--paludis/repositories/e/e_repository.cc211
-rw-r--r--paludis/repositories/e/e_repository.hh42
-rw-r--r--paludis/repositories/e/e_repository_TEST.cc285
-rw-r--r--paludis/repositories/e/e_repository_entries.cc2
-rw-r--r--paludis/repositories/e/e_repository_entries.hh30
-rw-r--r--paludis/repositories/e/e_repository_id.cc4
-rw-r--r--paludis/repositories/e/e_repository_id.hh14
-rw-r--r--paludis/repositories/e/e_repository_mask_file.cc10
-rw-r--r--paludis/repositories/e/e_repository_mask_file.hh2
-rw-r--r--paludis/repositories/e/e_repository_news.cc4
-rw-r--r--paludis/repositories/e/e_repository_params.sr6
-rw-r--r--paludis/repositories/e/e_repository_profile.cc57
-rw-r--r--paludis/repositories/e/e_repository_profile.hh8
-rw-r--r--paludis/repositories/e/e_repository_profile_file.cc6
-rw-r--r--paludis/repositories/e/e_repository_sets.cc45
-rw-r--r--paludis/repositories/e/e_repository_sets.hh8
-rw-r--r--paludis/repositories/e/e_repository_sets_TEST.cc34
-rw-r--r--paludis/repositories/e/e_stripper.hh2
-rw-r--r--paludis/repositories/e/eapi-fwd.hh4
-rw-r--r--paludis/repositories/e/eapi.cc22
-rw-r--r--paludis/repositories/e/eapi.hh6
-rw-r--r--paludis/repositories/e/eapi.sr6
-rw-r--r--paludis/repositories/e/eapi_phase.cc4
-rw-r--r--paludis/repositories/e/ebuild.cc43
-rw-r--r--paludis/repositories/e/ebuild.hh30
-rw-r--r--paludis/repositories/e/ebuild_entries.cc109
-rw-r--r--paludis/repositories/e/ebuild_entries.hh28
-rw-r--r--paludis/repositories/e/ebuild_flat_metadata_cache.cc16
-rw-r--r--paludis/repositories/e/ebuild_flat_metadata_cache.hh8
-rw-r--r--paludis/repositories/e/ebuild_id.cc180
-rw-r--r--paludis/repositories/e/ebuild_id.hh68
-rw-r--r--paludis/repositories/e/eclass_mtimes.cc15
-rw-r--r--paludis/repositories/e/eclass_mtimes.hh6
-rw-r--r--paludis/repositories/e/exheres_layout.cc109
-rw-r--r--paludis/repositories/e/exheres_layout.hh32
-rw-r--r--paludis/repositories/e/exndbam_id.cc22
-rw-r--r--paludis/repositories/e/exndbam_id.hh4
-rw-r--r--paludis/repositories/e/exndbam_repository.cc46
-rw-r--r--paludis/repositories/e/exndbam_repository.hh22
-rw-r--r--paludis/repositories/e/exndbam_repository_TEST.cc4
-rw-r--r--paludis/repositories/e/fetch_visitor.cc22
-rw-r--r--paludis/repositories/e/fetch_visitor.hh6
-rw-r--r--paludis/repositories/e/fetch_visitor_TEST.cc6
-rw-r--r--paludis/repositories/e/fix_locked_dependencies.cc66
-rw-r--r--paludis/repositories/e/fix_locked_dependencies.hh8
-rw-r--r--paludis/repositories/e/fix_locked_dependencies_TEST.cc20
-rw-r--r--paludis/repositories/e/glsa.cc12
-rw-r--r--paludis/repositories/e/glsa.hh9
-rw-r--r--paludis/repositories/e/layout.cc20
-rw-r--r--paludis/repositories/e/layout.hh42
-rw-r--r--paludis/repositories/e/make_ebuild_repository.cc24
-rw-r--r--paludis/repositories/e/make_ebuild_repository.hh10
-rw-r--r--paludis/repositories/e/package_dep_spec.cc7
-rw-r--r--paludis/repositories/e/package_dep_spec.hh4
-rw-r--r--paludis/repositories/e/pipe_command_handler.cc28
-rw-r--r--paludis/repositories/e/pipe_command_handler.hh4
-rw-r--r--paludis/repositories/e/pretend_fetch_visitor.cc12
-rw-r--r--paludis/repositories/e/pretend_fetch_visitor.hh4
-rw-r--r--paludis/repositories/e/qa/categories.cc2
-rw-r--r--paludis/repositories/e/qa/categories.hh4
-rw-r--r--paludis/repositories/e/qa/default_functions.cc2
-rw-r--r--paludis/repositories/e/qa/default_functions.hh4
-rw-r--r--paludis/repositories/e/qa/default_functions_TEST.cc14
-rw-r--r--paludis/repositories/e/qa/deprecated_functions.cc4
-rw-r--r--paludis/repositories/e/qa/deprecated_functions.hh4
-rw-r--r--paludis/repositories/e/qa/eapi_supported.cc2
-rw-r--r--paludis/repositories/e/qa/eapi_supported.hh4
-rw-r--r--paludis/repositories/e/qa/ebuild_count.cc4
-rw-r--r--paludis/repositories/e/qa/ebuild_count.hh4
-rw-r--r--paludis/repositories/e/qa/extractors.cc6
-rw-r--r--paludis/repositories/e/qa/extractors.hh4
-rw-r--r--paludis/repositories/e/qa/extractors_TEST.cc22
-rw-r--r--paludis/repositories/e/qa/fetches_key.cc10
-rw-r--r--paludis/repositories/e/qa/fetches_key.hh4
-rw-r--r--paludis/repositories/e/qa/function_keyword.cc4
-rw-r--r--paludis/repositories/e/qa/function_keyword.hh4
-rw-r--r--paludis/repositories/e/qa/function_keyword_TEST.cc4
-rw-r--r--paludis/repositories/e/qa/header.cc4
-rw-r--r--paludis/repositories/e/qa/header.hh4
-rw-r--r--paludis/repositories/e/qa/homepage_key.cc10
-rw-r--r--paludis/repositories/e/qa/homepage_key.hh4
-rw-r--r--paludis/repositories/e/qa/homepage_key_TEST.cc14
-rw-r--r--paludis/repositories/e/qa/inherited_key.cc2
-rw-r--r--paludis/repositories/e/qa/inherited_key.hh4
-rw-r--r--paludis/repositories/e/qa/iuse_key.cc4
-rw-r--r--paludis/repositories/e/qa/iuse_key.hh6
-rw-r--r--paludis/repositories/e/qa/keywords_key.cc2
-rw-r--r--paludis/repositories/e/qa/keywords_key.hh4
-rw-r--r--paludis/repositories/e/qa/kv_variables.cc2
-rw-r--r--paludis/repositories/e/qa/kv_variables.hh4
-rw-r--r--paludis/repositories/e/qa/kv_variables_TEST.cc10
-rw-r--r--paludis/repositories/e/qa/license_key.cc12
-rw-r--r--paludis/repositories/e/qa/license_key.hh6
-rw-r--r--paludis/repositories/e/qa/manifest.cc32
-rw-r--r--paludis/repositories/e/qa/manifest.hh4
-rw-r--r--paludis/repositories/e/qa/manifest_TEST.cc36
-rw-r--r--paludis/repositories/e/qa/metadata_keys.cc38
-rw-r--r--paludis/repositories/e/qa/metadata_keys.hh4
-rw-r--r--paludis/repositories/e/qa/qa.cc6
-rw-r--r--paludis/repositories/e/qa/qa_checks.cc102
-rw-r--r--paludis/repositories/e/qa/qa_checks.hh47
-rw-r--r--paludis/repositories/e/qa/qa_checks_group.cc13
-rw-r--r--paludis/repositories/e/qa/qa_controller.cc111
-rw-r--r--paludis/repositories/e/qa/qa_controller.hh12
-rw-r--r--paludis/repositories/e/qa/restrict_key.cc10
-rw-r--r--paludis/repositories/e/qa/restrict_key.hh4
-rw-r--r--paludis/repositories/e/qa/root_variable.cc2
-rw-r--r--paludis/repositories/e/qa/root_variable.hh4
-rw-r--r--paludis/repositories/e/qa/short_description_key.cc2
-rw-r--r--paludis/repositories/e/qa/short_description_key.hh4
-rw-r--r--paludis/repositories/e/qa/spec_keys.cc52
-rw-r--r--paludis/repositories/e/qa/spec_keys.hh4
-rw-r--r--paludis/repositories/e/qa/spec_keys_TEST.cc42
-rw-r--r--paludis/repositories/e/qa/stray_files.cc8
-rw-r--r--paludis/repositories/e/qa/stray_files.hh10
-rw-r--r--paludis/repositories/e/qa/subshell_die.cc4
-rw-r--r--paludis/repositories/e/qa/subshell_die.hh4
-rw-r--r--paludis/repositories/e/qa/subshell_die_TEST.cc4
-rw-r--r--paludis/repositories/e/qa/variable_assigns.cc4
-rw-r--r--paludis/repositories/e/qa/variable_assigns.hh4
-rw-r--r--paludis/repositories/e/qa/visibility.cc28
-rw-r--r--paludis/repositories/e/qa/visibility.hh6
-rw-r--r--paludis/repositories/e/qa/visibility_TEST.cc24
-rw-r--r--paludis/repositories/e/qa/whitespace.cc4
-rw-r--r--paludis/repositories/e/qa/whitespace.hh4
-rw-r--r--paludis/repositories/e/registration.cc4
-rw-r--r--paludis/repositories/e/source_uri_finder.cc6
-rw-r--r--paludis/repositories/e/source_uri_finder_TEST.cc6
-rw-r--r--paludis/repositories/e/traditional_layout.cc108
-rw-r--r--paludis/repositories/e/traditional_layout.hh32
-rw-r--r--paludis/repositories/e/use_desc.cc11
-rw-r--r--paludis/repositories/e/use_requirements.cc14
-rw-r--r--paludis/repositories/e/use_requirements.hh18
-rw-r--r--paludis/repositories/e/vdb_id.cc4
-rw-r--r--paludis/repositories/e/vdb_id.hh4
-rw-r--r--paludis/repositories/e/vdb_merger.cc7
-rw-r--r--paludis/repositories/e/vdb_merger.hh4
-rw-r--r--paludis/repositories/e/vdb_merger_TEST.cc2
-rw-r--r--paludis/repositories/e/vdb_repository.cc114
-rw-r--r--paludis/repositories/e/vdb_repository.hh28
-rw-r--r--paludis/repositories/e/vdb_repository_TEST.cc166
-rw-r--r--paludis/repositories/e/vdb_unmerger.cc24
-rw-r--r--paludis/repositories/e/vdb_unmerger.hh10
-rw-r--r--paludis/repositories/e/vdb_unmerger_TEST.cc2
-rw-r--r--paludis/repositories/e/xml_things.cc18
-rw-r--r--paludis/repositories/e/xml_things_TEST.cc6
-rw-r--r--paludis/repositories/fake/fake_installed_repository.cc18
-rw-r--r--paludis/repositories/fake/fake_installed_repository.hh6
-rw-r--r--paludis/repositories/fake/fake_installed_repository_TEST.cc4
-rw-r--r--paludis/repositories/fake/fake_package_id.cc226
-rw-r--r--paludis/repositories/fake/fake_package_id.hh104
-rw-r--r--paludis/repositories/fake/fake_repository.cc14
-rw-r--r--paludis/repositories/fake/fake_repository.hh8
-rw-r--r--paludis/repositories/fake/fake_repository_TEST.cc4
-rw-r--r--paludis/repositories/fake/fake_repository_base.cc60
-rw-r--r--paludis/repositories/fake/fake_repository_base.hh28
-rw-r--r--paludis/repositories/gems/gem_specification.cc108
-rw-r--r--paludis/repositories/gems/gem_specification.hh54
-rw-r--r--paludis/repositories/gems/gem_specification_TEST.cc2
-rw-r--r--paludis/repositories/gems/gem_specifications.cc20
-rw-r--r--paludis/repositories/gems/gem_specifications.hh8
-rw-r--r--paludis/repositories/gems/gems_repository.cc57
-rw-r--r--paludis/repositories/gems/gems_repository.hh14
-rw-r--r--paludis/repositories/gems/installed_gems_repository.cc39
-rw-r--r--paludis/repositories/gems/installed_gems_repository.hh14
-rw-r--r--paludis/repositories/gems/registration.cc8
-rw-r--r--paludis/repositories/gems/yaml.cc16
-rw-r--r--paludis/repositories/unpackaged/dep_parser.cc10
-rw-r--r--paludis/repositories/unpackaged/dep_parser.hh4
-rw-r--r--paludis/repositories/unpackaged/dep_parser_TEST.cc4
-rw-r--r--paludis/repositories/unpackaged/installed_id.cc128
-rw-r--r--paludis/repositories/unpackaged/installed_id.hh48
-rw-r--r--paludis/repositories/unpackaged/installed_repository.cc48
-rw-r--r--paludis/repositories/unpackaged/installed_repository.hh16
-rw-r--r--paludis/repositories/unpackaged/installed_repository_TEST.cc76
-rw-r--r--paludis/repositories/unpackaged/registration.cc8
-rw-r--r--paludis/repositories/unpackaged/unpackaged_id.cc94
-rw-r--r--paludis/repositories/unpackaged/unpackaged_id.hh48
-rw-r--r--paludis/repositories/unpackaged/unpackaged_key.cc14
-rw-r--r--paludis/repositories/unpackaged/unpackaged_key.hh8
-rw-r--r--paludis/repositories/unpackaged/unpackaged_repository.cc40
-rw-r--r--paludis/repositories/unpackaged/unpackaged_repository.hh12
-rw-r--r--paludis/repositories/unpackaged/unpackaged_repository_TEST.cc28
-rw-r--r--paludis/repositories/unpackaged/unpackaged_stripper.hh2
-rw-r--r--paludis/repositories/virtuals/installed_virtuals_repository.cc51
-rw-r--r--paludis/repositories/virtuals/installed_virtuals_repository.hh20
-rw-r--r--paludis/repositories/virtuals/installed_virtuals_repository_TEST.cc4
-rw-r--r--paludis/repositories/virtuals/package_id.cc128
-rw-r--r--paludis/repositories/virtuals/package_id.hh58
-rw-r--r--paludis/repositories/virtuals/virtuals_repository.cc91
-rw-r--r--paludis/repositories/virtuals/virtuals_repository.hh24
-rw-r--r--paludis/repositories/virtuals/virtuals_repository_TEST.cc26
-rw-r--r--paludis/repository-fwd.hh12
-rw-r--r--paludis/repository.cc16
-rw-r--r--paludis/repository.hh36
-rw-r--r--paludis/repository_maker.cc6
-rw-r--r--paludis/repository_maker.hh6
-rw-r--r--paludis/repository_name_cache.cc27
-rw-r--r--paludis/repository_name_cache.hh6
-rw-r--r--paludis/repository_name_cache_TEST.cc24
-rw-r--r--paludis/selinux/security_context.cc16
-rw-r--r--paludis/selinux/security_context.hh16
-rw-r--r--paludis/set_file.cc66
-rw-r--r--paludis/set_file.hh4
-rw-r--r--paludis/set_file.sr4
-rw-r--r--paludis/set_file_TEST.cc22
-rw-r--r--paludis/show_suggest_visitor.cc40
-rw-r--r--paludis/show_suggest_visitor.hh4
-rw-r--r--paludis/stage_builder_task.cc8
-rw-r--r--paludis/stage_builder_task.hh17
-rw-r--r--paludis/stringify_formatter-impl.hh36
-rw-r--r--paludis/stripper.cc6
-rw-r--r--paludis/sync_task.cc12
-rw-r--r--paludis/syncer.cc8
-rw-r--r--paludis/uninstall_list.cc112
-rw-r--r--paludis/uninstall_list.hh22
-rw-r--r--paludis/uninstall_list.sr4
-rw-r--r--paludis/uninstall_list_TEST.cc46
-rw-r--r--paludis/uninstall_task.cc40
-rw-r--r--paludis/uninstall_task.hh10
-rw-r--r--paludis/unmerger.cc22
-rw-r--r--paludis/unmerger.hh26
-rw-r--r--paludis/user_dep_spec.cc2
-rw-r--r--paludis/util/action_queue.cc16
-rw-r--r--paludis/util/action_queue.hh4
-rw-r--r--paludis/util/action_queue_TEST.cc4
-rw-r--r--paludis/util/clone-impl.hh4
-rw-r--r--paludis/util/clone.hh8
-rw-r--r--paludis/util/config_file-fwd.hh3
-rw-r--r--paludis/util/config_file.cc36
-rw-r--r--paludis/util/config_file.hh10
-rw-r--r--paludis/util/config_file_TEST.cc6
-rw-r--r--paludis/util/damerau_levenshtein.cc2
-rw-r--r--paludis/util/dir_iterator.cc26
-rw-r--r--paludis/util/exception.cc4
-rw-r--r--paludis/util/files.m44
-rw-r--r--paludis/util/fs_entry.cc2
-rw-r--r--paludis/util/fs_entry.hh4
-rw-r--r--paludis/util/graph-impl.hh4
-rw-r--r--paludis/util/graph.cc6
-rw-r--r--paludis/util/graph.hh10
-rw-r--r--paludis/util/hashes.cc30
-rw-r--r--paludis/util/hashes.hh124
-rw-r--r--paludis/util/indirect_iterator.hh20
-rw-r--r--paludis/util/indirect_iterator_TEST.cc22
-rw-r--r--paludis/util/instantiation_policy_TEST.cc11
-rw-r--r--paludis/util/kc.hh202
-rw-r--r--paludis/util/log.cc12
-rw-r--r--paludis/util/make_shared_ptr-fwd.hh10
-rw-r--r--paludis/util/make_shared_ptr.hh8
-rw-r--r--paludis/util/member_iterator-fwd.hh6
-rw-r--r--paludis/util/member_iterator-impl.hh20
-rw-r--r--paludis/util/member_iterator.hh22
-rw-r--r--paludis/util/remove_shared_ptr.hh26
-rw-r--r--paludis/util/save.hh6
-rw-r--r--paludis/util/save_TEST.cc2
-rw-r--r--paludis/util/stringify.hh6
-rw-r--r--paludis/util/system.cc26
-rw-r--r--paludis/util/system.hh14
-rw-r--r--paludis/util/system_TEST.cc6
-rw-r--r--paludis/util/thread.cc8
-rw-r--r--paludis/util/thread.hh10
-rw-r--r--paludis/util/thread_TEST.cc4
-rw-r--r--paludis/util/thread_pool.cc8
-rw-r--r--paludis/util/thread_pool.hh6
-rw-r--r--paludis/util/thread_pool_TEST.cc4
-rw-r--r--paludis/util/tr1_functional.hh81
-rw-r--r--paludis/util/tr1_memory.hh56
-rw-r--r--paludis/util/tr1_type_traits.hh63
-rw-r--r--paludis/util/virtual_constructor-impl.hh6
-rw-r--r--paludis/util/virtual_constructor_TEST.cc18
-rw-r--r--paludis/util/visitor-impl.hh28
-rw-r--r--paludis/util/visitor.hh166
-rw-r--r--paludis/util/visitor_TEST.cc32
-rw-r--r--paludis/util/visitor_cast.hh12
-rw-r--r--paludis/util/visitor_cast_TEST.cc16
-rw-r--r--paludis/util/wrapped_forward_iterator.hh13
-rw-r--r--paludis/version_requirements-fwd.hh4
-rw-r--r--paludis/version_spec.cc2
-rw-r--r--paludis/version_spec.hh10
-rw-r--r--paludis/version_spec_TEST.cc62
-rw-r--r--python/action.cc8
-rw-r--r--python/additional_tests.cc18
-rw-r--r--python/contents.cc16
-rw-r--r--python/dep_label.cc20
-rw-r--r--python/dep_list.cc10
-rw-r--r--python/dep_spec.cc138
-rw-r--r--python/dep_spec.hh48
-rw-r--r--python/dep_tag.cc6
-rw-r--r--python/environment.cc62
-rw-r--r--python/exception.cc6
-rw-r--r--python/exception.hh16
-rw-r--r--python/iterable.hh34
-rw-r--r--python/mask.cc62
-rw-r--r--python/metadata_key.cc212
-rw-r--r--python/package_database.cc2
-rw-r--r--python/paludis_python.hh25
-rw-r--r--python/query.cc82
-rw-r--r--python/repository.cc8
-rw-r--r--ruby/action.cc72
-rw-r--r--ruby/contents.cc76
-rw-r--r--ruby/dep_list.cc94
-rw-r--r--ruby/dep_spec.cc374
-rw-r--r--ruby/dep_tag.cc86
-rw-r--r--ruby/environment.cc56
-rw-r--r--ruby/find_unused_packages_task.cc2
-rw-r--r--ruby/mask.cc50
-rw-r--r--ruby/metadata_key.cc204
-rw-r--r--ruby/package_database.cc40
-rw-r--r--ruby/package_id.cc92
-rw-r--r--ruby/paludis_ruby.cc12
-rw-r--r--ruby/paludis_ruby.hh50
-rw-r--r--ruby/repository.cc138
-rw-r--r--src/clients/accerso/accerso.cc14
-rw-r--r--src/clients/adjutrix/adjutrix.cc4
-rw-r--r--src/clients/adjutrix/display_default_system_resolution.cc2
-rw-r--r--src/clients/adjutrix/downgrade_check.cc2
-rw-r--r--src/clients/adjutrix/find_dropped_keywords.cc8
-rw-r--r--src/clients/adjutrix/find_insecure_packages.cc10
-rw-r--r--src/clients/adjutrix/find_reverse_deps.cc18
-rw-r--r--src/clients/adjutrix/find_stable_candidates.cc8
-rw-r--r--src/clients/adjutrix/find_unused_packages.cc6
-rw-r--r--src/clients/adjutrix/keywords_graph.cc25
-rw-r--r--src/clients/adjutrix/what_needs_keywording.cc15
-rw-r--r--src/clients/contrarius/contrarius.cc18
-rw-r--r--src/clients/contrarius/contrarius_stage_options.sr12
-rw-r--r--src/clients/contrarius/install.cc6
-rw-r--r--src/clients/contrarius/install.hh3
-rw-r--r--src/clients/contrarius/stage.cc20
-rw-r--r--src/clients/contrarius/stage.hh18
-rw-r--r--src/clients/contrarius/stage_builder.cc10
-rw-r--r--src/clients/contrarius/stage_builder.hh10
-rw-r--r--src/clients/gtkpaludis/gtkpaludis.cc2
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/categories_list.cc4
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/categories_list_model.cc10
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/categories_list_model.hh4
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/messages_page.cc2
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/package_buttons.cc2
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/package_buttons.hh4
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/packages_list.cc4
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/packages_list_filtered_model.hh4
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/packages_list_model.cc24
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/packages_list_model.hh8
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/packages_page.cc24
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/packages_page.hh16
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/packages_repository_filter.cc2
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/packages_repository_filter_model.cc12
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/packages_repository_filter_model.hh4
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/repositories_list_model.cc4
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/repositories_list_model.hh4
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/repository_buttons.cc2
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/repository_info_model.cc4
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/repository_info_model.hh4
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/sets_list.cc4
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/sets_list_model.cc12
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/sets_list_model.hh4
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/task_window.cc4
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/threaded_window.cc6
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/version_info_model.cc20
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/version_info_model.hh6
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/versions_list.cc6
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/versions_list_model.cc12
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/versions_list_model.hh6
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/versions_page.cc6
-rw-r--r--src/clients/gtkpaludis/libgtkpaludis/versions_page.hh6
-rw-r--r--src/clients/importare/importare.cc12
-rw-r--r--src/clients/importare/install.cc10
-rw-r--r--src/clients/importare/install.hh8
-rw-r--r--src/clients/inquisitio/do_search.cc80
-rw-r--r--src/clients/inquisitio/inquisitio.cc2
-rw-r--r--src/clients/inquisitio/key_extractor.cc32
-rw-r--r--src/clients/inquisitio/matcher.cc8
-rw-r--r--src/clients/inquisitio/matcher.hh8
-rw-r--r--src/clients/instruo/instruo.cc50
-rw-r--r--src/clients/paludis/applets.cc44
-rw-r--r--src/clients/paludis/applets.hh16
-rw-r--r--src/clients/paludis/do_config.cc16
-rw-r--r--src/clients/paludis/do_config.hh6
-rw-r--r--src/clients/paludis/do_contents.cc14
-rw-r--r--src/clients/paludis/do_contents.hh12
-rw-r--r--src/clients/paludis/do_executables.cc12
-rw-r--r--src/clients/paludis/do_executables.hh10
-rw-r--r--src/clients/paludis/info.cc22
-rw-r--r--src/clients/paludis/info.hh6
-rw-r--r--src/clients/paludis/install.cc10
-rw-r--r--src/clients/paludis/install.hh4
-rw-r--r--src/clients/paludis/list.cc20
-rw-r--r--src/clients/paludis/list.hh10
-rw-r--r--src/clients/paludis/owner.cc12
-rw-r--r--src/clients/paludis/owner.hh6
-rw-r--r--src/clients/paludis/paludis.cc50
-rw-r--r--src/clients/paludis/query.cc28
-rw-r--r--src/clients/paludis/query.hh4
-rw-r--r--src/clients/paludis/report.cc42
-rw-r--r--src/clients/paludis/report.hh2
-rw-r--r--src/clients/paludis/sync.cc6
-rw-r--r--src/clients/paludis/sync.hh4
-rw-r--r--src/clients/paludis/uninstall.cc12
-rw-r--r--src/clients/paludis/uninstall.hh6
-rw-r--r--src/clients/qualudis/qualudis.cc15
-rw-r--r--src/clients/reconcilio/broken_linkage_finder/broken_linkage_finder.cc74
-rw-r--r--src/clients/reconcilio/broken_linkage_finder/broken_linkage_finder.hh13
-rw-r--r--src/clients/reconcilio/broken_linkage_finder/configuration.cc25
-rw-r--r--src/clients/reconcilio/broken_linkage_finder/elf_linkage_checker.cc8
-rw-r--r--src/clients/reconcilio/broken_linkage_finder/elf_linkage_checker.hh5
-rw-r--r--src/clients/reconcilio/broken_linkage_finder/libtool_linkage_checker.cc2
-rw-r--r--src/clients/reconcilio/broken_linkage_finder/libtool_linkage_checker.hh2
-rw-r--r--src/clients/reconcilio/broken_linkage_finder/linkage_checker.hh7
-rw-r--r--src/clients/reconcilio/fix_linkage.cc6
-rw-r--r--src/clients/reconcilio/fix_linkage.hh5
-rw-r--r--src/clients/reconcilio/install.cc14
-rw-r--r--src/clients/reconcilio/install.hh8
-rw-r--r--src/clients/reconcilio/littlelf/elf.cc2
-rw-r--r--src/clients/reconcilio/littlelf/elf_dynamic_section.cc20
-rw-r--r--src/clients/reconcilio/littlelf/elf_dynamic_section.hh7
-rw-r--r--src/clients/reconcilio/reconcilio.cc4
-rw-r--r--src/clients/reconcilio/util/wildcard_expander.cc7
-rw-r--r--src/output/colour_formatter.cc16
-rw-r--r--src/output/colour_formatter.hh8
-rw-r--r--src/output/console_install_task.cc70
-rw-r--r--src/output/console_install_task.hh42
-rw-r--r--src/output/console_install_task.sr2
-rw-r--r--src/output/console_query_task.cc32
-rw-r--r--src/output/console_query_task.hh18
-rw-r--r--src/output/mask_displayer.cc12
-rw-r--r--src/output/mask_displayer.hh4
613 files changed, 7709 insertions, 8475 deletions
diff --git a/NEWS b/NEWS
index 1f02af1..1c976a2 100644
--- a/NEWS
+++ b/NEWS
@@ -4,6 +4,10 @@ News for Paludis
This file lists the major changes between versions. For a more detailed list
of every change, see the ChangeLog.
+trunk/:
+ * Compilers without tr1 memory, type traits and functional support are no
+ longer supported. This means you, gcc-3.
+
0.26.0:
* Fixed gcc-3.4 compile.
diff --git a/configure.ac b/configure.ac
index 5d0ac74..d3e951e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -267,46 +267,12 @@ int main(int, char **)
m.insert(std::make_pair(1, 2));
}
],
- [
- AC_MSG_RESULT([std::tr1::unordered_map])
- PALUDIS_CXXFLAGS="${PALUDIS_CXXFLAGS} -DPALUDIS_HASH_IS_STD_TR1_UNORDERED=1"
- PALUDIS_PC_CFLAGS="${PALUDIS_PC_CFLAGS} -DPALUDIS_HASH_IS_STD_TR1_UNORDERED=1"
- ],
- [
- AC_COMPILE_IFELSE([
-#include <ext/hash_map>
-int main(int, char **)
-{
- __gnu_cxx::hash_map<int, int> m;
- m.insert(std::make_pair(1, 2));
-}
-],
- [
- AC_MSG_RESULT([__gnu_cxx::hash_map])
- PALUDIS_CXXFLAGS="${PALUDIS_CXXFLAGS} -DPALUDIS_HASH_IS_GNU_CXX_HASH=1"
- PALUDIS_PC_CFLAGS="${PALUDIS_PC_CFLAGS} -DPALUDIS_HASH_IS_GNU_CXX_HASH=1"
- ],
- [
- AC_COMPILE_IFELSE([
-#include <hash_map>
-int main(int, char **)
-{
- std::hash_map<int, int> m;
- m.insert(std::make_pair(1, 2));
-}
-],
- [
- AC_MSG_RESULT([std::hash_map])
- PALUDIS_CXXFLAGS="${PALUDIS_CXXFLAGS} -DPALUDIS_HASH_IS_STD_HASH=1"
- PALUDIS_PC_CFLAGS="${PALUDIS_PC_CFLAGS} -DPALUDIS_HASH_IS_STD_HASH=1"
- ],
- [
- AC_MSG_RESULT([no, falling back to std::map (slower)])
- ])])])
+ [AC_MSG_RESULT([std::tr1::unordered_map])],
+ [AC_MSG_RESULT([no])
+ AC_MSG_ERROR([Your compiler doesn't support tr1])])
dnl }}}
dnl {{{ tr1 shared pointers
-need_pointer_wrappers=no
AC_MSG_CHECKING([for std::tr1::shared_ptr<>])
AC_COMPILE_IFELSE([
#include <tr1/memory>
@@ -316,31 +282,12 @@ int main(int, char **)
return *x;
}
],
- [AC_MSG_RESULT([yes])
- PALUDIS_CXXFLAGS="${PALUDIS_CXXFLAGS} -DPALUDIS_TR1_MEMORY_IS_STD_TR1=1"
- PALUDIS_PC_CFLAGS="${PALUDIS_PC_CFLAGS} -DPALUDIS_TR1_MEMORY_IS_STD_TR1=1"
- ],
- [AC_MSG_RESULT([no])
- AC_MSG_CHECKING([for boost::shared_ptr<>])
- AC_COMPILE_IFELSE([
-#include <boost/shared_ptr.hpp>
-int main(int, char **)
-{
- boost::shared_ptr<int> x(new int(10));
- return *x;
-}
-],
- [AC_MSG_RESULT([yes])
- PALUDIS_CXXFLAGS="${PALUDIS_CXXFLAGS} -DPALUDIS_TR1_MEMORY_IS_BOOST=1"
- PALUDIS_PC_CFLAGS="${PALUDIS_PC_CFLAGS} -DPALUDIS_TR1_MEMORY_IS_BOOST=1"
- need_pointer_wrappers=yes],
+ [AC_MSG_RESULT([yes])],
[AC_MSG_RESULT([no])
- AC_MSG_ERROR([Your compiler doesn't support tr1 and boost is not installed])])])
-AM_CONDITIONAL([NEED_POINTER_WRAPPERS], test x$need_pointer_wrappers = "xyes")
+ AC_MSG_ERROR([Your compiler doesn't support tr1])])
dnl }}}
dnl {{{ tr1 type traits
-need_type_traits_wrappers=no
AC_MSG_CHECKING([for std::tr1::remove_pointer<>])
AC_COMPILE_IFELSE([
#include <tr1/type_traits>
@@ -350,31 +297,12 @@ int main(int, char **)
return x;
}
],
- [AC_MSG_RESULT([yes])
- PALUDIS_CXXFLAGS="${PALUDIS_CXXFLAGS} -DPALUDIS_TR1_TYPE_TRAITS_IS_STD_TR1=1"
- PALUDIS_PC_CFLAGS="${PALUDIS_PC_CFLAGS} -DPALUDIS_TR1_TYPE_TRAITS_IS_STD_TR1=1"
- ],
- [AC_MSG_RESULT([no])
- AC_MSG_CHECKING([for boost::remove_pointer<>])
- AC_COMPILE_IFELSE([
-#include <boost/type_traits.hpp>
-int main(int, char **)
-{
- boost::remove_pointer<int *>::type x(10);
- return x;
-}
-],
- [AC_MSG_RESULT([yes])
- PALUDIS_CXXFLAGS="${PALUDIS_CXXFLAGS} -DPALUDIS_TR1_TYPE_TRAITS_IS_BOOST=1"
- PALUDIS_PC_CFLAGS="${PALUDIS_PC_CFLAGS} -DPALUDIS_TR1_TYPE_TRAITS_IS_BOOST=1"
- need_type_traits_wrappers=yes],
+ [AC_MSG_RESULT([yes])],
[AC_MSG_RESULT([no])
- AC_MSG_ERROR([Your compiler doesn't support tr1 and boost is not installed])])])
-AM_CONDITIONAL([NEED_TYPE_TRAITS_WRAPPERS], test x$need_type_traits_wrappers = "xyes")
+ AC_MSG_ERROR([Your compiler doesn't support tr1])])
dnl }}}
dnl {{{ tr1 binders
-need_bind_wrappers=no
AC_MSG_CHECKING([for std::tr1::bind<>])
AC_COMPILE_IFELSE([
#include <tr1/functional>
@@ -396,39 +324,9 @@ int main(int, char **)
std::tr1::bind(std::tr1::mem_fn(&S::x), &s, _1));
}
],
- [AC_MSG_RESULT([yes])
- PALUDIS_CXXFLAGS="${PALUDIS_CXXFLAGS} -DPALUDIS_TR1_FUNCTIONAL_IS_STD_TR1=1"
- PALUDIS_PC_CFLAGS="${PALUDIS_PC_CFLAGS} -DPALUDIS_TR1_FUNCTIONAL_IS_STD_TR1=1"
- ],
- [AC_MSG_RESULT([no])
- AC_MSG_CHECKING([for boost::bind<>])
- AC_COMPILE_IFELSE([
-#include <boost/bind.hpp>
-#include <boost/mem_fn.hpp>
-#include <functional>
-#include <algorithm>
-#include <list>
-struct S
-{
- void x(const int) const
- {
- }
-};
-int main(int, char **)
-{
- std::list<int> l;
- S s;
- std::for_each(l.begin(), l.end(),
- boost::bind(boost::mem_fn(&S::x), &s, _1));
-}
-],
- [AC_MSG_RESULT([yes])
- PALUDIS_CXXFLAGS="${PALUDIS_CXXFLAGS} -DPALUDIS_TR1_FUNCTIONAL_IS_BOOST=1"
- PALUDIS_PC_CFLAGS="${PALUDIS_PC_CFLAGS} -DPALUDIS_TR1_FUNCTIONAL_IS_BOOST=1"
- need_bind_wrappers=yes],
+ [AC_MSG_RESULT([yes])],
[AC_MSG_RESULT([no])
- AC_MSG_ERROR([Your compiler doesn't support tr1 and boost is not installed])])])
-AM_CONDITIONAL([NEED_BIND_WRAPPERS], test x$need_bind_wrappers = "xyes")
+ AC_MSG_ERROR([Your compiler doesn't support tr1])])
dnl }}}
need_xml_check=
diff --git a/doc/api/cplusplus/examples/example_action.cc b/doc/api/cplusplus/examples/example_action.cc
index ecfc13b..4faa5b6 100644
--- a/doc/api/cplusplus/examples/example_action.cc
+++ b/doc/api/cplusplus/examples/example_action.cc
@@ -33,11 +33,11 @@ int main(int argc, char * argv[])
"example_action", "EXAMPLE_ACTION_OPTIONS", "EXAMPLE_ACTION_CMDLINE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* Fetch package IDs for 'sys-apps/paludis'. */
- tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
+ std::tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
query::Matches(make_package_dep_spec().package(QualifiedPackageName("sys-apps/paludis"))),
qo_order_by_version));
diff --git a/doc/api/cplusplus/examples/example_contents.cc b/doc/api/cplusplus/examples/example_contents.cc
index 6bfae68..69f956d 100644
--- a/doc/api/cplusplus/examples/example_contents.cc
+++ b/doc/api/cplusplus/examples/example_contents.cc
@@ -75,11 +75,11 @@ int main(int argc, char * argv[])
"example_contents", "EXAMPLE_CONTENTS_OPTIONS", "EXAMPLE_CONTENTS_CMDLINE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* Fetch package IDs for installed 'sys-apps/paludis'. */
- tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
+ std::tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
query::Matches(make_package_dep_spec().package(QualifiedPackageName("sys-apps/paludis"))) &
query::SupportsAction<InstalledAction>(),
qo_order_by_version));
@@ -100,7 +100,7 @@ int main(int argc, char * argv[])
/* Visit the contents key's value's entries with our visitor. We use
* indirect_iterator because value()->begin() and ->end() return
- * iterators to tr1::shared_ptr<>s rather than raw objects. */
+ * iterators to std::tr1::shared_ptr<>s rather than raw objects. */
ContentsPrinter p;
std::for_each(
indirect_iterator((*i)->contents_key()->value()->begin()),
diff --git a/doc/api/cplusplus/examples/example_dep_label.cc b/doc/api/cplusplus/examples/example_dep_label.cc
index 3627bfc..fd4d093 100644
--- a/doc/api/cplusplus/examples/example_dep_label.cc
+++ b/doc/api/cplusplus/examples/example_dep_label.cc
@@ -155,11 +155,11 @@ int main(int argc, char * argv[])
"example_dep_label", "EXAMPLE_DEP_LABEL_OPTIONS", "EXAMPLE_DEP_LABEL_CMDLINE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* Fetch package IDs for all installed packages. */
- tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
+ std::tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
query::SupportsAction<InstalledAction>(),
qo_whatever));
diff --git a/doc/api/cplusplus/examples/example_dep_spec.cc b/doc/api/cplusplus/examples/example_dep_spec.cc
index 89a38a0..85084a3 100644
--- a/doc/api/cplusplus/examples/example_dep_spec.cc
+++ b/doc/api/cplusplus/examples/example_dep_spec.cc
@@ -41,7 +41,7 @@ int main(int argc, char * argv[])
"example_dep_spec", "EXAMPLE_DEP_SPEC_OPTIONS", "EXAMPLE_DEP_SPEC_CMDLINE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* For each command line parameter... */
@@ -122,7 +122,7 @@ int main(int argc, char * argv[])
/* And display packages matching that spec */
cout << " " << left << setw(24) << "Matches:" << " ";
- tr1::shared_ptr<const PackageIDSequence> ids(
+ std::tr1::shared_ptr<const PackageIDSequence> ids(
env->package_database()->query(query::Matches(spec), qo_order_by_version));
bool need_indent(false);
for (PackageIDSequence::ConstIterator i(ids->begin()), i_end(ids->end()) ;
diff --git a/doc/api/cplusplus/examples/example_dep_spec_flattener.cc b/doc/api/cplusplus/examples/example_dep_spec_flattener.cc
index 2b4d3bb..52eb8b2 100644
--- a/doc/api/cplusplus/examples/example_dep_spec_flattener.cc
+++ b/doc/api/cplusplus/examples/example_dep_spec_flattener.cc
@@ -38,11 +38,11 @@ int main(int argc, char * argv[])
"example_dep_spec_flattener", "EXAMPLE_DEP_SPEC_FLATTENER_OPTIONS", "EXAMPLE_DEP_SPEC_FLATTENER_CMDLINE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* Fetch package IDs for all installed packages. */
- tr1::shared_ptr<const PackageIDSequence> ids(
+ std::tr1::shared_ptr<const PackageIDSequence> ids(
env->package_database()->query(
query::SupportsAction<InstalledAction>(),
qo_order_by_version));
@@ -64,7 +64,7 @@ int main(int argc, char * argv[])
(*i)->provide_key()->value()->accept(provides);
/* The results are available through DepSpecFlattener::begin()
- * and ::end(). These return an iterator to a tr1::shared_ptr<>,
+ * and ::end(). These return an iterator to a std::tr1::shared_ptr<>,
* so we use indirect_iterator to add a level of dereferencing.*/
cout << " " << left << setw(24) << "Provides:" << " "
<< join(indirect_iterator(provides.begin()), indirect_iterator(provides.end()), " ")
diff --git a/doc/api/cplusplus/examples/example_dep_tag.cc b/doc/api/cplusplus/examples/example_dep_tag.cc
index b8e61c3..9ced77a 100644
--- a/doc/api/cplusplus/examples/example_dep_tag.cc
+++ b/doc/api/cplusplus/examples/example_dep_tag.cc
@@ -78,11 +78,11 @@ namespace
/* Display information about a named set. */
void display_set(
- const tr1::shared_ptr<const Environment> & env,
+ const std::tr1::shared_ptr<const Environment> & env,
const SetName & name,
SeenCategories & seen_categories)
{
- tr1::shared_ptr<const SetSpecTree::ConstItem> set(env->set(name));
+ std::tr1::shared_ptr<const SetSpecTree::ConstItem> set(env->set(name));
/* Environment::set can return a zero pointer, if a set is not known. */
if (! set)
@@ -132,7 +132,7 @@ int main(int argc, char * argv[])
"example_dep_tag", "EXAMPLE_DEP_TAG_OPTIONS", "EXAMPLE_DEP_TAG_CMDLINE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
SeenCategories seen_categories;
@@ -153,7 +153,7 @@ int main(int argc, char * argv[])
/* Fetch the category. DepTagCategoryMaker::find_maker returns a
* function that creates the category, rather than directly
* returning the category. */
- tr1::shared_ptr<const DepTagCategory> category(
+ std::tr1::shared_ptr<const DepTagCategory> category(
DepTagCategoryMaker::get_instance()->find_maker(*s)());
cout << left << setw(20) << " Visible:" << " " << boolalpha << category->visible() << endl;
diff --git a/doc/api/cplusplus/examples/example_dep_tree.cc b/doc/api/cplusplus/examples/example_dep_tree.cc
index a84e3e5..6a8c518 100644
--- a/doc/api/cplusplus/examples/example_dep_tree.cc
+++ b/doc/api/cplusplus/examples/example_dep_tree.cc
@@ -52,15 +52,15 @@ namespace
public ConstVisitor<DependencySpecTree>::VisitConstSequence<DependenciesCollector, AnyDepSpec>
{
private:
- const tr1::shared_ptr<const Environment> _env;
- const tr1::shared_ptr<const PackageID> _id;
+ const std::tr1::shared_ptr<const Environment> _env;
+ const std::tr1::shared_ptr<const PackageID> _id;
ResultsMap & _results;
std::set<SetName> _recursing_sets;
public:
DependenciesCollector(
- const tr1::shared_ptr<const Environment> & e,
- const tr1::shared_ptr<const PackageID> & i,
+ const std::tr1::shared_ptr<const Environment> & e,
+ const std::tr1::shared_ptr<const PackageID> & i,
ResultsMap & r) :
_env(e),
_id(i),
@@ -92,7 +92,7 @@ namespace
void visit_leaf(const NamedSetDepSpec & spec)
{
/* For named set specs, we visit the set. */
- tr1::shared_ptr<const SetSpecTree::ConstItem> set(_env->set(spec.name()));
+ std::tr1::shared_ptr<const SetSpecTree::ConstItem> set(_env->set(spec.name()));
/* First complication: we might have a name referring to a set
* that doesn't exist. */
@@ -140,14 +140,14 @@ namespace
public ConstVisitor<FetchableURISpecTree>::VisitConstSequence<FileExtensionsCollector, AllDepSpec>
{
private:
- const tr1::shared_ptr<const Environment> _env;
- const tr1::shared_ptr<const PackageID> _id;
+ const std::tr1::shared_ptr<const Environment> _env;
+ const std::tr1::shared_ptr<const PackageID> _id;
ResultsMap & _results;
public:
FileExtensionsCollector(
- const tr1::shared_ptr<const Environment> & e,
- const tr1::shared_ptr<const PackageID> & i,
+ const std::tr1::shared_ptr<const Environment> & e,
+ const std::tr1::shared_ptr<const PackageID> & i,
ResultsMap & r) :
_env(e),
_id(i),
@@ -190,11 +190,11 @@ int main(int argc, char * argv[])
"example_dep_tree", "EXAMPLE_DEP_TREE_OPTIONS", "EXAMPLE_DEP_TREE_CMDLINE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* Fetch package IDs for all installed packages. */
- tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
+ std::tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
query::SupportsAction<InstalledAction>(),
qo_order_by_version));
diff --git a/doc/api/cplusplus/examples/example_environment.cc b/doc/api/cplusplus/examples/example_environment.cc
index 4c91afd..dd4cc8b 100644
--- a/doc/api/cplusplus/examples/example_environment.cc
+++ b/doc/api/cplusplus/examples/example_environment.cc
@@ -43,7 +43,7 @@ int main(int argc, char * argv[])
* the environment class to use (e.g. 'paludis', 'portage') and the
* second part is passed as parameters to be handled by that
* environment's constructor. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* A lot of the Environment members aren't very useful to clients. The
@@ -54,7 +54,7 @@ int main(int argc, char * argv[])
* change in the future) use flag queries. The package database has its
* own examples, so we'll start with sets: */
- tr1::shared_ptr<SetSpecTree::ConstItem> world(env->set(SetName("world")));
+ std::tr1::shared_ptr<SetSpecTree::ConstItem> world(env->set(SetName("world")));
if (world)
{
/* See \ref example_dep_tree.cc "example_dep_tree.cc" for how to
@@ -65,7 +65,7 @@ int main(int argc, char * argv[])
cout << "No world set defined" << endl;
/* And use flags, for which we need a package IDs: */
- tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
+ std::tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
query::Matches(make_package_dep_spec().package(QualifiedPackageName("sys-apps/paludis"))) &
query::SupportsAction<InstalledAction>(),
qo_order_by_version));
diff --git a/doc/api/cplusplus/examples/example_formatter.cc b/doc/api/cplusplus/examples/example_formatter.cc
index 72f7e08..1e963be 100644
--- a/doc/api/cplusplus/examples/example_formatter.cc
+++ b/doc/api/cplusplus/examples/example_formatter.cc
@@ -155,11 +155,11 @@ int main(int argc, char * argv[])
"example_formatter", "EXAMPLE_FORMATTER_OPTIONS", "EXAMPLE_FORMATTER_CMDLINE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* Fetch package IDs for installable 'sys-apps/paludis'. */
- tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
+ std::tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
query::Matches(make_package_dep_spec().package(QualifiedPackageName("sys-apps/paludis"))) &
query::SupportsAction<InstallAction>(),
qo_order_by_version));
diff --git a/doc/api/cplusplus/examples/example_mask.cc b/doc/api/cplusplus/examples/example_mask.cc
index c8fd2d8..1461346 100644
--- a/doc/api/cplusplus/examples/example_mask.cc
+++ b/doc/api/cplusplus/examples/example_mask.cc
@@ -80,11 +80,11 @@ int main(int argc, char * argv[])
"example_mask", "EXAMPLE_MASK_OPTIONS", "EXAMPLE_MASK_CMDLINE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* Fetch package IDs for 'sys-apps/paludis'. */
- tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
+ std::tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
query::Matches(make_package_dep_spec().package(QualifiedPackageName("sys-apps/paludis"))),
qo_order_by_version));
diff --git a/doc/api/cplusplus/examples/example_match_package.cc b/doc/api/cplusplus/examples/example_match_package.cc
index 90fdd6d..09266ba 100644
--- a/doc/api/cplusplus/examples/example_match_package.cc
+++ b/doc/api/cplusplus/examples/example_match_package.cc
@@ -36,17 +36,17 @@ int main(int argc, char * argv[])
"example_match_package", "EXAMPLE_MATCH_PACKAGE_OPTIONS", "EXAMPLE_MATCH_PACKAGE_CMDLINE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* Fetch all installed packages. */
- tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
+ std::tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
query::SupportsAction<InstalledAction>(),
qo_order_by_version));
/* Fetch the 'system' and 'world' sets. Ordinarily we should check for
* zero pointers here, but these two sets will always exist. */
- tr1::shared_ptr<const SetSpecTree::ConstItem> system(env->set(SetName("system"))),
+ std::tr1::shared_ptr<const SetSpecTree::ConstItem> system(env->set(SetName("system"))),
world(env->set(SetName("world")));
/* For each ID: */
diff --git a/doc/api/cplusplus/examples/example_metadata_key.cc b/doc/api/cplusplus/examples/example_metadata_key.cc
index abd8f33..a5e2379 100644
--- a/doc/api/cplusplus/examples/example_metadata_key.cc
+++ b/doc/api/cplusplus/examples/example_metadata_key.cc
@@ -76,10 +76,10 @@ namespace
cout << indent << left << setw(30) << " Value:" << " " << key.value() << endl;
}
- void visit(const MetadataValueKey<tr1::shared_ptr<const PackageID> > & key)
+ void visit(const MetadataValueKey<std::tr1::shared_ptr<const PackageID> > & key)
{
cout << indent << left << setw(30) << " Class:" << " " <<
- "MetadataValueKey<tr1::shared_ptr<const PackageID> >" << endl;
+ "MetadataValueKey<std::tr1::shared_ptr<const PackageID> >" << endl;
cout << indent << left << setw(30) << " Value:" << " " << *key.value() << endl;
}
@@ -95,21 +95,21 @@ namespace
cout << indent << left << setw(30) << " Value:" << " " << buf << endl;
}
- void visit(const MetadataValueKey<tr1::shared_ptr<const Contents> > &)
+ void visit(const MetadataValueKey<std::tr1::shared_ptr<const Contents> > &)
{
cout << indent << left << setw(30) << " Class:" << " " <<
- "MetadataValueKey<tr1::shared_ptr<const Contents> > " << endl;
+ "MetadataValueKey<std::tr1::shared_ptr<const Contents> > " << endl;
/* We won't display the contents of the contents key here, since
* it involves creating another visitor. See \ref
* example_contents.cc "example_contents.cc" for that. */
}
- void visit(const MetadataValueKey<tr1::shared_ptr<const RepositoryMaskInfo> > & key)
+ void visit(const MetadataValueKey<std::tr1::shared_ptr<const RepositoryMaskInfo> > & key)
{
cout << indent << left << setw(30) << " Class:" << " " <<
- "MetadataValueKey<tr1::shared_ptr<const RepositoryMaskInfo> >" << endl;
+ "MetadataValueKey<std::tr1::shared_ptr<const RepositoryMaskInfo> >" << endl;
- /* MetadataValueKey<tr1::shared_ptr<const RepositoryMaskInfo> >::value()
+ /* MetadataValueKey<std::tr1::shared_ptr<const RepositoryMaskInfo> >::value()
* can return a zero pointer. Other keys can't. */
if (key.value())
{
@@ -255,11 +255,11 @@ int main(int argc, char * argv[])
"example_metadata_key", "EXAMPLE_METADATA_KEY_OPTIONS", "EXAMPLE_METADATA_KEY_CMDLINE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* Fetch package IDs for 'sys-apps/paludis'. */
- tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
+ std::tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
query::Matches(make_package_dep_spec().package(QualifiedPackageName("sys-apps/paludis"))),
qo_order_by_version));
@@ -273,7 +273,7 @@ int main(int argc, char * argv[])
for (PackageID::MetadataConstIterator k((*i)->begin_metadata()), k_end((*i)->end_metadata()) ;
k != k_end ; ++k)
{
- /* Display it. Note that PackageID::MetadataConstIterator returns a tr1::shared_ptr
+ /* Display it. Note that PackageID::MetadataConstIterator returns a std::tr1::shared_ptr
* to a key, so we dereference twice (or we could have used IndirectIterator). */
show_key(**k);
cout << endl;
@@ -294,7 +294,7 @@ int main(int argc, char * argv[])
k != k_end ; ++k)
{
/* Display it. Repository::MetadataConstIterator also returns a
- * tr1::shared_ptr to the key. */
+ * std::tr1::shared_ptr to the key. */
show_key(**k);
cout << endl;
}
diff --git a/doc/api/cplusplus/examples/example_package_database.cc b/doc/api/cplusplus/examples/example_package_database.cc
index 3c94b46..0aaaba8 100644
--- a/doc/api/cplusplus/examples/example_package_database.cc
+++ b/doc/api/cplusplus/examples/example_package_database.cc
@@ -37,14 +37,14 @@ int main(int argc, char * argv[])
"example_package_database", "EXAMPLE_PACKAGE_DATABASE_OPTIONS", "EXAMPLE_PACKAGE_DATABASE_CMDLINE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* The most useful PackageDatabase method is PackageDatabase::query,
* which is covered in other examples. But there are others: */
if (env->package_database()->has_repository_named(RepositoryName("gentoo")))
{
- tr1::shared_ptr<const Repository> repo(env->package_database()->fetch_repository(RepositoryName("gentoo")));
+ std::tr1::shared_ptr<const Repository> repo(env->package_database()->fetch_repository(RepositoryName("gentoo")));
cout << "Repository 'gentoo' exists, and has format '" <<
(repo->format_key() ? repo->format_key()->value() : "") << "'" << endl;
}
diff --git a/doc/api/cplusplus/examples/example_package_id.cc b/doc/api/cplusplus/examples/example_package_id.cc
index 71b5a94..0ab51fc 100644
--- a/doc/api/cplusplus/examples/example_package_id.cc
+++ b/doc/api/cplusplus/examples/example_package_id.cc
@@ -42,11 +42,11 @@ int main(int argc, char * argv[])
"example_package_id", "EXAMPLE_PACKAGE_ID_OPTIONS", "EXAMPLE_PACKAGE_ID_CMDLINE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* Fetch package IDs for 'sys-apps/paludis'. */
- tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
+ std::tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
query::Matches(make_package_dep_spec().package(QualifiedPackageName("sys-apps/paludis"))),
qo_order_by_version));
diff --git a/doc/api/cplusplus/examples/example_query.cc b/doc/api/cplusplus/examples/example_query.cc
index 9e96ed7..3640c5f 100644
--- a/doc/api/cplusplus/examples/example_query.cc
+++ b/doc/api/cplusplus/examples/example_query.cc
@@ -29,14 +29,14 @@ using std::endl;
namespace
{
/* Run a particular query, and show its results. */
- void show_query(const tr1::shared_ptr<const Environment> & env, const Query & query)
+ void show_query(const std::tr1::shared_ptr<const Environment> & env, const Query & query)
{
/* Queries support a crude form of stringification. */
cout << query << ":" << endl;
/* Usually the only thing clients will do with a Query object is pass it
* to PackageDatabase::query. */
- tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(query, qo_order_by_version));
+ std::tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(query, qo_order_by_version));
/* Show the results */
if (! ids->empty())
@@ -56,7 +56,7 @@ int main(int argc, char * argv[])
"example_action", "EXAMPLE_ACTION_OPTIONS", "EXAMPLE_ACTION_CMDLINE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* Make some queries, and display what they give. */
diff --git a/doc/api/cplusplus/examples/example_query_delegate.cc b/doc/api/cplusplus/examples/example_query_delegate.cc
index 139019b..f325dba 100644
--- a/doc/api/cplusplus/examples/example_query_delegate.cc
+++ b/doc/api/cplusplus/examples/example_query_delegate.cc
@@ -42,12 +42,12 @@ namespace
{
}
- tr1::shared_ptr<PackageIDSequence>
+ std::tr1::shared_ptr<PackageIDSequence>
ids(const Environment & e,
- tr1::shared_ptr<const RepositoryNameSequence> repos,
- tr1::shared_ptr<const QualifiedPackageNameSet> pkgs) const
+ std::tr1::shared_ptr<const RepositoryNameSequence> repos,
+ std::tr1::shared_ptr<const QualifiedPackageNameSet> pkgs) const
{
- tr1::shared_ptr<PackageIDSequence> result(new PackageIDSequence);
+ std::tr1::shared_ptr<PackageIDSequence> result(new PackageIDSequence);
/* We have to iterate over every repository by hand... */
for (RepositoryNameSequence::ConstIterator r(repos->begin()), r_end(repos->end()) ;
@@ -55,12 +55,12 @@ namespace
{
/* And from each repository, we iterate over packages by
* hand... */
- tr1::shared_ptr<const Repository> repo(e.package_database()->fetch_repository(*r));
+ std::tr1::shared_ptr<const Repository> repo(e.package_database()->fetch_repository(*r));
for (QualifiedPackageNameSet::ConstIterator p(pkgs->begin()), p_end(pkgs->end()) ;
p != p_end ; ++p)
{
/* And finally, IDs by hand... */
- tr1::shared_ptr<const PackageIDSequence> i(repo->package_ids(*p));
+ std::tr1::shared_ptr<const PackageIDSequence> i(repo->package_ids(*p));
for (PackageIDSequence::ConstIterator v(i->begin()), v_end(i->end()) ;
v != v_end ; ++v)
{
@@ -89,20 +89,20 @@ namespace
{
public:
DescriptionContains(const std::string & pattern) :
- Query(tr1::shared_ptr<QueryDelegate>(new DescriptionContainsDelegate(pattern)))
+ Query(std::tr1::shared_ptr<QueryDelegate>(new DescriptionContainsDelegate(pattern)))
{
}
};
/* Run a particular query, and show its results. */
- void show_query(const tr1::shared_ptr<const Environment> & env, const Query & query)
+ void show_query(const std::tr1::shared_ptr<const Environment> & env, const Query & query)
{
/* Queries support a crude form of stringification. */
cout << query << ":" << endl;
/* Usually the only thing clients will do with a Query object is pass it
* to PackageDatabase::query. */
- tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(query, qo_order_by_version));
+ std::tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(query, qo_order_by_version));
/* Show the results */
if (! ids->empty())
@@ -122,7 +122,7 @@ int main(int argc, char * argv[])
"example_query_delegate", "EXAMPLE_QUERY_DELEGATE", "EXAMPLE_QUERY_DELEGATE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* Make some queries, and display what they give. */
diff --git a/doc/api/cplusplus/examples/example_repository.cc b/doc/api/cplusplus/examples/example_repository.cc
index 75a5a41..4114218 100644
--- a/doc/api/cplusplus/examples/example_repository.cc
+++ b/doc/api/cplusplus/examples/example_repository.cc
@@ -35,7 +35,7 @@ int main(int argc, char * argv[])
"example_environment", "EXAMPLE_ENVIRONMENT_OPTIONS", "EXAMPLE_ENVIRONMENT_CMDLINE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* For each repository... */
@@ -61,9 +61,9 @@ int main(int argc, char * argv[])
* packages, IDs and so on. These methods are used by
* PackageDatabase::query, but are also sometimes of direct use to
* clients. */
- tr1::shared_ptr<const CategoryNamePartSet> cats((*r)->category_names());
+ std::tr1::shared_ptr<const CategoryNamePartSet> cats((*r)->category_names());
cout << left << setw(30) << " Number of categories:" << " " << cats->size() << endl;
- tr1::shared_ptr<const PackageIDSequence> ids((*r)->package_ids(QualifiedPackageName("sys-apps/paludis")));
+ std::tr1::shared_ptr<const PackageIDSequence> ids((*r)->package_ids(QualifiedPackageName("sys-apps/paludis")));
cout << left << setw(30) << " IDs for sys-apps/paludis:" << " " <<
join(indirect_iterator(ids->begin()), indirect_iterator(ids->end()), " ") << endl;
diff --git a/doc/api/cplusplus/examples/example_stringify_formatter.cc b/doc/api/cplusplus/examples/example_stringify_formatter.cc
index 150de4e..298da78 100644
--- a/doc/api/cplusplus/examples/example_stringify_formatter.cc
+++ b/doc/api/cplusplus/examples/example_stringify_formatter.cc
@@ -34,11 +34,11 @@ int main(int argc, char * argv[])
"example_stringify_formatter", "EXAMPLE_STRINGIFY_FORMATTER_OPTIONS", "EXAMPLE_STRINGIFY_FORMATTER_CMDLINE");
/* We start with an Environment, respecting the user's '--environment' choice. */
- tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
+ std::tr1::shared_ptr<Environment> env(EnvironmentMaker::get_instance()->make_from_spec(
CommandLine::get_instance()->a_environment.argument()));
/* Fetch package IDs for installable 'sys-apps/paludis'. */
- tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
+ std::tr1::shared_ptr<const PackageIDSequence> ids(env->package_database()->query(
query::Matches(make_package_dep_spec().package(QualifiedPackageName("sys-apps/paludis"))) &
query::SupportsAction<InstallAction>(),
qo_order_by_version));
diff --git a/doc/api/cplusplus/examples/example_version_spec.cc b/doc/api/cplusplus/examples/example_version_spec.cc
index 186fd79..9b9fcc8 100644
--- a/doc/api/cplusplus/examples/example_version_spec.cc
+++ b/doc/api/cplusplus/examples/example_version_spec.cc
@@ -56,7 +56,7 @@ int main(int argc, char * argv[])
/* Show the output of various members. Not all of these are of much
* direct use. */
- cout << " " << left << setw(24) << "Hash value:" << " " << "0x" << hex << v->hash_value() << endl;
+ cout << " " << left << setw(24) << "Hash value:" << " " << "0x" << hex << v->hash() << endl;
cout << " " << left << setw(24) << "Remove revision:" << " " << v->remove_revision() << endl;
cout << " " << left << setw(24) << "Revision only:" << " " << v->revision_only() << endl;
cout << " " << left << setw(24) << "Bump:" << " " << v->bump() << endl;
diff --git a/doc/configuration/hooks.html.part b/doc/configuration/hooks.html.part
index 63aa7be..23c3467 100644
--- a/doc/configuration/hooks.html.part
+++ b/doc/configuration/hooks.html.part
@@ -434,7 +434,7 @@ that performs the action, and optionally one with prototype
<code>void paludis_hook_add_dependencies(const paludis::Environment *, const paludis::Hook &amp;,
paludis::DirectedGraph&lt;std::string, int&gt; &amp;)</code>
if it needs to define ordering dependencies with other hooks. If the hook is to be placed in an <code>auto</code>
-directory, it must also define <code>const paludis::tr1::shared_ptr&lt;const Seqyence&lt;std::string&gt; &gt;
+directory, it must also define <code>const std::tr1::shared_ptr&lt;const Seqyence&lt;std::string&gt; &gt;
paludis_hook_auto_phases(const paludis::Environment *)</code>. All functions are
declared in the header <code>&lt;paludis/hook.hh&gt;</code>, including any necessary
<code>extern</code> or visibility declarations.</p>
diff --git a/misc/make_sr.bash b/misc/make_sr.bash
index 238f11f..f0deb43 100755
--- a/misc/make_sr.bash
+++ b/misc/make_sr.bash
@@ -232,7 +232,7 @@ while read a ; do
else
echo " protected:"
echo " ${want_key_types[${k}]% ->*} raw_${want_keys[${k}]};"
- echo " mutable paludis::tr1::shared_ptr<const ${want_key_types[${k}]#*-> }> cached_${want_keys[${k}]};"
+ echo " mutable paludis::std::tr1::shared_ptr<const ${want_key_types[${k}]#*-> }> cached_${want_keys[${k}]};"
echo
fi
done
@@ -254,7 +254,7 @@ while read a ; do
echo " const ${want_key_types[${k}]%-> *} get_raw_${want_keys[${k}]}() const"
echo " PALUDIS_ATTRIBUTE((warn_unused_result));"
echo
- echo " paludis::tr1::shared_ptr<const ${want_key_types[${k}]#*-> }> ${want_keys[${k}]}() const"
+ echo " paludis::std::tr1::shared_ptr<const ${want_key_types[${k}]#*-> }> ${want_keys[${k}]}() const"
echo " PALUDIS_ATTRIBUTE((warn_unused_result));"
echo
fi
@@ -642,7 +642,7 @@ while read a ; do
echo " return raw_${want_keys[${k}]};"
echo "}"
echo
- echo "paludis::tr1::shared_ptr<const ${want_key_types[${k}]#*-> }>"
+ echo "paludis::std::tr1::shared_ptr<const ${want_key_types[${k}]#*-> }>"
echo "${a}::${want_keys[${k}]}() const"
echo "{"
echo " if (! cached_${want_keys[${k}]})"
diff --git a/paludis/action-fwd.hh b/paludis/action-fwd.hh
index a457b4b..b036427 100644
--- a/paludis/action-fwd.hh
+++ b/paludis/action-fwd.hh
@@ -24,8 +24,8 @@
#include <paludis/util/attributes.hh>
#include <paludis/util/kc-fwd.hh>
#include <paludis/util/keys.hh>
-#include <paludis/util/tr1_memory.hh>
#include <paludis/repository-fwd.hh>
+#include <tr1/memory>
/** \file
* Forward declarations for paludis/action.hh .
@@ -84,7 +84,7 @@ namespace paludis
kc::Field<k::no_config_protect, bool>,
kc::Field<k::debug_build, InstallActionDebugOption>,
kc::Field<k::checks, InstallActionChecksOption>,
- kc::Field<k::destination, tr1::shared_ptr<Repository> >
+ kc::Field<k::destination, std::tr1::shared_ptr<Repository> >
> InstallActionOptions;
/**
diff --git a/paludis/action.cc b/paludis/action.cc
index 719a927..8cede23 100644
--- a/paludis/action.cc
+++ b/paludis/action.cc
@@ -268,7 +268,7 @@ InstallActionError::InstallActionError(const std::string & msg) throw () :
}
FetchActionError::FetchActionError(const std::string & msg,
- const tr1::shared_ptr<const Sequence<FetchActionFailure> > & e) throw () :
+ const std::tr1::shared_ptr<const Sequence<FetchActionFailure> > & e) throw () :
ActionError("Fetch error: " + msg),
_failures(e)
{
@@ -283,7 +283,7 @@ FetchActionError::~FetchActionError() throw ()
{
}
-const tr1::shared_ptr<const Sequence<FetchActionFailure> >
+const std::tr1::shared_ptr<const Sequence<FetchActionFailure> >
FetchActionError::failures() const
{
return _failures;
diff --git a/paludis/action.hh b/paludis/action.hh
index 069beed..af6b3c5 100644
--- a/paludis/action.hh
+++ b/paludis/action.hh
@@ -410,20 +410,20 @@ namespace paludis
public ActionError
{
private:
- const tr1::shared_ptr<const Sequence<FetchActionFailure> > _failures;
+ const std::tr1::shared_ptr<const Sequence<FetchActionFailure> > _failures;
public:
///\name Basic operations
///\{
FetchActionError(const std::string &) throw ();
- FetchActionError(const std::string &, const tr1::shared_ptr<const Sequence<FetchActionFailure> > &) throw ();
+ FetchActionError(const std::string &, const std::tr1::shared_ptr<const Sequence<FetchActionFailure> > &) throw ();
~FetchActionError() throw ();
///\}
/// More information about failed fetches.
- const tr1::shared_ptr<const Sequence<FetchActionFailure> > failures() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ const std::tr1::shared_ptr<const Sequence<FetchActionFailure> > failures() const PALUDIS_ATTRIBUTE((warn_unused_result));
};
/**
diff --git a/paludis/args/dep_list_args_group.cc b/paludis/args/dep_list_args_group.cc
index a92159c..fea4b35 100644
--- a/paludis/args/dep_list_args_group.cc
+++ b/paludis/args/dep_list_args_group.cc
@@ -161,7 +161,7 @@ DepListArgsGroup::~DepListArgsGroup()
void
DepListArgsGroup::populate_dep_list_options(const Environment * env, DepListOptions & options) const
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
if (dl_reinstall.argument() == "never")
options.reinstall = dl_reinstall_never;
@@ -233,8 +233,8 @@ DepListArgsGroup::populate_dep_list_options(const Environment * env, DepListOpti
if (! options.override_masks)
options.override_masks.reset(new DepListOverrideMasksFunctions);
- options.override_masks->push_back(tr1::bind(&override_tilde_keywords, env, _1, _2));
- options.override_masks->push_back(tr1::bind(&override_license, _2));
+ options.override_masks->push_back(std::tr1::bind(&override_tilde_keywords, env, _1, _2));
+ options.override_masks->push_back(std::tr1::bind(&override_license, _2));
if (dl_override_masks.specified())
{
@@ -247,18 +247,18 @@ DepListArgsGroup::populate_dep_list_options(const Environment * env, DepListOpti
a_end(dl_override_masks.end_args()) ; a != a_end ; ++a)
{
if (*a == "tilde-keyword")
- options.override_masks->push_back(tr1::bind(&override_tilde_keywords, env, _1, _2));
+ options.override_masks->push_back(std::tr1::bind(&override_tilde_keywords, env, _1, _2));
else if (*a == "unkeyworded")
- options.override_masks->push_back(tr1::bind(&override_unkeyworded, env, _1, _2));
+ options.override_masks->push_back(std::tr1::bind(&override_unkeyworded, env, _1, _2));
else if (*a == "repository")
- options.override_masks->push_back(tr1::bind(&override_repository_masks, _2));
+ options.override_masks->push_back(std::tr1::bind(&override_repository_masks, _2));
else if (*a == "license")
- options.override_masks->push_back(tr1::bind(&override_license, _2));
+ options.override_masks->push_back(std::tr1::bind(&override_license, _2));
else if (*a == "profile")
{
Log::get_instance()->message("paludis.args.deprecated", ll_warning, lc_no_context) <<
"--dl-override-masks profile is deprecated, use --dl-override-masks repository";
- options.override_masks->push_back(tr1::bind(&override_repository_masks, _2));
+ options.override_masks->push_back(std::tr1::bind(&override_repository_masks, _2));
}
else if (*a == "none")
{
diff --git a/paludis/args/install_args_group.cc b/paludis/args/install_args_group.cc
index 3b42256..05b88f8 100644
--- a/paludis/args/install_args_group.cc
+++ b/paludis/args/install_args_group.cc
@@ -82,19 +82,19 @@ InstallArgsGroup::populate_dep_list_options(const Environment *, DepListOptions
options.dependency_tags = a_show_reasons.argument() == "summary" || a_show_reasons.argument() == "full";
}
-tr1::shared_ptr<const DestinationsSet>
+std::tr1::shared_ptr<const DestinationsSet>
InstallArgsGroup::destinations(Environment * env) const
{
if (a_destinations.specified())
{
Context local_context("When building destinations collection:");
- tr1::shared_ptr<DestinationsSet> d(new DestinationsSet);
+ std::tr1::shared_ptr<DestinationsSet> d(new DestinationsSet);
for (args::StringSetArg::ConstIterator i(a_destinations.begin_args()),
i_end(a_destinations.end_args()) ;
i != i_end ; ++i)
{
- tr1::shared_ptr<Repository> repo(env->package_database()->fetch_repository(
+ std::tr1::shared_ptr<Repository> repo(env->package_database()->fetch_repository(
RepositoryName(*i)));
if ((*repo)[k::destination_interface()])
d->insert(repo);
diff --git a/paludis/args/install_args_group.hh b/paludis/args/install_args_group.hh
index 946dc9f..4689735 100644
--- a/paludis/args/install_args_group.hh
+++ b/paludis/args/install_args_group.hh
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008 Ciaran McCreesh
* Copyright (c) 2007 David Leverton
*
* This file is part of the Paludis package manager. Paludis is free software;
@@ -112,7 +112,7 @@ namespace paludis
/**
* Fetch our specified destinations set.
*/
- tr1::shared_ptr<const DestinationsSet> destinations(Environment *) const;
+ std::tr1::shared_ptr<const DestinationsSet> destinations(Environment *) const;
/**
* Populate an InstallTask from our values.
diff --git a/paludis/args/man.cc b/paludis/args/man.cc
index 69e995d..b6c21d2 100644
--- a/paludis/args/man.cc
+++ b/paludis/args/man.cc
@@ -19,8 +19,8 @@
#include "man.hh"
#include <paludis/util/visitor-impl.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/visitor_cast.hh>
+#include <tr1/functional>
#include <ostream>
#include <sstream>
#include <algorithm>
@@ -95,7 +95,7 @@ namespace
void
paludis::args::generate_doc(DocWriter & dw, const ArgsHandler * const h)
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
dw.heading(h->app_name(), h->man_section(), h->app_synopsis());
@@ -146,7 +146,7 @@ paludis::args::generate_doc(DocWriter & dw, const ArgsHandler * const h)
if (h->begin_notes() != h->end_notes())
{
dw.start_notes();
- std::for_each(h->begin_notes(), h->end_notes(), tr1::bind(&DocWriter::note, &dw, _1));
+ std::for_each(h->begin_notes(), h->end_notes(), std::tr1::bind(&DocWriter::note, &dw, _1));
dw.end_notes();
}
diff --git a/paludis/condition_tracker.cc b/paludis/condition_tracker.cc
index 6d8dc1d..8c838e6 100644
--- a/paludis/condition_tracker.cc
+++ b/paludis/condition_tracker.cc
@@ -24,13 +24,13 @@
#include <paludis/dep_label.hh>
using namespace paludis;
-using namespace tr1::placeholders;
+using namespace std::tr1::placeholders;
ConditionTracker::ConditionTracker(
- tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > conditions) :
+ std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > conditions) :
base(new ConstTreeSequence<DependencySpecTree, AllDepSpec>(
- tr1::shared_ptr<AllDepSpec>(new AllDepSpec))),
- adder(tr1::bind(&ConstTreeSequence<DependencySpecTree, AllDepSpec>::add, base.get(), _1))
+ std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec))),
+ adder(std::tr1::bind(&ConstTreeSequence<DependencySpecTree, AllDepSpec>::add, base.get(), _1))
{
conditions->accept(*this);
}
@@ -40,44 +40,44 @@ ConditionTracker::~ConditionTracker()
}
template <typename T_>
-tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >
+std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >
ConditionTracker::do_add_sequence(const T_ & node)
{
- adder(tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, T_> >(
+ adder(std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, T_> >(
new ConstTreeSequence<DependencySpecTree, T_>(
- tr1::static_pointer_cast<T_>(node.clone()))));
+ std::tr1::static_pointer_cast<T_>(node.clone()))));
return base;
}
template <typename T_>
-tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >
+std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >
ConditionTracker::do_add_leaf(const T_ & node)
{
- adder(tr1::shared_ptr<TreeLeaf<DependencySpecTree, T_> >(
+ adder(std::tr1::shared_ptr<TreeLeaf<DependencySpecTree, T_> >(
new TreeLeaf<DependencySpecTree, T_>(
- tr1::static_pointer_cast<T_>(node.clone()))));
+ std::tr1::static_pointer_cast<T_>(node.clone()))));
return base;
}
-tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >
+std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >
ConditionTracker::add_condition(const AnyDepSpec & any)
{
return do_add_sequence(any);
}
-tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >
+std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >
ConditionTracker::add_condition(const ConditionalDepSpec & use)
{
return do_add_sequence(use);
}
-tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >
+std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >
ConditionTracker::add_condition(const PackageDepSpec & pkg)
{
return do_add_leaf(pkg);
}
-tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >
+std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >
ConditionTracker::add_condition(const BlockDepSpec & block)
{
return do_add_leaf(block);
@@ -89,11 +89,11 @@ ConditionTracker::do_visit_sequence(const T_ & node,
DependencySpecTree::ConstSequenceIterator begin,
DependencySpecTree::ConstSequenceIterator end)
{
- tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, T_> > a(
+ std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, T_> > a(
new ConstTreeSequence<DependencySpecTree, T_>(
- tr1::static_pointer_cast<T_>(node.clone())));
+ std::tr1::static_pointer_cast<T_>(node.clone())));
adder(a);
- adder = tr1::bind(&ConstTreeSequence<DependencySpecTree, T_>::add, a.get(), _1);
+ adder = std::tr1::bind(&ConstTreeSequence<DependencySpecTree, T_>::add, a.get(), _1);
if (begin != end)
{
begin->accept(*this);
diff --git a/paludis/condition_tracker.hh b/paludis/condition_tracker.hh
index 6d7d98c..30a7030 100644
--- a/paludis/condition_tracker.hh
+++ b/paludis/condition_tracker.hh
@@ -20,11 +20,11 @@
#ifndef PALUDIS_GUARD_PALUDIS_CONDITION_TRACKER_HH
#define PALUDIS_GUARD_PALUDIS_CONDITION_TRACKER_HH 1
-#include <paludis/util/tr1_memory.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/visitor.hh>
#include <paludis/dep_tree.hh>
#include <paludis/dep_spec-fwd.hh>
+#include <tr1/memory>
+#include <tr1/functional>
/** \file
* Declarations for ConditionTracker, which is used internally by DepList.
@@ -50,8 +50,8 @@ namespace paludis
public ConstVisitor<DependencySpecTree>::VisitConstSequence<ConditionTracker, AllDepSpec>
{
private:
- tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > base;
- tr1::function<void (tr1::shared_ptr<ConstAcceptInterface<DependencySpecTree> >)> adder;
+ std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > base;
+ std::tr1::function<void (std::tr1::shared_ptr<ConstAcceptInterface<DependencySpecTree> >)> adder;
template <typename T_>
void do_visit_sequence(const T_ &,
@@ -59,15 +59,15 @@ namespace paludis
DependencySpecTree::ConstSequenceIterator);
template <typename T_>
- tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > do_add_sequence(const T_ &);
+ std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > do_add_sequence(const T_ &);
template <typename T_>
- tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > do_add_leaf(const T_ &);
+ std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > do_add_leaf(const T_ &);
public:
///\name Basic operations
///\{
- ConditionTracker(tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >);
+ ConditionTracker(std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >);
virtual ~ConditionTracker();
@@ -76,10 +76,10 @@ namespace paludis
///\name Add a condition
///\{
- tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > add_condition(const AnyDepSpec &);
- tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > add_condition(const ConditionalDepSpec &);
- tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > add_condition(const PackageDepSpec &);
- tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > add_condition(const BlockDepSpec &);
+ std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > add_condition(const AnyDepSpec &);
+ std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > add_condition(const ConditionalDepSpec &);
+ std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > add_condition(const PackageDepSpec &);
+ std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > add_condition(const BlockDepSpec &);
///\}
diff --git a/paludis/contents.cc b/paludis/contents.cc
index 966033a..70a2e1f 100644
--- a/paludis/contents.cc
+++ b/paludis/contents.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -42,7 +42,7 @@ template class Visits<const ContentsFifoEntry>;
template class Visits<const ContentsDevEntry>;
template class Visits<const ContentsMiscEntry>;
-template class WrappedForwardIterator<Contents::ConstIteratorTag, const tr1::shared_ptr<const ContentsEntry> >;
+template class WrappedForwardIterator<Contents::ConstIteratorTag, const std::tr1::shared_ptr<const ContentsEntry> >;
ContentsEntry::ContentsEntry(const std::string & n) :
_name(n)
@@ -101,7 +101,7 @@ namespace paludis
template<>
struct Implementation<Contents>
{
- std::list<tr1::shared_ptr<const ContentsEntry> > c;
+ std::list<std::tr1::shared_ptr<const ContentsEntry> > c;
};
}
@@ -115,7 +115,7 @@ Contents::~Contents()
}
void
-Contents::add(tr1::shared_ptr<const ContentsEntry> c)
+Contents::add(std::tr1::shared_ptr<const ContentsEntry> c)
{
_imp->c.push_back(c);
}
diff --git a/paludis/contents.hh b/paludis/contents.hh
index aa2b040..45bf913 100644
--- a/paludis/contents.hh
+++ b/paludis/contents.hh
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -25,7 +25,7 @@
#include <paludis/util/visitor.hh>
#include <paludis/util/instantiation_policy.hh>
#include <paludis/util/private_implementation_pattern.hh>
-#include <paludis/util/tr1_memory.hh>
+#include <tr1/memory>
#include <string>
@@ -244,13 +244,13 @@ namespace paludis
///\}
/// Add a new entry.
- void add(tr1::shared_ptr<const ContentsEntry> c);
+ void add(std::tr1::shared_ptr<const ContentsEntry> c);
///\name Iterate over our entries
///\{
struct ConstIteratorTag;
- typedef WrappedForwardIterator<ConstIteratorTag, const tr1::shared_ptr<const ContentsEntry> > ConstIterator;
+ typedef WrappedForwardIterator<ConstIteratorTag, const std::tr1::shared_ptr<const ContentsEntry> > ConstIterator;
ConstIterator begin() const
PALUDIS_ATTRIBUTE((warn_unused_result));
diff --git a/paludis/dep_label-fwd.hh b/paludis/dep_label-fwd.hh
index a258f11..0d33665 100644
--- a/paludis/dep_label-fwd.hh
+++ b/paludis/dep_label-fwd.hh
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007 Ciaran McCreesh
+ * Copyright (c) 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -22,7 +22,7 @@
#include <paludis/util/attributes.hh>
#include <paludis/util/sequence-fwd.hh>
-#include <paludis/util/tr1_memory.hh>
+#include <tr1/memory>
#include <iosfwd>
/** \file
@@ -77,7 +77,7 @@ namespace paludis
* \ingroup g_dep_spec
* \since 0.26
*/
- typedef Sequence<tr1::shared_ptr<const DependencyLabel> > DependencyLabelSequence;
+ typedef Sequence<std::tr1::shared_ptr<const DependencyLabel> > DependencyLabelSequence;
/**
* A collection of DependencySystemLabel instances.
@@ -85,7 +85,7 @@ namespace paludis
* \ingroup g_dep_spec
* \since 0.26
*/
- typedef Sequence<tr1::shared_ptr<const DependencySystemLabel> > DependencySystemLabelSequence;
+ typedef Sequence<std::tr1::shared_ptr<const DependencySystemLabel> > DependencySystemLabelSequence;
/**
* A collection of DependencyTypeLabel instances.
@@ -93,7 +93,7 @@ namespace paludis
* \ingroup g_dep_spec
* \since 0.26
*/
- typedef Sequence<tr1::shared_ptr<const DependencyTypeLabel> > DependencyTypeLabelSequence;
+ typedef Sequence<std::tr1::shared_ptr<const DependencyTypeLabel> > DependencyTypeLabelSequence;
/**
* A collection of DependencySuggestLabel instances.
@@ -101,7 +101,7 @@ namespace paludis
* \ingroup g_dep_spec
* \since 0.26
*/
- typedef Sequence<tr1::shared_ptr<const DependencySuggestLabel> > DependencySuggestLabelSequence;
+ typedef Sequence<std::tr1::shared_ptr<const DependencySuggestLabel> > DependencySuggestLabelSequence;
/**
* A collection of DependencyABIsLabel instances.
@@ -109,7 +109,7 @@ namespace paludis
* \ingroup g_dep_spec
* \since 0.26
*/
- typedef Sequence<tr1::shared_ptr<const DependencyABIsLabel> > DependencyABIsLabelSequence;
+ typedef Sequence<std::tr1::shared_ptr<const DependencyABIsLabel> > DependencyABIsLabelSequence;
template <typename T_, typename Category_> struct ConcreteDependencyLabel;
diff --git a/paludis/dep_label.cc b/paludis/dep_label.cc
index 9b90568..cccf54f 100644
--- a/paludis/dep_label.cc
+++ b/paludis/dep_label.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007 Ciaran McCreesh
+ * Copyright (c) 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -28,11 +28,11 @@
using namespace paludis;
-template class Sequence<tr1::shared_ptr<const DependencyLabel> >;
-template class Sequence<tr1::shared_ptr<const DependencySystemLabel> >;
-template class Sequence<tr1::shared_ptr<const DependencyTypeLabel> >;
-template class Sequence<tr1::shared_ptr<const DependencySuggestLabel> >;
-template class Sequence<tr1::shared_ptr<const DependencyABIsLabel> >;
+template class Sequence<std::tr1::shared_ptr<const DependencyLabel> >;
+template class Sequence<std::tr1::shared_ptr<const DependencySystemLabel> >;
+template class Sequence<std::tr1::shared_ptr<const DependencyTypeLabel> >;
+template class Sequence<std::tr1::shared_ptr<const DependencySuggestLabel> >;
+template class Sequence<std::tr1::shared_ptr<const DependencyABIsLabel> >;
std::ostream &
paludis::operator<< (std::ostream & s, const URILabel & l)
@@ -144,10 +144,10 @@ namespace paludis
template <>
struct Implementation<ActiveDependencyLabels>
{
- tr1::shared_ptr<DependencySystemLabelSequence> system_labels;
- tr1::shared_ptr<DependencyTypeLabelSequence> type_labels;
- tr1::shared_ptr<DependencyABIsLabelSequence> abi_labels;
- tr1::shared_ptr<DependencySuggestLabelSequence> suggest_labels;
+ std::tr1::shared_ptr<DependencySystemLabelSequence> system_labels;
+ std::tr1::shared_ptr<DependencyTypeLabelSequence> type_labels;
+ std::tr1::shared_ptr<DependencyABIsLabelSequence> abi_labels;
+ std::tr1::shared_ptr<DependencySuggestLabelSequence> suggest_labels;
};
}
@@ -157,10 +157,10 @@ namespace
ConstVisitor<DependencyLabelVisitorTypes>
{
Implementation<ActiveDependencyLabels> & _imp;
- const tr1::shared_ptr<const DependencyLabel> _l;
+ const std::tr1::shared_ptr<const DependencyLabel> _l;
LabelsPopulator(Implementation<ActiveDependencyLabels> & i,
- const tr1::shared_ptr<const DependencyLabel> & l) :
+ const std::tr1::shared_ptr<const DependencyLabel> & l) :
_imp(i),
_l(l)
{
@@ -170,28 +170,28 @@ namespace
{
if (! _imp.suggest_labels)
_imp.suggest_labels.reset(new DependencySuggestLabelSequence);
- _imp.suggest_labels->push_back(tr1::static_pointer_cast<const DependencySuggestLabel>(_l));
+ _imp.suggest_labels->push_back(std::tr1::static_pointer_cast<const DependencySuggestLabel>(_l));
}
void visit(const DependencySystemLabel &)
{
if (! _imp.system_labels)
_imp.system_labels.reset(new DependencySystemLabelSequence);
- _imp.system_labels->push_back(tr1::static_pointer_cast<const DependencySystemLabel>(_l));
+ _imp.system_labels->push_back(std::tr1::static_pointer_cast<const DependencySystemLabel>(_l));
}
void visit(const DependencyABIsLabel &)
{
if (! _imp.abi_labels)
_imp.abi_labels.reset(new DependencyABIsLabelSequence);
- _imp.abi_labels->push_back(tr1::static_pointer_cast<const DependencyABIsLabel>(_l));
+ _imp.abi_labels->push_back(std::tr1::static_pointer_cast<const DependencyABIsLabel>(_l));
}
void visit(const DependencyTypeLabel &)
{
if (! _imp.type_labels)
_imp.type_labels.reset(new DependencyTypeLabelSequence);
- _imp.type_labels->push_back(tr1::static_pointer_cast<const DependencyTypeLabel>(_l));
+ _imp.type_labels->push_back(std::tr1::static_pointer_cast<const DependencyTypeLabel>(_l));
}
};
}
@@ -288,25 +288,25 @@ ActiveDependencyLabels::~ActiveDependencyLabels()
{
}
-const tr1::shared_ptr<const DependencySystemLabelSequence>
+const std::tr1::shared_ptr<const DependencySystemLabelSequence>
ActiveDependencyLabels::system_labels() const
{
return _imp->system_labels;
}
-const tr1::shared_ptr<const DependencyTypeLabelSequence>
+const std::tr1::shared_ptr<const DependencyTypeLabelSequence>
ActiveDependencyLabels::type_labels() const
{
return _imp->type_labels;
}
-const tr1::shared_ptr<const DependencyABIsLabelSequence>
+const std::tr1::shared_ptr<const DependencyABIsLabelSequence>
ActiveDependencyLabels::abi_labels() const
{
return _imp->abi_labels;
}
-const tr1::shared_ptr<const DependencySuggestLabelSequence>
+const std::tr1::shared_ptr<const DependencySuggestLabelSequence>
ActiveDependencyLabels::suggest_labels() const
{
return _imp->suggest_labels;
diff --git a/paludis/dep_label.hh b/paludis/dep_label.hh
index 478df9c..bc69624 100644
--- a/paludis/dep_label.hh
+++ b/paludis/dep_label.hh
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007 Ciaran McCreesh
+ * Copyright (c) 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -364,10 +364,10 @@ namespace paludis
///\name Current label selections
///\{
- const tr1::shared_ptr<const DependencySystemLabelSequence> system_labels() const PALUDIS_ATTRIBUTE((warn_unused_result));
- const tr1::shared_ptr<const DependencyTypeLabelSequence> type_labels() const PALUDIS_ATTRIBUTE((warn_unused_result));
- const tr1::shared_ptr<const DependencyABIsLabelSequence> abi_labels() const PALUDIS_ATTRIBUTE((warn_unused_result));
- const tr1::shared_ptr<const DependencySuggestLabelSequence> suggest_labels() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ const std::tr1::shared_ptr<const DependencySystemLabelSequence> system_labels() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ const std::tr1::shared_ptr<const DependencyTypeLabelSequence> type_labels() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ const std::tr1::shared_ptr<const DependencyABIsLabelSequence> abi_labels() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ const std::tr1::shared_ptr<const DependencySuggestLabelSequence> suggest_labels() const PALUDIS_ATTRIBUTE((warn_unused_result));
///\}
};
diff --git a/paludis/dep_list-fwd.hh b/paludis/dep_list-fwd.hh
index 9c16b5f..90550de 100644
--- a/paludis/dep_list-fwd.hh
+++ b/paludis/dep_list-fwd.hh
@@ -20,7 +20,6 @@
#ifndef PALUDIS_GUARD_PALUDIS_DEP_LIST_FWD_HH
#define PALUDIS_GUARD_PALUDIS_DEP_LIST_FWD_HH 1
-#include <paludis/util/tr1_memory.hh>
#include <paludis/repository-fwd.hh>
#include <paludis/dep_tree.hh>
#include <paludis/package_id-fwd.hh>
diff --git a/paludis/dep_list.cc b/paludis/dep_list.cc
index 5af2688..1222613 100644
--- a/paludis/dep_list.cc
+++ b/paludis/dep_list.cc
@@ -30,7 +30,6 @@
#include <paludis/action.hh>
#include <paludis/dep_spec_flattener.hh>
#include <paludis/distribution.hh>
-#include <paludis/hashed_containers.hh>
#include <paludis/match_package.hh>
#include <paludis/metadata_key.hh>
#include <paludis/query.hh>
@@ -48,22 +47,24 @@
#include <paludis/util/sequence.hh>
#include <paludis/util/stringify.hh>
#include <paludis/util/tokeniser.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/visitor-impl.hh>
#include <paludis/util/wrapped_forward_iterator-impl.hh>
#include <paludis/util/kc.hh>
+#include <paludis/util/hashes.hh>
#include <algorithm>
#include <functional>
#include <vector>
#include <list>
#include <set>
+#include <tr1/functional>
+#include <tr1/unordered_map>
using namespace paludis;
-typedef std::list<tr1::shared_ptr<ActiveDependencyLabels> > LabelsStack;
+typedef std::list<std::tr1::shared_ptr<ActiveDependencyLabels> > LabelsStack;
-template class Sequence<tr1::function<bool (const PackageID &, const Mask &)> >;
+template class Sequence<std::tr1::function<bool (const PackageID &, const Mask &)> >;
template class WrappedForwardIterator<DepList::IteratorTag, DepListEntry>;
template class WrappedForwardIterator<DepList::ConstIteratorTag, const DepListEntry>;
@@ -96,13 +97,13 @@ DepListOptions::DepListOptions() :
namespace paludis
{
typedef std::list<DepListEntry> MergeList;
- typedef MakeHashedMultiMap<QualifiedPackageName, MergeList::iterator>::Type MergeListIndex;
+ typedef std::tr1::unordered_multimap<QualifiedPackageName, MergeList::iterator, Hash<QualifiedPackageName> > MergeListIndex;
template<>
struct Implementation<DepList>
{
const Environment * const env;
- tr1::shared_ptr<DepListOptions> opts;
+ std::tr1::shared_ptr<DepListOptions> opts;
MergeList merge_list;
MergeList::const_iterator current_merge_list_entry;
@@ -117,11 +118,11 @@ namespace paludis
LabelsStack labels;
- const tr1::shared_ptr<const PackageID> current_package_id() const
+ const std::tr1::shared_ptr<const PackageID> current_package_id() const
{
if (current_merge_list_entry != merge_list.end())
return current_merge_list_entry->package_id;
- return tr1::shared_ptr<const PackageID>();
+ return std::tr1::shared_ptr<const PackageID>();
}
Implementation(const Environment * const e, const DepListOptions & o) :
@@ -170,7 +171,7 @@ namespace
/* see EffSTL 9 for why this is so painful */
if (e.tags->empty())
return;
- tr1::shared_ptr<DepListEntryTags> t(new DepListEntryTags);
+ std::tr1::shared_ptr<DepListEntryTags> t(new DepListEntryTags);
GenerationGreaterThan pred(g);
for (DepListEntryTags::ConstIterator i(e.tags->begin()), i_end(e.tags->end()) ;
i != i_end ; ++i)
@@ -290,16 +291,16 @@ struct DepList::AddVisitor :
ConstVisitor<DependencySpecTree>
{
DepList * const d;
- tr1::shared_ptr<const DestinationsSet> destinations;
- tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > conditions;
+ std::tr1::shared_ptr<const DestinationsSet> destinations;
+ std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > conditions;
std::set<SetName> recursing_sets;
const bool only_if_not_suggested_label;
- AddVisitor(DepList * const dd, bool l, tr1::shared_ptr<const DestinationsSet> ddd,
- tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > c =
- (tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >(
+ AddVisitor(DepList * const dd, bool l, std::tr1::shared_ptr<const DestinationsSet> ddd,
+ std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > c =
+ (std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >(
new ConstTreeSequence<DependencySpecTree, AllDepSpec>(
- tr1::shared_ptr<AllDepSpec>(new AllDepSpec))))) :
+ std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec))))) :
d(dd),
destinations(ddd),
conditions(c),
@@ -377,12 +378,12 @@ DepList::AddVisitor::visit_leaf(const PackageDepSpec & a)
}
}
- Save<tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > > save_c(
+ Save<std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > > save_c(
&conditions, d->_imp->opts->dependency_tags ? ConditionTracker(conditions).add_condition(a) : conditions);
/* find already installed things */
// TODO: check destinations
- tr1::shared_ptr<const PackageIDSequence> already_installed(d->_imp->env->package_database()->query(
+ std::tr1::shared_ptr<const PackageIDSequence> already_installed(d->_imp->env->package_database()->query(
query::SupportsAction<InstalledAction>() &
query::Matches(a),
qo_order_by_version));
@@ -408,7 +409,7 @@ DepList::AddVisitor::visit_leaf(const PackageDepSpec & a)
if (d->_imp->opts->dependency_tags && d->_imp->current_package_id())
existing_merge_list_entry->tags->insert(DepTagEntry::create()
- .tag(tr1::shared_ptr<DepTag>(new DependencyDepTag(d->_imp->current_package_id(), a, conditions)))
+ .tag(std::tr1::shared_ptr<DepTag>(new DependencyDepTag(d->_imp->current_package_id(), a, conditions)))
.generation(d->_imp->merge_list_generation));
/* add an appropriate destination */
@@ -439,8 +440,8 @@ DepList::AddVisitor::visit_leaf(const PackageDepSpec & a)
}
/* find installable candidates, and find the best visible candidate */
- tr1::shared_ptr<const PackageID> best_visible_candidate;
- tr1::shared_ptr<const PackageIDSequence> installable_candidates(
+ std::tr1::shared_ptr<const PackageID> best_visible_candidate;
+ std::tr1::shared_ptr<const PackageIDSequence> installable_candidates(
d->_imp->env->package_database()->query(
query::MaybeSupportsAction<InstallAction>() &
query::Matches(a),
@@ -542,7 +543,7 @@ DepList::AddVisitor::visit_leaf(const PackageDepSpec & a)
if (! a.additional_requirements_ptr())
throw AllMaskedError(a);
- tr1::shared_ptr<const PackageIDSequence> match_except_reqs(d->_imp->env->package_database()->query(
+ std::tr1::shared_ptr<const PackageIDSequence> match_except_reqs(d->_imp->env->package_database()->query(
query::Matches(*a.without_additional_requirements()), qo_whatever));
for (PackageIDSequence::ConstIterator i(match_except_reqs->begin()),
@@ -561,7 +562,7 @@ DepList::AddVisitor::visit_leaf(const PackageDepSpec & a)
}
}
- tr1::shared_ptr<PackageIDSequence> already_installed_in_same_slot(new PackageIDSequence);
+ std::tr1::shared_ptr<PackageIDSequence> already_installed_in_same_slot(new PackageIDSequence);
for (PackageIDSequence::ConstIterator aa(already_installed->begin()),
aa_end(already_installed->end()) ; aa != aa_end ; ++aa)
if ((*aa)->slot() == best_visible_candidate->slot())
@@ -616,7 +617,7 @@ DepList::AddVisitor::visit_leaf(const PackageDepSpec & a)
case dl_downgrade_error:
case dl_downgrade_warning:
{
- tr1::shared_ptr<const PackageIDSequence> are_we_downgrading(
+ std::tr1::shared_ptr<const PackageIDSequence> are_we_downgrading(
d->_imp->env->package_database()->query(
query::SupportsAction<InstalledAction>() &
query::Matches(make_package_dep_spec()
@@ -652,7 +653,7 @@ DepList::AddVisitor::visit_leaf(const NamedSetDepSpec & a)
{
Context context("When adding NamedSetDepSpec '" + stringify(a) + "':");
- tr1::shared_ptr<const SetSpecTree::ConstItem> set(d->_imp->env->set(a.name()));
+ std::tr1::shared_ptr<const SetSpecTree::ConstItem> set(d->_imp->env->set(a.name()));
if (! set)
throw NoSuchSetError(stringify(a.name()));
@@ -674,7 +675,7 @@ DepList::AddVisitor::visit_sequence(const AllDepSpec &,
DependencySpecTree::ConstSequenceIterator end)
{
d->_imp->labels.push_front(make_shared_ptr(new ActiveDependencyLabels(**d->_imp->labels.begin())));
- RunOnDestruction restore_labels(tr1::bind(tr1::mem_fn(&LabelsStack::pop_front), &d->_imp->labels));
+ RunOnDestruction restore_labels(std::tr1::bind(std::tr1::mem_fn(&LabelsStack::pop_front), &d->_imp->labels));
std::for_each(cur, end, accept_visitor(*this));
}
@@ -684,13 +685,13 @@ DepList::AddVisitor::visit_sequence(const ConditionalDepSpec & a,
DependencySpecTree::ConstSequenceIterator cur,
DependencySpecTree::ConstSequenceIterator end)
{
- Save<tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > > save_c(
+ Save<std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > > save_c(
&conditions, d->_imp->opts->dependency_tags ? ConditionTracker(conditions).add_condition(a) : conditions);
if (d->_imp->opts->use == dl_use_deps_standard)
{
d->_imp->labels.push_front(make_shared_ptr(new ActiveDependencyLabels(**d->_imp->labels.begin())));
- RunOnDestruction restore_labels(tr1::bind(tr1::mem_fn(&LabelsStack::pop_front), &d->_imp->labels));
+ RunOnDestruction restore_labels(std::tr1::bind(std::tr1::mem_fn(&LabelsStack::pop_front), &d->_imp->labels));
if (a.condition_met())
std::for_each(cur, end, accept_visitor(*this));
@@ -707,10 +708,10 @@ DepList::AddVisitor::visit_sequence(const AnyDepSpec & a,
DependencySpecTree::ConstSequenceIterator cur,
DependencySpecTree::ConstSequenceIterator end)
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
d->_imp->labels.push_front(make_shared_ptr(new ActiveDependencyLabels(**d->_imp->labels.begin())));
- RunOnDestruction restore_labels(tr1::bind(tr1::mem_fn(&LabelsStack::pop_front), &d->_imp->labels));
+ RunOnDestruction restore_labels(std::tr1::bind(std::tr1::mem_fn(&LabelsStack::pop_front), &d->_imp->labels));
/* annoying requirement: || ( foo? ( ... ) ) resolves to empty if !foo. */
if (end == std::find_if(cur, end, &is_viable_any_child))
@@ -719,7 +720,7 @@ DepList::AddVisitor::visit_sequence(const AnyDepSpec & a,
{
RangeRewriter r;
std::for_each(cur, end, accept_visitor(r));
- tr1::shared_ptr<PackageDepSpec> rewritten_spec(r.spec());
+ std::tr1::shared_ptr<PackageDepSpec> rewritten_spec(r.spec());
if (rewritten_spec)
{
TreeLeaf<DependencySpecTree, PackageDepSpec> rr(r.spec());
@@ -728,7 +729,7 @@ DepList::AddVisitor::visit_sequence(const AnyDepSpec & a,
}
}
- Save<tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > > save_c(
+ Save<std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > > save_c(
&conditions, d->_imp->opts->dependency_tags ? ConditionTracker(conditions).add_condition(a) : conditions);
/* see if any of our children is already installed. if any is, add it so that
@@ -761,8 +762,8 @@ DepList::AddVisitor::visit_sequence(const AnyDepSpec & a,
Save<bool> save_t(&d->_imp->throw_on_blocker,
dl_blocks_discard_completely != d->_imp->opts->blocks);
- Save<tr1::shared_ptr<DepListOverrideMasksFunctions> > save_o(&d->_imp->opts->override_masks,
- tr1::shared_ptr<DepListOverrideMasksFunctions>());
+ Save<std::tr1::shared_ptr<DepListOverrideMasksFunctions> > save_o(&d->_imp->opts->override_masks,
+ std::tr1::shared_ptr<DepListOverrideMasksFunctions>());
d->add_not_top_level(only_if_not_suggested_label, *c, destinations, conditions);
return;
}
@@ -783,8 +784,8 @@ DepList::AddVisitor::visit_sequence(const AnyDepSpec & a,
Save<bool> save_t(&d->_imp->throw_on_blocker,
dl_blocks_discard_completely != d->_imp->opts->blocks);
- Save<tr1::shared_ptr<DepListOverrideMasksFunctions> > save_o(&d->_imp->opts->override_masks,
- tr1::shared_ptr<DepListOverrideMasksFunctions>());
+ Save<std::tr1::shared_ptr<DepListOverrideMasksFunctions> > save_o(&d->_imp->opts->override_masks,
+ std::tr1::shared_ptr<DepListOverrideMasksFunctions>());
d->add_not_top_level(only_if_not_suggested_label, *c, destinations, conditions);
return;
}
@@ -818,12 +819,12 @@ DepList::AddVisitor::visit_leaf(const BlockDepSpec & a)
Context context("When checking BlockDepSpec '!" + stringify(*a.blocked_spec()) + "':");
- Save<tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > > save_c(
+ Save<std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > > save_c(
&conditions, d->_imp->opts->dependency_tags ? ConditionTracker(conditions).add_condition(a) : conditions);
bool check_whole_list(false);
std::list<MergeList::const_iterator> will_be_installed;
- tr1::shared_ptr<const PackageIDSequence> already_installed;
+ std::tr1::shared_ptr<const PackageIDSequence> already_installed;
if (a.blocked_spec()->package_ptr())
{
@@ -987,13 +988,13 @@ DepList::~DepList()
{
}
-tr1::shared_ptr<DepListOptions>
+std::tr1::shared_ptr<DepListOptions>
DepList::options()
{
return _imp->opts;
}
-const tr1::shared_ptr<const DepListOptions>
+const std::tr1::shared_ptr<const DepListOptions>
DepList::options() const
{
return _imp->opts;
@@ -1008,18 +1009,18 @@ DepList::clear()
void
DepList::add_in_role(const bool only_if_not_suggested_label, DependencySpecTree::ConstItem & spec, const std::string & role,
- tr1::shared_ptr<const DestinationsSet> destinations)
+ std::tr1::shared_ptr<const DestinationsSet> destinations)
{
Context context("When adding " + role + (only_if_not_suggested_label ? " unless under a suggested label" : "") + ":");
add_not_top_level(only_if_not_suggested_label, spec, destinations,
- tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >(
- new ConstTreeSequence<DependencySpecTree, AllDepSpec>(tr1::shared_ptr<AllDepSpec>(new AllDepSpec))));
+ std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> >(
+ new ConstTreeSequence<DependencySpecTree, AllDepSpec>(std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec))));
}
void
DepList::add_not_top_level(const bool only_if_not_suggested_label,
- DependencySpecTree::ConstItem & spec, tr1::shared_ptr<const DestinationsSet> destinations,
- tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > conditions)
+ DependencySpecTree::ConstItem & spec, std::tr1::shared_ptr<const DestinationsSet> destinations,
+ std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > conditions)
{
DepListTransaction transaction(_imp->merge_list, _imp->merge_list_index, _imp->merge_list_generation);
@@ -1029,7 +1030,7 @@ DepList::add_not_top_level(const bool only_if_not_suggested_label,
}
void
-DepList::add(SetSpecTree::ConstItem & spec, tr1::shared_ptr<const DestinationsSet> destinations)
+DepList::add(SetSpecTree::ConstItem & spec, std::tr1::shared_ptr<const DestinationsSet> destinations)
{
DepListTransaction transaction(_imp->merge_list, _imp->merge_list_index, _imp->merge_list_generation);
@@ -1042,16 +1043,16 @@ DepList::add(SetSpecTree::ConstItem & spec, tr1::shared_ptr<const DestinationsSe
}
void
-DepList::add(const PackageDepSpec & spec, tr1::shared_ptr<const DestinationsSet> destinations)
+DepList::add(const PackageDepSpec & spec, std::tr1::shared_ptr<const DestinationsSet> destinations)
{
- TreeLeaf<SetSpecTree, PackageDepSpec> l(tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(spec)));
+ TreeLeaf<SetSpecTree, PackageDepSpec> l(std::tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(spec)));
add(l, destinations);
}
void
-DepList::add_package(const tr1::shared_ptr<const PackageID> & p, tr1::shared_ptr<const DepTag> tag,
- const PackageDepSpec & pds, tr1::shared_ptr<DependencySpecTree::ConstItem> conditions,
- tr1::shared_ptr<const DestinationsSet> destinations)
+DepList::add_package(const std::tr1::shared_ptr<const PackageID> & p, std::tr1::shared_ptr<const DepTag> tag,
+ const PackageDepSpec & pds, std::tr1::shared_ptr<DependencySpecTree::ConstItem> conditions,
+ std::tr1::shared_ptr<const DestinationsSet> destinations)
{
Context context("When adding package '" + stringify(*p) + "':");
@@ -1066,12 +1067,12 @@ DepList::add_package(const tr1::shared_ptr<const PackageID> & p, tr1::shared_ptr
.package_id(p)
.generation(_imp->merge_list_generation)
.state(dle_no_deps)
- .tags(tr1::shared_ptr<DepListEntryTags>(new DepListEntryTags))
- .destination(p->virtual_for_key() ? tr1::shared_ptr<Repository>() : find_destination(*p, destinations))
+ .tags(std::tr1::shared_ptr<DepListEntryTags>(new DepListEntryTags))
+ .destination(p->virtual_for_key() ? std::tr1::shared_ptr<Repository>() : find_destination(*p, destinations))
.associated_entry(0)
.handled(p->virtual_for_key() ?
- tr1::shared_ptr<DepListEntryHandled>(new DepListEntryNoHandlingRequired) :
- tr1::shared_ptr<DepListEntryHandled>(new DepListEntryUnhandled))
+ std::tr1::shared_ptr<DepListEntryHandled>(new DepListEntryNoHandlingRequired) :
+ std::tr1::shared_ptr<DepListEntryHandled>(new DepListEntryUnhandled))
.kind(p->virtual_for_key() ? dlk_virtual : dlk_package))),
our_merge_entry_post_position(our_merge_entry_position);
@@ -1084,7 +1085,7 @@ DepList::add_package(const tr1::shared_ptr<const PackageID> & p, tr1::shared_ptr
if (_imp->opts->dependency_tags && _imp->current_package_id())
our_merge_entry_position->tags->insert(DepTagEntry::create()
- .tag(tr1::shared_ptr<DepTag>(new DependencyDepTag(_imp->current_package_id(), pds, conditions)))
+ .tag(std::tr1::shared_ptr<DepTag>(new DependencyDepTag(_imp->current_package_id(), pds, conditions)))
.generation(_imp->merge_list_generation));
Save<MergeList::const_iterator> save_current_merge_list_entry(&_imp->current_merge_list_entry,
@@ -1105,7 +1106,7 @@ DepList::add_package(const tr1::shared_ptr<const PackageID> & p, tr1::shared_ptr
for (DepSpecFlattener<ProvideSpecTree, PackageDepSpec>::ConstIterator i(f.begin()), i_end(f.end()) ; i != i_end ; ++i)
{
- tr1::shared_ptr<PackageDepSpec> pp(new PackageDepSpec(make_package_dep_spec()
+ std::tr1::shared_ptr<PackageDepSpec> pp(new PackageDepSpec(make_package_dep_spec()
.package(*(*i)->package_ptr())
.version_requirement(VersionRequirement(vo_equal, p->version()))));
@@ -1128,8 +1129,8 @@ DepList::add_package(const tr1::shared_ptr<const PackageID> & p, tr1::shared_ptr
QualifiedPackageName((*i)->text()), p))
.generation(_imp->merge_list_generation)
.state(dle_has_all_deps)
- .tags(tr1::shared_ptr<DepListEntryTags>(new DepListEntryTags))
- .destination(tr1::shared_ptr<Repository>())
+ .tags(std::tr1::shared_ptr<DepListEntryTags>(new DepListEntryTags))
+ .destination(std::tr1::shared_ptr<Repository>())
.associated_entry(&*_imp->current_merge_list_entry)
.handled(make_shared_ptr(new DepListEntryNoHandlingRequired))
.kind(dlk_provided)));
@@ -1187,8 +1188,8 @@ DepList::add_package(const tr1::shared_ptr<const PackageID> & p, tr1::shared_ptr
}
void
-DepList::add_error_package(const tr1::shared_ptr<const PackageID> & p, const DepListEntryKind kind,
- const PackageDepSpec & pds, tr1::shared_ptr<DependencySpecTree::ConstItem> conditions)
+DepList::add_error_package(const std::tr1::shared_ptr<const PackageID> & p, const DepListEntryKind kind,
+ const PackageDepSpec & pds, std::tr1::shared_ptr<DependencySpecTree::ConstItem> conditions)
{
std::pair<MergeListIndex::iterator, MergeListIndex::const_iterator> pp(
_imp->merge_list_index.equal_range(p->name()));
@@ -1199,7 +1200,7 @@ DepList::add_error_package(const tr1::shared_ptr<const PackageID> & p, const Dep
{
if (_imp->current_package_id())
pp.first->second->tags->insert(DepTagEntry::create()
- .tag(tr1::shared_ptr<DepTag>(new DependencyDepTag(_imp->current_package_id(), pds, conditions)))
+ .tag(std::tr1::shared_ptr<DepTag>(new DependencyDepTag(_imp->current_package_id(), pds, conditions)))
.generation(_imp->merge_list_generation));
return;
}
@@ -1211,24 +1212,24 @@ DepList::add_error_package(const tr1::shared_ptr<const PackageID> & p, const Dep
.package_id(p)
.generation(_imp->merge_list_generation)
.state(dle_has_all_deps)
- .tags(tr1::shared_ptr<DepListEntryTags>(new DepListEntryTags))
- .destination(tr1::shared_ptr<Repository>())
+ .tags(std::tr1::shared_ptr<DepListEntryTags>(new DepListEntryTags))
+ .destination(std::tr1::shared_ptr<Repository>())
.associated_entry(&*_imp->current_merge_list_entry)
.handled(make_shared_ptr(new DepListEntryNoHandlingRequired))
.kind(kind)));
if (_imp->current_package_id())
our_merge_entry_position->tags->insert(DepTagEntry::create()
- .tag(tr1::shared_ptr<DepTag>(new DependencyDepTag(_imp->current_package_id(), pds, conditions)))
+ .tag(std::tr1::shared_ptr<DepTag>(new DependencyDepTag(_imp->current_package_id(), pds, conditions)))
.generation(_imp->merge_list_generation));
_imp->merge_list_index.insert(std::make_pair(p->name(), our_merge_entry_position));
}
void
-DepList::add_suggested_package(const tr1::shared_ptr<const PackageID> & p,
- const PackageDepSpec & pds, tr1::shared_ptr<DependencySpecTree::ConstItem> conditions,
- const tr1::shared_ptr<const DestinationsSet> destinations)
+DepList::add_suggested_package(const std::tr1::shared_ptr<const PackageID> & p,
+ const PackageDepSpec & pds, std::tr1::shared_ptr<DependencySpecTree::ConstItem> conditions,
+ const std::tr1::shared_ptr<const DestinationsSet> destinations)
{
std::pair<MergeListIndex::iterator, MergeListIndex::const_iterator> pp(
_imp->merge_list_index.equal_range(p->name()));
@@ -1247,7 +1248,7 @@ DepList::add_suggested_package(const tr1::shared_ptr<const PackageID> & p,
.package_id(p)
.generation(_imp->merge_list_generation)
.state(dle_has_all_deps)
- .tags(tr1::shared_ptr<DepListEntryTags>(new DepListEntryTags))
+ .tags(std::tr1::shared_ptr<DepListEntryTags>(new DepListEntryTags))
.destination(find_destination(*p, destinations))
.associated_entry(&*_imp->current_merge_list_entry)
.handled(make_shared_ptr(new DepListEntryNoHandlingRequired))
@@ -1255,7 +1256,7 @@ DepList::add_suggested_package(const tr1::shared_ptr<const PackageID> & p,
if (_imp->current_package_id())
our_merge_entry_position->tags->insert(DepTagEntry::create()
- .tag(tr1::shared_ptr<DepTag>(new DependencyDepTag(_imp->current_package_id(), pds, conditions)))
+ .tag(std::tr1::shared_ptr<DepTag>(new DependencyDepTag(_imp->current_package_id(), pds, conditions)))
.generation(_imp->merge_list_generation));
_imp->merge_list_index.insert(std::make_pair(p->name(), our_merge_entry_position));
@@ -1263,7 +1264,7 @@ DepList::add_suggested_package(const tr1::shared_ptr<const PackageID> & p,
void
DepList::add_predeps(DependencySpecTree::ConstItem & d, const DepListDepsOption opt, const std::string & s,
- tr1::shared_ptr<const DestinationsSet> destinations, const bool only_if_not_suggested_label)
+ std::tr1::shared_ptr<const DestinationsSet> destinations, const bool only_if_not_suggested_label)
{
if (dl_deps_pre == opt || dl_deps_pre_or_post == opt)
{
@@ -1285,7 +1286,7 @@ DepList::add_predeps(DependencySpecTree::ConstItem & d, const DepListDepsOption
void
DepList::add_postdeps(DependencySpecTree::ConstItem & d, const DepListDepsOption opt, const std::string & s,
- tr1::shared_ptr<const DestinationsSet> destinations, const bool only_if_not_suggested_label)
+ std::tr1::shared_ptr<const DestinationsSet> destinations, const bool only_if_not_suggested_label)
{
if (dl_deps_pre_or_post == opt || dl_deps_post == opt || dl_deps_try_post == opt)
{
@@ -1317,9 +1318,9 @@ DepList::add_postdeps(DependencySpecTree::ConstItem & d, const DepListDepsOption
}
void
-DepList::add_already_installed_package(const tr1::shared_ptr<const PackageID> & p, tr1::shared_ptr<const DepTag> tag,
- const PackageDepSpec & pds, tr1::shared_ptr<DependencySpecTree::ConstItem> conditions,
- const tr1::shared_ptr<const DestinationsSet> destinations)
+DepList::add_already_installed_package(const std::tr1::shared_ptr<const PackageID> & p, std::tr1::shared_ptr<const DepTag> tag,
+ const PackageDepSpec & pds, std::tr1::shared_ptr<DependencySpecTree::ConstItem> conditions,
+ const std::tr1::shared_ptr<const DestinationsSet> destinations)
{
Context context("When adding installed package '" + stringify(*p) + "':");
@@ -1329,9 +1330,9 @@ DepList::add_already_installed_package(const tr1::shared_ptr<const PackageID> &
DepListEntry::create()
.package_id(p)
.generation(_imp->merge_list_generation)
- .tags(tr1::shared_ptr<DepListEntryTags>(new DepListEntryTags))
+ .tags(std::tr1::shared_ptr<DepListEntryTags>(new DepListEntryTags))
.state(dle_has_pre_deps)
- .destination(tr1::shared_ptr<Repository>())
+ .destination(std::tr1::shared_ptr<Repository>())
.associated_entry(0)
.handled(make_shared_ptr(new DepListEntryNoHandlingRequired))
.kind(dlk_already_installed)));
@@ -1344,7 +1345,7 @@ DepList::add_already_installed_package(const tr1::shared_ptr<const PackageID> &
if (_imp->opts->dependency_tags && _imp->current_package_id())
our_merge_entry->tags->insert(DepTagEntry::create()
- .tag(tr1::shared_ptr<DepTag>(new DependencyDepTag(_imp->current_package_id(), pds, conditions)))
+ .tag(std::tr1::shared_ptr<DepTag>(new DependencyDepTag(_imp->current_package_id(), pds, conditions)))
.generation(_imp->merge_list_generation));
Save<MergeList::const_iterator> save_current_merge_list_entry(&_imp->current_merge_list_entry,
@@ -1485,7 +1486,7 @@ DepList::prefer_installed_over_uninstalled(const PackageID & installed,
uninstalled.iuse_key()->value()->begin(), uninstalled.iuse_key()->value()->end(),
std::inserter(iuse_common, iuse_common.begin()));
std::transform(iuse_common.begin(), iuse_common.end(), std::inserter(use_common, use_common.begin()),
- tr1::mem_fn(&IUseFlag::flag));
+ std::tr1::mem_fn(&IUseFlag::flag));
}
for (std::set<UseFlagName>::const_iterator f(use_common.begin()), f_end(use_common.end()) ;
@@ -1499,7 +1500,7 @@ DepList::prefer_installed_over_uninstalled(const PackageID & installed,
bool
DepList::already_installed(const DependencySpecTree::ConstItem & spec,
- tr1::shared_ptr<const DestinationsSet> destinations) const
+ std::tr1::shared_ptr<const DestinationsSet> destinations) const
{
QueryVisitor visitor(this, destinations, _imp->env, _imp->current_package_id());
spec.accept(visitor);
@@ -1574,9 +1575,9 @@ DepList::has_errors() const
return end() != std::find_if(begin(), end(), IsError());
}
-tr1::shared_ptr<Repository>
+std::tr1::shared_ptr<Repository>
DepList::find_destination(const PackageID & p,
- tr1::shared_ptr<const DestinationsSet> dd)
+ std::tr1::shared_ptr<const DestinationsSet> dd)
{
for (DestinationsSet::ConstIterator d(dd->begin()), d_end(dd->end()) ;
d != d_end ; ++d)
diff --git a/paludis/dep_list.hh b/paludis/dep_list.hh
index c7e537a..623f485 100644
--- a/paludis/dep_list.hh
+++ b/paludis/dep_list.hh
@@ -31,9 +31,8 @@
#include <paludis/util/instantiation_policy.hh>
#include <paludis/util/private_implementation_pattern.hh>
#include <paludis/util/options.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/version_spec.hh>
-
+#include <tr1/functional>
#include <iosfwd>
/** \file
@@ -53,7 +52,7 @@ namespace paludis
*
* \ingroup g_dep_list
*/
- typedef Sequence<tr1::function<bool (const PackageID &, const Mask &)> > DepListOverrideMasksFunctions;
+ typedef Sequence<std::tr1::function<bool (const PackageID &, const Mask &)> > DepListOverrideMasksFunctions;
#include <paludis/dep_list-sr.hh>
@@ -74,14 +73,14 @@ namespace paludis
/**
* Find an appropriate destination for a package.
*/
- tr1::shared_ptr<Repository> find_destination(const PackageID &,
- tr1::shared_ptr<const DestinationsSet>);
+ std::tr1::shared_ptr<Repository> find_destination(const PackageID &,
+ std::tr1::shared_ptr<const DestinationsSet>);
/**
* Add a DepSpec with role context.
*/
void add_in_role(const bool only_if_not_suggested_label, DependencySpecTree::ConstItem &, const std::string & role,
- tr1::shared_ptr<const DestinationsSet>);
+ std::tr1::shared_ptr<const DestinationsSet>);
/**
* Return whether we prefer the first parameter, which is installed,
@@ -93,34 +92,34 @@ namespace paludis
/**
* Add a package to the list.
*/
- void add_package(const tr1::shared_ptr<const PackageID> &, tr1::shared_ptr<const DepTag>,
- const PackageDepSpec &, tr1::shared_ptr<DependencySpecTree::ConstItem>,
- tr1::shared_ptr<const DestinationsSet> destinations);
+ void add_package(const std::tr1::shared_ptr<const PackageID> &, std::tr1::shared_ptr<const DepTag>,
+ const PackageDepSpec &, std::tr1::shared_ptr<DependencySpecTree::ConstItem>,
+ std::tr1::shared_ptr<const DestinationsSet> destinations);
/**
* Add an already installed package to the list.
*/
- void add_already_installed_package(const tr1::shared_ptr<const PackageID> &, tr1::shared_ptr<const DepTag>,
- const PackageDepSpec &, tr1::shared_ptr<DependencySpecTree::ConstItem>,
- tr1::shared_ptr<const DestinationsSet> destinations);
+ void add_already_installed_package(const std::tr1::shared_ptr<const PackageID> &, std::tr1::shared_ptr<const DepTag>,
+ const PackageDepSpec &, std::tr1::shared_ptr<DependencySpecTree::ConstItem>,
+ std::tr1::shared_ptr<const DestinationsSet> destinations);
/**
* Add an error package to the list.
*/
- void add_error_package(const tr1::shared_ptr<const PackageID> &, const DepListEntryKind,
- const PackageDepSpec &, tr1::shared_ptr<DependencySpecTree::ConstItem>);
+ void add_error_package(const std::tr1::shared_ptr<const PackageID> &, const DepListEntryKind,
+ const PackageDepSpec &, std::tr1::shared_ptr<DependencySpecTree::ConstItem>);
/**
* Add predependencies.
*/
void add_predeps(DependencySpecTree::ConstItem &, const DepListDepsOption, const std::string &,
- tr1::shared_ptr<const DestinationsSet> destinations, const bool only_if_not_suggested_label);
+ std::tr1::shared_ptr<const DestinationsSet> destinations, const bool only_if_not_suggested_label);
/**
* Add postdependencies.
*/
void add_postdeps(DependencySpecTree::ConstItem &, const DepListDepsOption, const std::string &,
- tr1::shared_ptr<const DestinationsSet> destinations, const bool only_if_not_suggested_label);
+ std::tr1::shared_ptr<const DestinationsSet> destinations, const bool only_if_not_suggested_label);
/**
* Return whether the specified PackageID is matched by
@@ -131,8 +130,8 @@ namespace paludis
void add_not_top_level(
const bool only_if_not_suggested_label,
DependencySpecTree::ConstItem &,
- tr1::shared_ptr<const DestinationsSet> target_destinations,
- tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > conditions);
+ std::tr1::shared_ptr<const DestinationsSet> target_destinations,
+ std::tr1::shared_ptr<ConstTreeSequence<DependencySpecTree, AllDepSpec> > conditions);
public:
///\name Basic operations
@@ -164,26 +163,26 @@ namespace paludis
/**
* Our options.
*/
- tr1::shared_ptr<DepListOptions> options();
+ std::tr1::shared_ptr<DepListOptions> options();
/**
* Our options.
*/
- const tr1::shared_ptr<const DepListOptions> options() const;
+ const std::tr1::shared_ptr<const DepListOptions> options() const;
/**
* Add the packages required to resolve an additional dependency
* spec.
*/
void add(SetSpecTree::ConstItem &,
- tr1::shared_ptr<const DestinationsSet> target_destinations);
+ std::tr1::shared_ptr<const DestinationsSet> target_destinations);
/**
* Add the packages required to resolve an additional dependency
* spec.
*/
void add(const PackageDepSpec &,
- tr1::shared_ptr<const DestinationsSet> target_destinations);
+ std::tr1::shared_ptr<const DestinationsSet> target_destinations);
/**
* Manually add a DepListEntry to the list.
@@ -203,7 +202,7 @@ namespace paludis
* Return whether a spec structure is already installed.
*/
bool already_installed(DependencySpecTree::ConstItem &,
- tr1::shared_ptr<const DestinationsSet> target_destinations) const;
+ std::tr1::shared_ptr<const DestinationsSet> target_destinations) const;
/**
* Return whether a PackageID has been replaced.
@@ -223,9 +222,9 @@ namespace paludis
/**
* Add a suggested package to the list.
*/
- void add_suggested_package(const tr1::shared_ptr<const PackageID> &,
- const PackageDepSpec &, tr1::shared_ptr<DependencySpecTree::ConstItem>,
- tr1::shared_ptr<const DestinationsSet> destinations);
+ void add_suggested_package(const std::tr1::shared_ptr<const PackageID> &,
+ const PackageDepSpec &, std::tr1::shared_ptr<DependencySpecTree::ConstItem>,
+ std::tr1::shared_ptr<const DestinationsSet> destinations);
};
}
diff --git a/paludis/dep_list.sr b/paludis/dep_list.sr
index dafbfe8..f30d3e9 100644
--- a/paludis/dep_list.sr
+++ b/paludis/dep_list.sr
@@ -26,7 +26,7 @@ make_class_DepListOptions()
key circular DepListCircularOption
key use DepListUseOption
key blocks DepListBlocksOption
- key override_masks "tr1::shared_ptr<DepListOverrideMasksFunctions>"
+ key override_masks "std::tr1::shared_ptr<DepListOverrideMasksFunctions>"
key dependency_tags bool
@@ -53,15 +53,15 @@ make_class_DepListEntry()
key kind DepListEntryKind
- key package_id "tr1::shared_ptr<const PackageID>"
+ key package_id "std::tr1::shared_ptr<const PackageID>"
key associated_entry "const DepListEntry *"
- key tags "tr1::shared_ptr<DepListEntryTags>"
- key destination "tr1::shared_ptr<Repository>"
+ key tags "std::tr1::shared_ptr<DepListEntryTags>"
+ key destination "std::tr1::shared_ptr<Repository>"
key generation long
key state DepListEntryState
- key handled "tr1::shared_ptr<const DepListEntryHandled>"
+ key handled "std::tr1::shared_ptr<const DepListEntryHandled>"
allow_named_args
diff --git a/paludis/dep_list_TEST.cc b/paludis/dep_list_TEST.cc
index e2bc97f..d04caa5 100644
--- a/paludis/dep_list_TEST.cc
+++ b/paludis/dep_list_TEST.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2005, 2006, 2007 Ciaran McCreesh
+ * Copyright (c) 2005, 2006, 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -1275,7 +1275,7 @@ namespace test_cases
void populate_repo()
{
repo->add_version("cat", "one", "1")->provide_key()->set_from_string("virtual/foo");
- tr1::shared_ptr<FakePackageID> m(repo->add_version("cat", "two", "2"));
+ std::tr1::shared_ptr<FakePackageID> m(repo->add_version("cat", "two", "2"));
m->provide_key()->set_from_string("virtual/foo");
m->build_dependencies_key()->set_from_string("cat/one");
}
@@ -1298,9 +1298,9 @@ namespace test_cases
{
void set_options(DepListOptions & opts)
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
opts.override_masks.reset(new DepListOverrideMasksFunctions);
- opts.override_masks->push_back(tr1::bind(&override_tilde_keywords, &env, _1, _2));
+ opts.override_masks->push_back(std::tr1::bind(&override_tilde_keywords, &env, _1, _2));
}
void populate_repo()
@@ -1370,9 +1370,9 @@ namespace test_cases
{
void set_options(DepListOptions & opts)
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
opts.override_masks.reset(new DepListOverrideMasksFunctions);
- opts.override_masks->push_back(tr1::bind(&override_tilde_keywords, &env, _1, _2));
+ opts.override_masks->push_back(std::tr1::bind(&override_tilde_keywords, &env, _1, _2));
}
void populate_repo()
@@ -1789,9 +1789,9 @@ namespace test_cases
void run()
{
TestEnvironment env;
- tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
+ std::tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
env.package_database()->add_repository(1, repo);
- tr1::shared_ptr<FakeInstalledRepository> destination_repo(new FakeInstalledRepository(&env,
+ std::tr1::shared_ptr<FakeInstalledRepository> destination_repo(new FakeInstalledRepository(&env,
RepositoryName("installed_repo")));
env.package_database()->add_repository(2, destination_repo);
@@ -1827,9 +1827,9 @@ namespace test_cases
void run()
{
TestEnvironment env;
- tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
+ std::tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
env.package_database()->add_repository(1, repo);
- tr1::shared_ptr<FakeInstalledRepository> destination_repo(new FakeInstalledRepository(&env,
+ std::tr1::shared_ptr<FakeInstalledRepository> destination_repo(new FakeInstalledRepository(&env,
RepositoryName("installed_repo")));
env.package_database()->add_repository(2, destination_repo);
@@ -1866,11 +1866,11 @@ namespace test_cases
{
TestEnvironment env;
- tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
+ std::tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
env.package_database()->add_repository(1, repo);
repo->add_version("cat", "one", "1");
- tr1::shared_ptr<FakeInstalledRepository> installed_repo(
+ std::tr1::shared_ptr<FakeInstalledRepository> installed_repo(
new FakeInstalledRepository(&env, RepositoryName("installed_repo")));
env.package_database()->add_repository(2, installed_repo);
installed_repo->add_version("cat", "one", "2");
@@ -1892,11 +1892,11 @@ namespace test_cases
{
TestEnvironment env;
- tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
+ std::tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
env.package_database()->add_repository(1, repo);
repo->add_version("cat", "one", "1")->build_dependencies_key()->set_from_string("cat/two");
- tr1::shared_ptr<FakeInstalledRepository> installed_repo(
+ std::tr1::shared_ptr<FakeInstalledRepository> installed_repo(
new FakeInstalledRepository(&env, RepositoryName("installed_repo")));
env.package_database()->add_repository(2, installed_repo);
installed_repo->add_version("cat", "two", "2");
@@ -1919,11 +1919,11 @@ namespace test_cases
{
TestEnvironment env;
- tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
+ std::tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
env.package_database()->add_repository(1, repo);
repo->add_version("cat", "one", "1")->build_dependencies_key()->set_from_string("cat/two");
- tr1::shared_ptr<FakeInstalledRepository> installed_repo(
+ std::tr1::shared_ptr<FakeInstalledRepository> installed_repo(
new FakeInstalledRepository(&env, RepositoryName("installed_repo")));
env.package_database()->add_repository(2, installed_repo);
installed_repo->add_version("cat", "two", "2");
@@ -1947,11 +1947,11 @@ namespace test_cases
{
TestEnvironment env;
- tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
+ std::tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
env.package_database()->add_repository(1, repo);
repo->add_version("cat", "one", "1")->build_dependencies_key()->set_from_string("cat/two");
- tr1::shared_ptr<FakeInstalledRepository> installed_repo(
+ std::tr1::shared_ptr<FakeInstalledRepository> installed_repo(
new FakeInstalledRepository(&env, RepositoryName("installed_repo")));
env.package_database()->add_repository(2, installed_repo);
installed_repo->add_version("cat", "two", "2");
@@ -1971,21 +1971,21 @@ namespace test_cases
DepList d3(&env, DepListOptions());
d3.options()->fall_back = dl_fall_back_as_needed_except_targets;
- tr1::shared_ptr<ConstTreeSequence<SetSpecTree, AllDepSpec> > t3(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
- tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
- t3->add(tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(new TreeLeaf<SetSpecTree, PackageDepSpec>(
- tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(parse_user_package_dep_spec("cat/one", UserPackageDepSpecOptions()))))));
- t3->add(tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(new TreeLeaf<SetSpecTree, PackageDepSpec>(
- tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(parse_user_package_dep_spec("cat/two", UserPackageDepSpecOptions()))))));
+ std::tr1::shared_ptr<ConstTreeSequence<SetSpecTree, AllDepSpec> > t3(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
+ std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
+ t3->add(std::tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(new TreeLeaf<SetSpecTree, PackageDepSpec>(
+ std::tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(parse_user_package_dep_spec("cat/one", UserPackageDepSpecOptions()))))));
+ t3->add(std::tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(new TreeLeaf<SetSpecTree, PackageDepSpec>(
+ std::tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(parse_user_package_dep_spec("cat/two", UserPackageDepSpecOptions()))))));
TEST_CHECK_THROWS(d3.add(*t3, env.default_destinations()), DepListError);
DepList d4(&env, DepListOptions());
- tr1::shared_ptr<ConstTreeSequence<SetSpecTree, AllDepSpec> > t4(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
- tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
- t4->add(tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(new TreeLeaf<SetSpecTree, PackageDepSpec>(
- tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(parse_user_package_dep_spec("cat/one", UserPackageDepSpecOptions()))))));
- t4->add(tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(new TreeLeaf<SetSpecTree, PackageDepSpec>(
- tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(parse_user_package_dep_spec("cat/three", UserPackageDepSpecOptions()))))));
+ std::tr1::shared_ptr<ConstTreeSequence<SetSpecTree, AllDepSpec> > t4(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
+ std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
+ t4->add(std::tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(new TreeLeaf<SetSpecTree, PackageDepSpec>(
+ std::tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(parse_user_package_dep_spec("cat/one", UserPackageDepSpecOptions()))))));
+ t4->add(std::tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(new TreeLeaf<SetSpecTree, PackageDepSpec>(
+ std::tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(parse_user_package_dep_spec("cat/three", UserPackageDepSpecOptions()))))));
TEST_CHECK_THROWS(d4.add(*t4, env.default_destinations()), DepListError);
}
} test_dep_list_fall_back_as_needed_not_targets;
@@ -2001,12 +2001,12 @@ namespace test_cases
{
TestEnvironment env;
- tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
+ std::tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
env.package_database()->add_repository(1, repo);
repo->add_version("cat", "one", "1")->build_dependencies_key()->set_from_string("cat/two");
repo->add_version("cat", "two", "2");
- tr1::shared_ptr<FakeInstalledRepository> installed_repo(
+ std::tr1::shared_ptr<FakeInstalledRepository> installed_repo(
new FakeInstalledRepository(&env, RepositoryName("installed_repo")));
env.package_database()->add_repository(2, installed_repo);
installed_repo->add_version("cat", "two", "0");
@@ -2019,12 +2019,12 @@ namespace test_cases
DepList d2(&env, DepListOptions());
d2.options()->upgrade = dl_upgrade_as_needed;
- tr1::shared_ptr<ConstTreeSequence<SetSpecTree, AllDepSpec> > t2(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
- tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
- t2->add(tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(new TreeLeaf<SetSpecTree, PackageDepSpec>(
- tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(parse_user_package_dep_spec("cat/one", UserPackageDepSpecOptions()))))));
- t2->add(tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(new TreeLeaf<SetSpecTree, PackageDepSpec>(
- tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(parse_user_package_dep_spec("cat/two", UserPackageDepSpecOptions()))))));
+ std::tr1::shared_ptr<ConstTreeSequence<SetSpecTree, AllDepSpec> > t2(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
+ std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
+ t2->add(std::tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(new TreeLeaf<SetSpecTree, PackageDepSpec>(
+ std::tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(parse_user_package_dep_spec("cat/one", UserPackageDepSpecOptions()))))));
+ t2->add(std::tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(new TreeLeaf<SetSpecTree, PackageDepSpec>(
+ std::tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(parse_user_package_dep_spec("cat/two", UserPackageDepSpecOptions()))))));
d2.add(*t2, env.default_destinations());
TEST_CHECK_EQUAL(join(d2.begin(), d2.end(), " "), "cat/two-2:0::repo cat/one-1:0::repo");
}
@@ -2041,7 +2041,7 @@ namespace test_cases
{
TestEnvironment env;
- tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
+ std::tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
env.package_database()->add_repository(1, repo);
repo->add_version("cat", "zero", "1")->build_dependencies_key()->set_from_string(
"( cat/one cat/two cat/three-live cat/four-cvs cat/five-svn cat/six-darcs )");
@@ -2052,7 +2052,7 @@ namespace test_cases
repo->add_version("cat", "five-svn", "0");
repo->add_version("cat", "six-darcs", "0");
- tr1::shared_ptr<FakeInstalledRepository> installed_repo(
+ std::tr1::shared_ptr<FakeInstalledRepository> installed_repo(
new FakeInstalledRepository(&env, RepositoryName("installed_repo")));
env.package_database()->add_repository(2, installed_repo);
installed_repo->add_version("cat", "one", "scm");
@@ -2082,24 +2082,24 @@ namespace test_cases
{
TestEnvironment env;
- tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
+ std::tr1::shared_ptr<FakeRepository> repo(new FakeRepository(&env, RepositoryName("repo")));
env.package_database()->add_repository(1, repo);
repo->add_version("cat", "one", "1")->build_dependencies_key()->set_from_string("cat/three");
repo->add_version("cat", "two", "1")->build_dependencies_key()->set_from_string("enabled? ( || ( ( <cat/three-1 cat/three:0 =cat/four-1 ) cat/five ) )");
repo->add_version("cat", "three", "0.9");
repo->add_version("cat", "four", "1");
- tr1::shared_ptr<FakeInstalledRepository> installed_repo(
+ std::tr1::shared_ptr<FakeInstalledRepository> installed_repo(
new FakeInstalledRepository(&env, RepositoryName("installed_repo")));
env.package_database()->add_repository(2, installed_repo);
DepList d1(&env, DepListOptions());
d1.options()->dependency_tags = true;
PackageDepSpec with_target_tag(parse_user_package_dep_spec("cat/one", UserPackageDepSpecOptions()));
- with_target_tag.set_tag(tr1::shared_ptr<const DepTag>(new TargetDepTag));
+ with_target_tag.set_tag(std::tr1::shared_ptr<const DepTag>(new TargetDepTag));
d1.add(with_target_tag, env.default_destinations());
PackageDepSpec with_set_tag(parse_user_package_dep_spec("cat/two", UserPackageDepSpecOptions()));
- with_set_tag.set_tag(tr1::shared_ptr<const DepTag>(new GeneralSetDepTag(SetName("set"), "test")));
+ with_set_tag.set_tag(std::tr1::shared_ptr<const DepTag>(new GeneralSetDepTag(SetName("set"), "test")));
d1.add(with_set_tag, env.default_destinations());
TEST_CHECK_EQUAL(join(d1.begin(), d1.end(), " "), "cat/three-0.9:0::repo cat/one-1:0::repo "
@@ -2107,7 +2107,7 @@ namespace test_cases
// tags for cat/three
DepList::Iterator it(d1.begin());
- tr1::shared_ptr<DepListEntryTags> tags(it->tags);
+ std::tr1::shared_ptr<DepListEntryTags> tags(it->tags);
TEST_CHECK_EQUAL(tags->size(), 3U);
bool cat_three_has_tag_from_cat_one(false);
bool cat_three_has_first_tag_from_cat_two(false);
@@ -2118,15 +2118,15 @@ namespace test_cases
{
if ("dependency" != tag_it->tag->category())
continue;
- tr1::shared_ptr<const DependencyDepTag> tag(
- tr1::static_pointer_cast<const DependencyDepTag>(tag_it->tag));
+ std::tr1::shared_ptr<const DependencyDepTag> tag(
+ std::tr1::static_pointer_cast<const DependencyDepTag>(tag_it->tag));
if ("cat/one-1:0::repo" == tag->short_text())
{
cat_three_has_tag_from_cat_one = true;
TEST_CHECK_STRINGIFY_EQUAL(*tag->dependency(), "cat/three");
StringifyFormatter ff;
- erepository::DepSpecPrettyPrinter pretty(0, tr1::shared_ptr<const PackageID>(), ff, 0, false);
+ erepository::DepSpecPrettyPrinter pretty(0, std::tr1::shared_ptr<const PackageID>(), ff, 0, false);
tag->conditions()->accept(pretty);
TEST_CHECK_STRINGIFY_EQUAL(pretty, "cat/three");
}
@@ -2137,7 +2137,7 @@ namespace test_cases
{
cat_three_has_first_tag_from_cat_two = true;
StringifyFormatter ff;
- erepository::DepSpecPrettyPrinter pretty(0, tr1::shared_ptr<const PackageID>(), ff, 0, false);
+ erepository::DepSpecPrettyPrinter pretty(0, std::tr1::shared_ptr<const PackageID>(), ff, 0, false);
tag->conditions()->accept(pretty);
TEST_CHECK_STRINGIFY_EQUAL(pretty, "enabled? ( || ( <cat/three-1 ) )");
}
@@ -2145,7 +2145,7 @@ namespace test_cases
{
cat_three_has_second_tag_from_cat_two = true;
StringifyFormatter ff;
- erepository::DepSpecPrettyPrinter pretty(0, tr1::shared_ptr<const PackageID>(), ff, 0, false);
+ erepository::DepSpecPrettyPrinter pretty(0, std::tr1::shared_ptr<const PackageID>(), ff, 0, false);
tag->conditions()->accept(pretty);
TEST_CHECK_STRINGIFY_EQUAL(pretty, "enabled? ( || ( cat/three:0 ) )");
}
@@ -2167,12 +2167,12 @@ namespace test_cases
tags = it->tags;
TEST_CHECK_EQUAL(tags->size(), 1U);
TEST_CHECK_EQUAL(tags->begin()->tag->category(), "dependency");
- tr1::shared_ptr<const DependencyDepTag> deptag(
- tr1::static_pointer_cast<const DependencyDepTag>(tags->begin()->tag));
+ std::tr1::shared_ptr<const DependencyDepTag> deptag(
+ std::tr1::static_pointer_cast<const DependencyDepTag>(tags->begin()->tag));
TEST_CHECK_EQUAL(deptag->short_text(), "cat/two-1:0::repo");
TEST_CHECK_STRINGIFY_EQUAL(*deptag->dependency(), "=cat/four-1");
StringifyFormatter ff;
- erepository::DepSpecPrettyPrinter pretty(0, tr1::shared_ptr<const PackageID>(), ff, 0, false);
+ erepository::DepSpecPrettyPrinter pretty(0, std::tr1::shared_ptr<const PackageID>(), ff, 0, false);
deptag->conditions()->accept(pretty);
TEST_CHECK_STRINGIFY_EQUAL(pretty, "enabled? ( || ( =cat/four-1 ) )");
diff --git a/paludis/dep_list_TEST.hh b/paludis/dep_list_TEST.hh
index 74a8ee3..a095f58 100644
--- a/paludis/dep_list_TEST.hh
+++ b/paludis/dep_list_TEST.hh
@@ -86,10 +86,10 @@ namespace test_cases
{
protected:
TestEnvironment env;
- tr1::shared_ptr<FakeRepository> repo;
- tr1::shared_ptr<FakeInstalledRepository> installed_repo;
- tr1::shared_ptr<VirtualsRepository> virtuals_repo;
- tr1::shared_ptr<InstalledVirtualsRepository> installed_virtuals_repo;
+ std::tr1::shared_ptr<FakeRepository> repo;
+ std::tr1::shared_ptr<FakeInstalledRepository> installed_repo;
+ std::tr1::shared_ptr<VirtualsRepository> virtuals_repo;
+ std::tr1::shared_ptr<InstalledVirtualsRepository> installed_virtuals_repo;
std::list<std::string> expected;
std::string merge_target;
bool done_populate;
diff --git a/paludis/dep_list_TEST_blockers.cc b/paludis/dep_list_TEST_blockers.cc
index ca6eddb..5c13db7 100644
--- a/paludis/dep_list_TEST_blockers.cc
+++ b/paludis/dep_list_TEST_blockers.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2005, 2006, 2007 Ciaran McCreesh
+ * Copyright (c) 2005, 2006, 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -86,7 +86,7 @@ namespace test_cases
void populate_repo()
{
repo->add_version("cat", "one", "1")->build_dependencies_key()->set_from_string("cat/two");
- tr1::shared_ptr<FakePackageID> two_m(repo->add_version("cat", "two", "1"));
+ std::tr1::shared_ptr<FakePackageID> two_m(repo->add_version("cat", "two", "1"));
two_m->build_dependencies_key()->set_from_string("!virtual/two");
two_m->provide_key()->set_from_string("virtual/two");
}
@@ -107,7 +107,7 @@ namespace test_cases
void populate_repo()
{
repo->add_version("cat", "one", "1")->build_dependencies_key()->set_from_string("cat/two");
- tr1::shared_ptr<FakePackageID> two_m(repo->add_version("cat", "two", "1"));
+ std::tr1::shared_ptr<FakePackageID> two_m(repo->add_version("cat", "two", "1"));
two_m->build_dependencies_key()->set_from_string("!virtual/two");
two_m->provide_key()->set_from_string("virtual/two");
installed_repo->add_version("other", "two", "1")->provide_key()->set_from_string("virtual/two");
@@ -214,11 +214,11 @@ namespace test_cases
void populate_repo()
{
- tr1::shared_ptr<FakePackageID> one_m(repo->add_version("cat", "one", "1"));
+ std::tr1::shared_ptr<FakePackageID> one_m(repo->add_version("cat", "one", "1"));
one_m->provide_key()->set_from_string("virtual/one");
one_m->build_dependencies_key()->set_from_string("!virtual/one");
one_m->run_dependencies_key()->set_from_string("!virtual/one");
- tr1::shared_ptr<FakePackageID> i_one_m(installed_repo->add_version("cat", "one", "1"));
+ std::tr1::shared_ptr<FakePackageID> i_one_m(installed_repo->add_version("cat", "one", "1"));
i_one_m->provide_key()->set_from_string("virtual/one");
i_one_m->run_dependencies_key()->set_from_string("!virtual/one");
}
@@ -237,11 +237,11 @@ namespace test_cases
void populate_repo()
{
- tr1::shared_ptr<FakePackageID> one_m(repo->add_version("cat", "one", "1"));
+ std::tr1::shared_ptr<FakePackageID> one_m(repo->add_version("cat", "one", "1"));
one_m->provide_key()->set_from_string("virtual/one");
one_m->build_dependencies_key()->set_from_string("!virtual/one");
one_m->run_dependencies_key()->set_from_string("!virtual/one");
- tr1::shared_ptr<FakePackageID> i_one_m(installed_repo->add_version("cat", "one", "1"));
+ std::tr1::shared_ptr<FakePackageID> i_one_m(installed_repo->add_version("cat", "one", "1"));
i_one_m->provide_key()->set_from_string("virtual/one");
i_one_m->run_dependencies_key()->set_from_string("!virtual/one");
}
@@ -266,7 +266,7 @@ namespace test_cases
void populate_repo()
{
repo->add_version("cat", "one", "1")->build_dependencies_key()->set_from_string("cat/two");
- tr1::shared_ptr<FakePackageID> two_m(repo->add_version("cat", "two", "2"));
+ std::tr1::shared_ptr<FakePackageID> two_m(repo->add_version("cat", "two", "2"));
two_m->provide_key()->set_from_string("virtual/two");
two_m->build_dependencies_key()->set_from_string("!virtual/two");
installed_repo->add_version("cat", "two", "1")->provide_key()->set_from_string("virtual/two");
@@ -315,7 +315,7 @@ namespace test_cases
void populate_repo()
{
repo->add_version("cat", "one", "1")->build_dependencies_key()->set_from_string("cat/two");
- tr1::shared_ptr<FakePackageID> two_m(repo->add_version("cat", "two", "2"));
+ std::tr1::shared_ptr<FakePackageID> two_m(repo->add_version("cat", "two", "2"));
two_m->build_dependencies_key()->set_from_string("!<virtual/two-2");
two_m->provide_key()->set_from_string("virtual/two");
installed_repo->add_version("cat", "two", "1")->provide_key()->set_from_string("virtual/two");
@@ -344,7 +344,7 @@ namespace test_cases
void populate_repo()
{
repo->add_version("cat", "one", "1")->build_dependencies_key()->set_from_string("cat/two");
- tr1::shared_ptr<FakePackageID> two_m(repo->add_version("cat", "two", "2"));
+ std::tr1::shared_ptr<FakePackageID> two_m(repo->add_version("cat", "two", "2"));
two_m->build_dependencies_key()->set_from_string("!<virtual/two-2");
two_m->provide_key()->set_from_string("virtual/two");
installed_repo->add_version("other", "two", "1")->provide_key()->set_from_string("virtual/two");
diff --git a/paludis/dep_list_exceptions.cc b/paludis/dep_list_exceptions.cc
index 05ee324..eff49cc 100644
--- a/paludis/dep_list_exceptions.cc
+++ b/paludis/dep_list_exceptions.cc
@@ -66,7 +66,7 @@ DowngradeNotAllowedError::~DowngradeNotAllowedError() throw ()
namespace
{
std::string
- destinations_to_string(tr1::shared_ptr<const DestinationsSet> dd)
+ destinations_to_string(std::tr1::shared_ptr<const DestinationsSet> dd)
{
std::string result;
bool need_comma(false);
@@ -84,7 +84,7 @@ namespace
}
NoDestinationError::NoDestinationError(const PackageID & p,
- tr1::shared_ptr<const DestinationsSet> d) throw () :
+ std::tr1::shared_ptr<const DestinationsSet> d) throw () :
DepListError("No suitable destination for '" + stringify(p) + "' in (" +
destinations_to_string(d) + ")")
{
diff --git a/paludis/dep_list_exceptions.hh b/paludis/dep_list_exceptions.hh
index 671bc3f..1cab520 100644
--- a/paludis/dep_list_exceptions.hh
+++ b/paludis/dep_list_exceptions.hh
@@ -189,7 +189,7 @@ namespace paludis
///\{
NoDestinationError(const PackageID &,
- tr1::shared_ptr<const DestinationsSet>) throw ();
+ std::tr1::shared_ptr<const DestinationsSet>) throw ();
///\}
};
diff --git a/paludis/dep_spec-fwd.hh b/paludis/dep_spec-fwd.hh
index 381083f..1458544 100644
--- a/paludis/dep_spec-fwd.hh
+++ b/paludis/dep_spec-fwd.hh
@@ -27,7 +27,7 @@
#include <paludis/formatter-fwd.hh>
#include <paludis/util/attributes.hh>
#include <paludis/util/sequence-fwd.hh>
-#include <paludis/util/tr1_memory.hh>
+#include <tr1/memory>
/** \file
* Forward declarations for paludis/dep_spec.hh .
@@ -86,7 +86,7 @@ namespace paludis
* \since 0.26
* \ingroup g_dep_spec
*/
- typedef Sequence<tr1::shared_ptr<const AdditionalPackageDepSpecRequirement> > AdditionalPackageDepSpecRequirements;
+ typedef Sequence<std::tr1::shared_ptr<const AdditionalPackageDepSpecRequirement> > AdditionalPackageDepSpecRequirements;
/**
* Create a PackageDepSpec from various rules.
diff --git a/paludis/dep_spec.cc b/paludis/dep_spec.cc
index 70698dc..1714aae 100644
--- a/paludis/dep_spec.cc
+++ b/paludis/dep_spec.cc
@@ -34,9 +34,9 @@
#include <paludis/util/iterator_funcs.hh>
#include <paludis/util/indirect_iterator-impl.hh>
#include <paludis/util/options.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/make_shared_ptr.hh>
#include <paludis/util/visitor-impl.hh>
+#include <tr1/functional>
#include <algorithm>
#include <list>
#include <map>
@@ -67,20 +67,20 @@ AnyDepSpec::AnyDepSpec()
{
}
-tr1::shared_ptr<DepSpec>
+std::tr1::shared_ptr<DepSpec>
AnyDepSpec::clone() const
{
- return tr1::shared_ptr<AnyDepSpec>(new AnyDepSpec());
+ return std::tr1::shared_ptr<AnyDepSpec>(new AnyDepSpec());
}
AllDepSpec::AllDepSpec()
{
}
-tr1::shared_ptr<DepSpec>
+std::tr1::shared_ptr<DepSpec>
AllDepSpec::clone() const
{
- return tr1::shared_ptr<AllDepSpec>(new AllDepSpec());
+ return std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec());
}
namespace paludis
@@ -88,11 +88,11 @@ namespace paludis
template <>
struct Implementation<ConditionalDepSpec>
{
- const tr1::shared_ptr<const ConditionalDepSpecData> data;
+ const std::tr1::shared_ptr<const ConditionalDepSpecData> data;
Mutex mutex;
bool added_keys;
- Implementation(const tr1::shared_ptr<const ConditionalDepSpecData> & d) :
+ Implementation(const std::tr1::shared_ptr<const ConditionalDepSpecData> & d) :
data(d),
added_keys(false)
{
@@ -100,7 +100,7 @@ namespace paludis
};
}
-ConditionalDepSpec::ConditionalDepSpec(const tr1::shared_ptr<const ConditionalDepSpecData> & d) :
+ConditionalDepSpec::ConditionalDepSpec(const std::tr1::shared_ptr<const ConditionalDepSpecData> & d) :
PrivateImplementationPattern<ConditionalDepSpec>(new Implementation<ConditionalDepSpec>(d)),
_imp(PrivateImplementationPattern<ConditionalDepSpec>::_imp)
{
@@ -137,9 +137,9 @@ ConditionalDepSpec::need_keys_added() const
if (! _imp->added_keys)
{
_imp->added_keys = true;
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
std::for_each(_imp->data->begin_metadata(), _imp->data->end_metadata(),
- tr1::bind(&ConditionalDepSpec::add_metadata_key, this, _1));
+ std::tr1::bind(&ConditionalDepSpec::add_metadata_key, this, _1));
}
}
@@ -163,7 +163,7 @@ ConditionalDepSpec::condition_meetable() const
return _imp->data->condition_meetable();
}
-const tr1::shared_ptr<const ConditionalDepSpecData>
+const std::tr1::shared_ptr<const ConditionalDepSpecData>
ConditionalDepSpec::data() const
{
return _imp->data;
@@ -203,10 +203,10 @@ NamedSetDepSpec::name() const
return _name;
}
-tr1::shared_ptr<DepSpec>
+std::tr1::shared_ptr<DepSpec>
NamedSetDepSpec::clone() const
{
- return tr1::shared_ptr<NamedSetDepSpec>(new NamedSetDepSpec(_name));
+ return std::tr1::shared_ptr<NamedSetDepSpec>(new NamedSetDepSpec(_name));
}
const PackageDepSpec *
@@ -215,7 +215,7 @@ PackageDepSpec::as_package_dep_spec() const
return this;
}
-BlockDepSpec::BlockDepSpec(tr1::shared_ptr<const PackageDepSpec> a) :
+BlockDepSpec::BlockDepSpec(std::tr1::shared_ptr<const PackageDepSpec> a) :
StringDepSpec("!" + a->text()),
_spec(a)
{
@@ -315,10 +315,10 @@ PlainTextDepSpec::PlainTextDepSpec(const std::string & s) :
{
}
-tr1::shared_ptr<DepSpec>
+std::tr1::shared_ptr<DepSpec>
PlainTextDepSpec::clone() const
{
- return tr1::shared_ptr<DepSpec>(new PlainTextDepSpec(text()));
+ return std::tr1::shared_ptr<DepSpec>(new PlainTextDepSpec(text()));
}
LicenseDepSpec::LicenseDepSpec(const std::string & s) :
@@ -326,10 +326,10 @@ LicenseDepSpec::LicenseDepSpec(const std::string & s) :
{
}
-tr1::shared_ptr<DepSpec>
+std::tr1::shared_ptr<DepSpec>
LicenseDepSpec::clone() const
{
- return tr1::shared_ptr<DepSpec>(new LicenseDepSpec(text()));
+ return std::tr1::shared_ptr<DepSpec>(new LicenseDepSpec(text()));
}
SimpleURIDepSpec::SimpleURIDepSpec(const std::string & s) :
@@ -337,22 +337,22 @@ SimpleURIDepSpec::SimpleURIDepSpec(const std::string & s) :
{
}
-tr1::shared_ptr<DepSpec>
+std::tr1::shared_ptr<DepSpec>
SimpleURIDepSpec::clone() const
{
- return tr1::shared_ptr<DepSpec>(new SimpleURIDepSpec(text()));
+ return std::tr1::shared_ptr<DepSpec>(new SimpleURIDepSpec(text()));
}
-tr1::shared_ptr<const PackageDepSpec>
+std::tr1::shared_ptr<const PackageDepSpec>
BlockDepSpec::blocked_spec() const
{
return _spec;
}
-tr1::shared_ptr<DepSpec>
+std::tr1::shared_ptr<DepSpec>
BlockDepSpec::clone() const
{
- return tr1::shared_ptr<DepSpec>(new BlockDepSpec(tr1::static_pointer_cast<PackageDepSpec>(_spec->clone())));
+ return std::tr1::shared_ptr<DepSpec>(new BlockDepSpec(std::tr1::static_pointer_cast<PackageDepSpec>(_spec->clone())));
}
FetchableURIDepSpec::FetchableURIDepSpec(const std::string & s) :
@@ -395,10 +395,10 @@ FetchableURIDepSpec::filename() const
return orig.substr(p+1);
}
-tr1::shared_ptr<DepSpec>
+std::tr1::shared_ptr<DepSpec>
FetchableURIDepSpec::clone() const
{
- return tr1::shared_ptr<FetchableURIDepSpec>(new FetchableURIDepSpec(text()));
+ return std::tr1::shared_ptr<FetchableURIDepSpec>(new FetchableURIDepSpec(text()));
}
namespace paludis
@@ -409,7 +409,7 @@ namespace paludis
template <typename T_>
struct Implementation<LabelsDepSpec<T_ > >
{
- std::list<tr1::shared_ptr<const typename T_::BasicNode> > items;
+ std::list<std::tr1::shared_ptr<const typename T_::BasicNode> > items;
};
}
@@ -425,12 +425,12 @@ LabelsDepSpec<T_>::~LabelsDepSpec()
}
template <typename T_>
-tr1::shared_ptr<DepSpec>
+std::tr1::shared_ptr<DepSpec>
LabelsDepSpec<T_>::clone() const
{
- using namespace tr1::placeholders;
- tr1::shared_ptr<LabelsDepSpec<T_> > my_clone(new LabelsDepSpec<T_>);
- std::for_each(begin(), end(), tr1::bind(tr1::mem_fn(&LabelsDepSpec<T_>::add_label), my_clone.get(), _1));
+ using namespace std::tr1::placeholders;
+ std::tr1::shared_ptr<LabelsDepSpec<T_> > my_clone(new LabelsDepSpec<T_>);
+ std::for_each(begin(), end(), std::tr1::bind(std::tr1::mem_fn(&LabelsDepSpec<T_>::add_label), my_clone.get(), _1));
return my_clone;
}
@@ -450,7 +450,7 @@ LabelsDepSpec<T_>::end() const
template <typename T_>
void
-LabelsDepSpec<T_>::add_label(const tr1::shared_ptr<const typename T_::BasicNode> & item)
+LabelsDepSpec<T_>::add_label(const std::tr1::shared_ptr<const typename T_::BasicNode> & item)
{
_imp->items.push_back(item);
}
@@ -464,10 +464,10 @@ namespace paludis
template <>
struct Implementation<PackageDepSpec>
{
- const tr1::shared_ptr<const PackageDepSpecData> data;
- tr1::shared_ptr<const DepTag> tag;
+ const std::tr1::shared_ptr<const PackageDepSpecData> data;
+ std::tr1::shared_ptr<const DepTag> tag;
- Implementation(const tr1::shared_ptr<const PackageDepSpecData> & d, const tr1::shared_ptr<const DepTag> & t) :
+ Implementation(const std::tr1::shared_ptr<const PackageDepSpecData> & d, const std::tr1::shared_ptr<const DepTag> & t) :
data(d),
tag(t)
{
@@ -475,10 +475,10 @@ namespace paludis
};
}
-PackageDepSpec::PackageDepSpec(const tr1::shared_ptr<const PackageDepSpecData> & d) :
+PackageDepSpec::PackageDepSpec(const std::tr1::shared_ptr<const PackageDepSpecData> & d) :
Cloneable<DepSpec>(),
StringDepSpec(d->as_string()),
- PrivateImplementationPattern<PackageDepSpec>(new Implementation<PackageDepSpec>(d, tr1::shared_ptr<const DepTag>()))
+ PrivateImplementationPattern<PackageDepSpec>(new Implementation<PackageDepSpec>(d, std::tr1::shared_ptr<const DepTag>()))
{
}
@@ -494,25 +494,25 @@ PackageDepSpec::PackageDepSpec(const PackageDepSpec & d) :
{
}
-tr1::shared_ptr<const QualifiedPackageName>
+std::tr1::shared_ptr<const QualifiedPackageName>
PackageDepSpec::package_ptr() const
{
return _imp->data->package_ptr();
}
-tr1::shared_ptr<const PackageNamePart>
+std::tr1::shared_ptr<const PackageNamePart>
PackageDepSpec::package_name_part_ptr() const
{
return _imp->data->package_name_part_ptr();
}
-tr1::shared_ptr<const CategoryNamePart>
+std::tr1::shared_ptr<const CategoryNamePart>
PackageDepSpec::category_name_part_ptr() const
{
return _imp->data->category_name_part_ptr();
}
-tr1::shared_ptr<const VersionRequirements>
+std::tr1::shared_ptr<const VersionRequirements>
PackageDepSpec::version_requirements_ptr() const
{
return _imp->data->version_requirements_ptr();
@@ -524,28 +524,28 @@ PackageDepSpec::version_requirements_mode() const
return _imp->data->version_requirements_mode();
}
-tr1::shared_ptr<const SlotRequirement>
+std::tr1::shared_ptr<const SlotRequirement>
PackageDepSpec::slot_requirement_ptr() const
{
return _imp->data->slot_requirement_ptr();
}
-tr1::shared_ptr<const RepositoryName>
+std::tr1::shared_ptr<const RepositoryName>
PackageDepSpec::repository_ptr() const
{
return _imp->data->repository_ptr();
}
-tr1::shared_ptr<const AdditionalPackageDepSpecRequirements>
+std::tr1::shared_ptr<const AdditionalPackageDepSpecRequirements>
PackageDepSpec::additional_requirements_ptr() const
{
return _imp->data->additional_requirements_ptr();
}
-tr1::shared_ptr<PackageDepSpec>
+std::tr1::shared_ptr<PackageDepSpec>
PackageDepSpec::without_additional_requirements() const
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
PartiallyMadePackageDepSpec result;
@@ -560,7 +560,7 @@ PackageDepSpec::without_additional_requirements() const
if (version_requirements_ptr())
std::for_each(version_requirements_ptr()->begin(), version_requirements_ptr()->end(),
- tr1::bind(&PartiallyMadePackageDepSpec::version_requirement, &result, _1));
+ std::tr1::bind(&PartiallyMadePackageDepSpec::version_requirement, &result, _1));
result.version_requirements_mode(version_requirements_mode());
@@ -573,14 +573,14 @@ PackageDepSpec::without_additional_requirements() const
return make_shared_ptr(new PackageDepSpec(result));
}
-tr1::shared_ptr<const DepTag>
+std::tr1::shared_ptr<const DepTag>
PackageDepSpec::tag() const
{
return _imp->tag;
}
void
-PackageDepSpec::set_tag(const tr1::shared_ptr<const DepTag> & s)
+PackageDepSpec::set_tag(const std::tr1::shared_ptr<const DepTag> & s)
{
_imp->tag = s;
}
@@ -606,14 +606,14 @@ namespace
struct PartiallyMadePackageDepSpecData :
PackageDepSpecData
{
- tr1::shared_ptr<QualifiedPackageName> package;
- tr1::shared_ptr<PackageNamePart> package_name_part;
- tr1::shared_ptr<CategoryNamePart> category_name_part;
- tr1::shared_ptr<VersionRequirements> version_requirements;
+ std::tr1::shared_ptr<QualifiedPackageName> package;
+ std::tr1::shared_ptr<PackageNamePart> package_name_part;
+ std::tr1::shared_ptr<CategoryNamePart> category_name_part;
+ std::tr1::shared_ptr<VersionRequirements> version_requirements;
VersionRequirementsMode version_requirements_mode_v;
- tr1::shared_ptr<const SlotRequirement> slot;
- tr1::shared_ptr<RepositoryName> repository;
- tr1::shared_ptr<AdditionalPackageDepSpecRequirements> additional_requirements;
+ std::tr1::shared_ptr<const SlotRequirement> slot;
+ std::tr1::shared_ptr<RepositoryName> repository;
+ std::tr1::shared_ptr<AdditionalPackageDepSpecRequirements> additional_requirements;
PartiallyMadePackageDepSpecData() :
PackageDepSpecData(),
@@ -747,22 +747,22 @@ namespace
return s.str();
}
- virtual tr1::shared_ptr<const QualifiedPackageName> package_ptr() const
+ virtual std::tr1::shared_ptr<const QualifiedPackageName> package_ptr() const
{
return package;
}
- virtual tr1::shared_ptr<const PackageNamePart> package_name_part_ptr() const
+ virtual std::tr1::shared_ptr<const PackageNamePart> package_name_part_ptr() const
{
return package_name_part;
}
- virtual tr1::shared_ptr<const CategoryNamePart> category_name_part_ptr() const
+ virtual std::tr1::shared_ptr<const CategoryNamePart> category_name_part_ptr() const
{
return category_name_part;
}
- virtual tr1::shared_ptr<const VersionRequirements> version_requirements_ptr() const
+ virtual std::tr1::shared_ptr<const VersionRequirements> version_requirements_ptr() const
{
return version_requirements;
}
@@ -772,17 +772,17 @@ namespace
return version_requirements_mode_v;
}
- virtual tr1::shared_ptr<const SlotRequirement> slot_requirement_ptr() const
+ virtual std::tr1::shared_ptr<const SlotRequirement> slot_requirement_ptr() const
{
return slot;
}
- virtual tr1::shared_ptr<const RepositoryName> repository_ptr() const
+ virtual std::tr1::shared_ptr<const RepositoryName> repository_ptr() const
{
return repository;
}
- virtual tr1::shared_ptr<const AdditionalPackageDepSpecRequirements> additional_requirements_ptr() const
+ virtual std::tr1::shared_ptr<const AdditionalPackageDepSpecRequirements> additional_requirements_ptr() const
{
return additional_requirements;
}
@@ -794,7 +794,7 @@ namespace paludis
template <>
struct Implementation<PartiallyMadePackageDepSpec>
{
- tr1::shared_ptr<PartiallyMadePackageDepSpecData> data;
+ std::tr1::shared_ptr<PartiallyMadePackageDepSpecData> data;
Implementation() :
data(new PartiallyMadePackageDepSpecData)
@@ -830,7 +830,7 @@ PartiallyMadePackageDepSpec::package(const QualifiedPackageName & name)
}
PartiallyMadePackageDepSpec &
-PartiallyMadePackageDepSpec::slot_requirement(const tr1::shared_ptr<const SlotRequirement> & s)
+PartiallyMadePackageDepSpec::slot_requirement(const std::tr1::shared_ptr<const SlotRequirement> & s)
{
_imp->data->slot = s;
return *this;
@@ -874,7 +874,7 @@ PartiallyMadePackageDepSpec::version_requirements_mode(const VersionRequirements
}
PartiallyMadePackageDepSpec &
-PartiallyMadePackageDepSpec::additional_requirement(const tr1::shared_ptr<const AdditionalPackageDepSpecRequirement> & req)
+PartiallyMadePackageDepSpec::additional_requirement(const std::tr1::shared_ptr<const AdditionalPackageDepSpecRequirement> & req)
{
if (! _imp->data->additional_requirements)
_imp->data->additional_requirements.reset(new AdditionalPackageDepSpecRequirements);
@@ -895,11 +895,11 @@ PartiallyMadePackageDepSpec::to_package_dep_spec() const
template class LabelsDepSpec<URILabelVisitorTypes>;
template class WrappedForwardIterator<LabelsDepSpec<URILabelVisitorTypes>::ConstIteratorTag,
- const tr1::shared_ptr<const URILabelVisitorTypes::BasicNode> >;
+ const std::tr1::shared_ptr<const URILabelVisitorTypes::BasicNode> >;
template class LabelsDepSpec<DependencyLabelVisitorTypes>;
template class WrappedForwardIterator<LabelsDepSpec<DependencyLabelVisitorTypes>::ConstIteratorTag,
- const tr1::shared_ptr<const DependencyLabelVisitorTypes::BasicNode> >;
+ const std::tr1::shared_ptr<const DependencyLabelVisitorTypes::BasicNode> >;
-template class Sequence<tr1::shared_ptr<const AdditionalPackageDepSpecRequirement> >;
+template class Sequence<std::tr1::shared_ptr<const AdditionalPackageDepSpecRequirement> >;
diff --git a/paludis/dep_spec.hh b/paludis/dep_spec.hh
index 2a6119a..adb1911 100644
--- a/paludis/dep_spec.hh
+++ b/paludis/dep_spec.hh
@@ -24,8 +24,6 @@
#include <paludis/util/clone.hh>
#include <paludis/util/instantiation_policy.hh>
#include <paludis/util/private_implementation_pattern.hh>
-#include <paludis/util/tr1_memory.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/wrapped_forward_iterator-fwd.hh>
#include <paludis/dep_label.hh>
@@ -40,6 +38,9 @@
#include <paludis/package_id-fwd.hh>
#include <paludis/environment-fwd.hh>
+#include <tr1/memory>
+#include <tr1/functional>
+
/** \file
* Declarations for dependency spec classes.
*
@@ -113,7 +114,7 @@ namespace paludis
///\}
- virtual tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ virtual std::tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
};
/**
@@ -134,7 +135,7 @@ namespace paludis
///\}
- virtual tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ virtual std::tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
};
/**
@@ -166,7 +167,7 @@ namespace paludis
///\name Basic operations
///\{
- ConditionalDepSpec(const tr1::shared_ptr<const ConditionalDepSpecData> &);
+ ConditionalDepSpec(const std::tr1::shared_ptr<const ConditionalDepSpecData> &);
ConditionalDepSpec(const ConditionalDepSpec &);
~ConditionalDepSpec();
@@ -194,7 +195,7 @@ namespace paludis
* This shouldn't generally be used by clients, but some repositories use it
* to gain access to additional data stored in the ConditionalDepSpecData.
*/
- const tr1::shared_ptr<const ConditionalDepSpecData> data() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ const std::tr1::shared_ptr<const ConditionalDepSpecData> data() const PALUDIS_ATTRIBUTE((warn_unused_result));
};
/**
@@ -320,7 +321,7 @@ namespace paludis
/**
* Set our slot requirements, return ourself.
*/
- PartiallyMadePackageDepSpec & slot_requirement(const tr1::shared_ptr<const SlotRequirement> &);
+ PartiallyMadePackageDepSpec & slot_requirement(const std::tr1::shared_ptr<const SlotRequirement> &);
/**
* Set our repository requirements, return ourself.
@@ -351,7 +352,7 @@ namespace paludis
* Add an additional requirement, return ourself.
*/
PartiallyMadePackageDepSpec & additional_requirement(
- const tr1::shared_ptr<const AdditionalPackageDepSpecRequirement> &);
+ const std::tr1::shared_ptr<const AdditionalPackageDepSpecRequirement> &);
/**
* Turn ourselves into a PackageDepSpec.
@@ -406,7 +407,7 @@ namespace paludis
*
* \since 0.26
*/
- PackageDepSpec(const tr1::shared_ptr<const PackageDepSpecData> &);
+ PackageDepSpec(const std::tr1::shared_ptr<const PackageDepSpecData> &);
PackageDepSpec(const PackageDepSpec &);
@@ -417,22 +418,22 @@ namespace paludis
/**
* Fetch the package name (may be a zero pointer).
*/
- tr1::shared_ptr<const QualifiedPackageName> package_ptr() const;
+ std::tr1::shared_ptr<const QualifiedPackageName> package_ptr() const;
/**
* Fetch the package name part, if wildcarded, or a zero pointer otherwise.
*/
- tr1::shared_ptr<const PackageNamePart> package_name_part_ptr() const;
+ std::tr1::shared_ptr<const PackageNamePart> package_name_part_ptr() const;
/**
* Fetch the category name part, if wildcarded, or a zero pointer otherwise.
*/
- tr1::shared_ptr<const CategoryNamePart> category_name_part_ptr() const;
+ std::tr1::shared_ptr<const CategoryNamePart> category_name_part_ptr() const;
/**
* Fetch the version requirements (may be a zero pointer).
*/
- tr1::shared_ptr<const VersionRequirements> version_requirements_ptr() const;
+ std::tr1::shared_ptr<const VersionRequirements> version_requirements_ptr() const;
/**
* Fetch the version requirements mode.
@@ -442,32 +443,32 @@ namespace paludis
/**
* Fetch the slot requirement (may be a zero pointer).
*/
- tr1::shared_ptr<const SlotRequirement> slot_requirement_ptr() const;
+ std::tr1::shared_ptr<const SlotRequirement> slot_requirement_ptr() const;
/**
* Fetch the repo name (may be a zero pointer).
*/
- tr1::shared_ptr<const RepositoryName> repository_ptr() const;
+ std::tr1::shared_ptr<const RepositoryName> repository_ptr() const;
/**
* Fetch any additional requirements (may be a zero pointer).
*/
- tr1::shared_ptr<const AdditionalPackageDepSpecRequirements> additional_requirements_ptr() const;
+ std::tr1::shared_ptr<const AdditionalPackageDepSpecRequirements> additional_requirements_ptr() const;
/**
* Fetch our tag.
*/
- tr1::shared_ptr<const DepTag> tag() const;
+ std::tr1::shared_ptr<const DepTag> tag() const;
/**
* Set our tag.
*/
- void set_tag(const tr1::shared_ptr<const DepTag> & s);
+ void set_tag(const std::tr1::shared_ptr<const DepTag> & s);
/**
* Fetch a copy of ourself without additional requirements.
*/
- tr1::shared_ptr<PackageDepSpec> without_additional_requirements() const;
+ std::tr1::shared_ptr<PackageDepSpec> without_additional_requirements() const;
virtual const PackageDepSpec * as_package_dep_spec() const;
};
@@ -496,22 +497,22 @@ namespace paludis
/**
* Fetch the package name (may be a zero pointer).
*/
- virtual tr1::shared_ptr<const QualifiedPackageName> package_ptr() const = 0;
+ virtual std::tr1::shared_ptr<const QualifiedPackageName> package_ptr() const = 0;
/**
* Fetch the package name part, if wildcarded, or a zero pointer otherwise.
*/
- virtual tr1::shared_ptr<const PackageNamePart> package_name_part_ptr() const = 0;
+ virtual std::tr1::shared_ptr<const PackageNamePart> package_name_part_ptr() const = 0;
/**
* Fetch the category name part, if wildcarded, or a zero pointer otherwise.
*/
- virtual tr1::shared_ptr<const CategoryNamePart> category_name_part_ptr() const = 0;
+ virtual std::tr1::shared_ptr<const CategoryNamePart> category_name_part_ptr() const = 0;
/**
* Fetch the version requirements (may be a zero pointer).
*/
- virtual tr1::shared_ptr<const VersionRequirements> version_requirements_ptr() const = 0;
+ virtual std::tr1::shared_ptr<const VersionRequirements> version_requirements_ptr() const = 0;
/**
* Fetch the version requirements mode.
@@ -521,17 +522,17 @@ namespace paludis
/**
* Fetch the slot name (may be a zero pointer).
*/
- virtual tr1::shared_ptr<const SlotRequirement> slot_requirement_ptr() const = 0;
+ virtual std::tr1::shared_ptr<const SlotRequirement> slot_requirement_ptr() const = 0;
/**
* Fetch the repo name (may be a zero pointer).
*/
- virtual tr1::shared_ptr<const RepositoryName> repository_ptr() const = 0;
+ virtual std::tr1::shared_ptr<const RepositoryName> repository_ptr() const = 0;
/**
* Fetch the additional requirements (may be a zero pointer).
*/
- virtual tr1::shared_ptr<const AdditionalPackageDepSpecRequirements> additional_requirements_ptr() const = 0;
+ virtual std::tr1::shared_ptr<const AdditionalPackageDepSpecRequirements> additional_requirements_ptr() const = 0;
};
/**
@@ -551,7 +552,7 @@ namespace paludis
///\}
- virtual tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ virtual std::tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
};
/**
@@ -577,7 +578,7 @@ namespace paludis
/// Fetch the name of our set.
const SetName name() const PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ virtual std::tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
};
/**
@@ -598,7 +599,7 @@ namespace paludis
///\}
- virtual tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ virtual std::tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
};
/**
@@ -641,7 +642,7 @@ namespace paludis
*/
std::string filename() const;
- virtual tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ virtual std::tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
};
/**
@@ -664,7 +665,7 @@ namespace paludis
///\}
- virtual tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ virtual std::tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
};
/**
@@ -698,22 +699,22 @@ namespace paludis
public StringDepSpec
{
private:
- tr1::shared_ptr<const PackageDepSpec> _spec;
+ std::tr1::shared_ptr<const PackageDepSpec> _spec;
public:
///\name Basic operations
///\{
- BlockDepSpec(tr1::shared_ptr<const PackageDepSpec> spec);
+ BlockDepSpec(std::tr1::shared_ptr<const PackageDepSpec> spec);
///\}
/**
* Fetch the spec we're blocking.
*/
- tr1::shared_ptr<const PackageDepSpec> blocked_spec() const;
+ std::tr1::shared_ptr<const PackageDepSpec> blocked_spec() const;
- virtual tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ virtual std::tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
};
/**
@@ -746,18 +747,18 @@ namespace paludis
///\name Contained labels
///\{
- void add_label(const tr1::shared_ptr<const typename SpecTree_::BasicNode> &);
+ void add_label(const std::tr1::shared_ptr<const typename SpecTree_::BasicNode> &);
struct ConstIteratorTag;
typedef WrappedForwardIterator<ConstIteratorTag,
- const tr1::shared_ptr<const typename SpecTree_::BasicNode> > ConstIterator;
+ const std::tr1::shared_ptr<const typename SpecTree_::BasicNode> > ConstIterator;
ConstIterator begin() const PALUDIS_ATTRIBUTE((warn_unused_result));
ConstIterator end() const PALUDIS_ATTRIBUTE((warn_unused_result));
///\}
- virtual tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ virtual std::tr1::shared_ptr<DepSpec> clone() const PALUDIS_ATTRIBUTE((warn_unused_result));
};
}
diff --git a/paludis/dep_spec_TEST.cc b/paludis/dep_spec_TEST.cc
index 38d5c40..ba228a7 100644
--- a/paludis/dep_spec_TEST.cc
+++ b/paludis/dep_spec_TEST.cc
@@ -42,7 +42,7 @@ namespace test_cases
void run()
{
- tr1::shared_ptr<PackageDepSpec> x(new PackageDepSpec(make_package_dep_spec()));
+ std::tr1::shared_ptr<PackageDepSpec> x(new PackageDepSpec(make_package_dep_spec()));
TEST_CHECK(0 == x->as_conditional_dep_spec());
}
} test_dep_spec_as;
@@ -76,14 +76,14 @@ namespace test_cases
{
PackageDepSpec a(parse_user_package_dep_spec("cat/pkg:1::repo[=1|>3.2][foo]", UserPackageDepSpecOptions()));
- tr1::shared_ptr<PackageDepSpec> b(tr1::static_pointer_cast<PackageDepSpec>(a.clone()));
+ std::tr1::shared_ptr<PackageDepSpec> b(std::tr1::static_pointer_cast<PackageDepSpec>(a.clone()));
TEST_CHECK_STRINGIFY_EQUAL(a, *b);
- tr1::shared_ptr<PackageDepSpec> c(tr1::static_pointer_cast<PackageDepSpec>(a.clone()));
+ std::tr1::shared_ptr<PackageDepSpec> c(std::tr1::static_pointer_cast<PackageDepSpec>(a.clone()));
TEST_CHECK_STRINGIFY_EQUAL(a, *c);
BlockDepSpec d(c);
- tr1::shared_ptr<BlockDepSpec> e(tr1::static_pointer_cast<BlockDepSpec>(d.clone()));
+ std::tr1::shared_ptr<BlockDepSpec> e(std::tr1::static_pointer_cast<BlockDepSpec>(d.clone()));
TEST_CHECK_STRINGIFY_EQUAL(*(d.blocked_spec()), *(e->blocked_spec()));
}
} test_dep_spec_clone;
diff --git a/paludis/dep_spec_flattener.cc b/paludis/dep_spec_flattener.cc
index 3b39a82..cea26c2 100644
--- a/paludis/dep_spec_flattener.cc
+++ b/paludis/dep_spec_flattener.cc
@@ -41,7 +41,7 @@ namespace paludis
{
const Environment * const env;
- std::list<tr1::shared_ptr<const Item_> > specs;
+ std::list<std::tr1::shared_ptr<const Item_> > specs;
Implementation(const Environment * const e) :
env(e)
@@ -122,7 +122,7 @@ dep_spec_flattener_internals::VisitNamedSetDepSpec<Heirarchy_, Item_, true>::vis
Context context("When expanding named set '" + stringify(s) + "':");
- tr1::shared_ptr<const SetSpecTree::ConstItem> set(f->_imp->env->set(s.name()));
+ std::tr1::shared_ptr<const SetSpecTree::ConstItem> set(f->_imp->env->set(s.name()));
if (! set)
{
@@ -145,7 +145,7 @@ template <typename Heirarchy_, typename Item_>
void
DepSpecFlattener<Heirarchy_, Item_>::visit_leaf(const Item_ & p)
{
- _imp->specs.push_back(tr1::static_pointer_cast<const Item_>(p.clone()));
+ _imp->specs.push_back(std::tr1::static_pointer_cast<const Item_>(p.clone()));
}
template class DepSpecFlattener<ProvideSpecTree, PackageDepSpec>;
diff --git a/paludis/dep_spec_flattener.hh b/paludis/dep_spec_flattener.hh
index d172af6..8d4fc68 100644
--- a/paludis/dep_spec_flattener.hh
+++ b/paludis/dep_spec_flattener.hh
@@ -26,11 +26,11 @@
#include <paludis/util/attributes.hh>
#include <paludis/util/instantiation_policy.hh>
#include <paludis/util/private_implementation_pattern.hh>
-#include <paludis/util/tr1_memory.hh>
#include <paludis/util/visitor.hh>
#include <paludis/util/no_type.hh>
#include <paludis/util/wrapped_forward_iterator-fwd.hh>
#include <paludis/util/sr.hh>
+#include <tr1/memory>
/** \file
* Declarations for DepSpecFlattener.
@@ -186,7 +186,7 @@ namespace paludis
///\{
struct ConstIteratorTag;
- typedef WrappedForwardIterator<ConstIteratorTag, const tr1::shared_ptr<const Item_> > ConstIterator;
+ typedef WrappedForwardIterator<ConstIteratorTag, const std::tr1::shared_ptr<const Item_> > ConstIterator;
ConstIterator begin() const;
ConstIterator end() const;
diff --git a/paludis/dep_tag.cc b/paludis/dep_tag.cc
index b212d73..d6efe16 100644
--- a/paludis/dep_tag.cc
+++ b/paludis/dep_tag.cc
@@ -30,7 +30,7 @@
using namespace paludis;
-template class VirtualConstructor<std::string, tr1::shared_ptr<const DepTagCategory> (*) (),
+template class VirtualConstructor<std::string, std::tr1::shared_ptr<const DepTagCategory> (*) (),
virtual_constructor_not_found::ThrowException<NoSuchDepTagCategory> >;
template class ConstVisitor<DepTagVisitorTypes>;
@@ -56,10 +56,10 @@ template class WrappedOutputIterator<Set<DepTagEntry>::InserterTag, DepTagEntry>
namespace
{
- tr1::shared_ptr<const DepTagCategory>
+ std::tr1::shared_ptr<const DepTagCategory>
make_glsa_dep_tag()
{
- return tr1::shared_ptr<const DepTagCategory>(new DepTagCategory(
+ return std::tr1::shared_ptr<const DepTagCategory>(new DepTagCategory(
true,
"glsa",
"Security advisories",
@@ -67,10 +67,10 @@ namespace
"Please read the advisories carefully and take appropriate action."));
}
- tr1::shared_ptr<const DepTagCategory>
+ std::tr1::shared_ptr<const DepTagCategory>
make_general_set_dep_tag()
{
- return tr1::shared_ptr<const DepTagCategory>(new DepTagCategory(
+ return std::tr1::shared_ptr<const DepTagCategory>(new DepTagCategory(
true,
"general",
"General sets",
@@ -78,10 +78,10 @@ namespace
""));
}
- tr1::shared_ptr<const DepTagCategory>
+ std::tr1::shared_ptr<const DepTagCategory>
make_dependency_set_dep_tag()
{
- return tr1::shared_ptr<const DepTagCategory>(new DepTagCategory(
+ return std::tr1::shared_ptr<const DepTagCategory>(new DepTagCategory(
false,
"dependency",
"Dependencies",
@@ -89,10 +89,10 @@ namespace
""));
}
- tr1::shared_ptr<const DepTagCategory>
+ std::tr1::shared_ptr<const DepTagCategory>
make_target_dep_tag()
{
- return tr1::shared_ptr<const DepTagCategory>(new DepTagCategory(
+ return std::tr1::shared_ptr<const DepTagCategory>(new DepTagCategory(
false,
"target",
"Targets",
@@ -355,23 +355,23 @@ namespace paludis
mutable Mutex mutex;
mutable std::string str;
- tr1::shared_ptr<const PackageID> id;
- const tr1::shared_ptr<PackageDepSpec> spec;
- const tr1::shared_ptr<const DependencySpecTree::ConstItem> cond;
+ std::tr1::shared_ptr<const PackageID> id;
+ const std::tr1::shared_ptr<PackageDepSpec> spec;
+ const std::tr1::shared_ptr<const DependencySpecTree::ConstItem> cond;
- Implementation(const tr1::shared_ptr<const PackageID> & i,
- const PackageDepSpec & d, const tr1::shared_ptr<const DependencySpecTree::ConstItem> & s) :
+ Implementation(const std::tr1::shared_ptr<const PackageID> & i,
+ const PackageDepSpec & d, const std::tr1::shared_ptr<const DependencySpecTree::ConstItem> & s) :
id(i),
- spec(tr1::static_pointer_cast<PackageDepSpec>(d.clone())),
+ spec(std::tr1::static_pointer_cast<PackageDepSpec>(d.clone())),
cond(s)
{
- spec->set_tag(tr1::shared_ptr<const DepTag>());
+ spec->set_tag(std::tr1::shared_ptr<const DepTag>());
}
};
}
-DependencyDepTag::DependencyDepTag(const tr1::shared_ptr<const PackageID> & i, const PackageDepSpec & d,
- const tr1::shared_ptr<const DependencySpecTree::ConstItem> & s) :
+DependencyDepTag::DependencyDepTag(const std::tr1::shared_ptr<const PackageID> & i, const PackageDepSpec & d,
+ const std::tr1::shared_ptr<const DependencySpecTree::ConstItem> & s) :
PrivateImplementationPattern<DependencyDepTag>(new Implementation<DependencyDepTag>(i, d, s))
{
}
@@ -392,19 +392,19 @@ DependencyDepTag::category() const
return "dependency";
}
-const tr1::shared_ptr<const PackageID>
+const std::tr1::shared_ptr<const PackageID>
DependencyDepTag::package_id() const
{
return _imp->id;
}
-const tr1::shared_ptr<const PackageDepSpec>
+const std::tr1::shared_ptr<const PackageDepSpec>
DependencyDepTag::dependency() const
{
return _imp->spec;
}
-const tr1::shared_ptr<const DependencySpecTree::ConstItem>
+const std::tr1::shared_ptr<const DependencySpecTree::ConstItem>
DependencyDepTag::conditions() const
{
return _imp->cond;
diff --git a/paludis/dep_tag.hh b/paludis/dep_tag.hh
index 891d00d..b056e93 100644
--- a/paludis/dep_tag.hh
+++ b/paludis/dep_tag.hh
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -47,7 +47,7 @@
#include <paludis/util/operators.hh>
#include <string>
-#include <paludis/util/tr1_memory.hh>
+#include <tr1/memory>
namespace paludis
{
@@ -159,7 +159,7 @@ namespace paludis
* \nosubgrouping
*/
class PALUDIS_VISIBLE DepTagCategoryMaker :
- public VirtualConstructor<std::string, tr1::shared_ptr<const DepTagCategory> (*) (),
+ public VirtualConstructor<std::string, std::tr1::shared_ptr<const DepTagCategory> (*) (),
virtual_constructor_not_found::ThrowException<NoSuchDepTagCategory> >,
public InstantiationPolicy<DepTagCategoryMaker, instantiation_method::SingletonTag>
{
@@ -308,8 +308,8 @@ namespace paludis
///\name Basic operations
///\{
- DependencyDepTag(const tr1::shared_ptr<const PackageID> &, const PackageDepSpec &,
- const tr1::shared_ptr<const DependencySpecTree::ConstItem> &);
+ DependencyDepTag(const std::tr1::shared_ptr<const PackageID> &, const PackageDepSpec &,
+ const std::tr1::shared_ptr<const DependencySpecTree::ConstItem> &);
~DependencyDepTag();
@@ -322,18 +322,18 @@ namespace paludis
/**
* The PackageID that contains our dependency.
*/
- const tr1::shared_ptr<const PackageID> package_id() const;
+ const std::tr1::shared_ptr<const PackageID> package_id() const;
/**
* The PackageDepSpec that pulled us in.
*/
- const tr1::shared_ptr<const PackageDepSpec> dependency() const;
+ const std::tr1::shared_ptr<const PackageDepSpec> dependency() const;
/**
* The AnyDepSpec instances and ConditionalDepSpec instances that our dependency
* is conditional upon.
*/
- const tr1::shared_ptr<const DependencySpecTree::ConstItem> conditions() const;
+ const std::tr1::shared_ptr<const DependencySpecTree::ConstItem> conditions() const;
};
/**
diff --git a/paludis/dep_tag.sr b/paludis/dep_tag.sr
index 2daf201..01ffcff 100644
--- a/paludis/dep_tag.sr
+++ b/paludis/dep_tag.sr
@@ -2,7 +2,7 @@ make_class_DepTagEntry()
{
visible
- key tag "tr1::shared_ptr<const DepTag>"
+ key tag "std::tr1::shared_ptr<const DepTag>"
key generation long
allow_named_args
diff --git a/paludis/distribution.cc b/paludis/distribution.cc
index 75dcbd8..8e98cb0 100644
--- a/paludis/distribution.cc
+++ b/paludis/distribution.cc
@@ -18,7 +18,6 @@
*/
#include <paludis/distribution.hh>
-#include <paludis/hashed_containers.hh>
#include <paludis/util/config_file.hh>
#include <paludis/util/destringify.hh>
#include <paludis/util/dir_iterator.hh>
@@ -30,6 +29,8 @@
#include <paludis/util/stringify.hh>
#include <paludis/util/private_implementation_pattern-impl.hh>
#include <paludis/util/kc.hh>
+#include <paludis/util/hashes.hh>
+#include <tr1/unordered_map>
using namespace paludis;
@@ -40,12 +41,14 @@ DistributionConfigurationError::DistributionConfigurationError(const std::string
{
}
+typedef std::tr1::unordered_map<std::string, std::tr1::shared_ptr<const Distribution>, Hash<std::string> > DistributionHash;
+
namespace paludis
{
template <>
struct Implementation<DistributionData>
{
- MakeHashedMap<std::string, tr1::shared_ptr<const Distribution> >::Type values;
+ DistributionHash values;
Implementation()
{
@@ -96,10 +99,10 @@ DistributionData::~DistributionData()
{
}
-tr1::shared_ptr<const Distribution>
+std::tr1::shared_ptr<const Distribution>
DistributionData::distribution_from_string(const std::string & s) const
{
- MakeHashedMap<std::string, tr1::shared_ptr<const Distribution> >::Type::const_iterator i(_imp->values.find(s));
+ DistributionHash::const_iterator i(_imp->values.find(s));
if (i == _imp->values.end())
throw DistributionConfigurationError("No distribution configuration found for '" + s + "'");
else
diff --git a/paludis/distribution.hh b/paludis/distribution.hh
index c7fb3d0..9ad5ea7 100644
--- a/paludis/distribution.hh
+++ b/paludis/distribution.hh
@@ -25,7 +25,7 @@
#include <paludis/util/exception.hh>
#include <paludis/util/private_implementation_pattern.hh>
#include <paludis/util/instantiation_policy.hh>
-#include <paludis/util/tr1_memory.hh>
+#include <tr1/memory>
/** \file
* Declarations for distributions.
@@ -87,7 +87,7 @@ namespace paludis
/**
* Fetch a distribution from a named string.
*/
- tr1::shared_ptr<const Distribution> distribution_from_string(const std::string &) const;
+ std::tr1::shared_ptr<const Distribution> distribution_from_string(const std::string &) const;
};
}
diff --git a/paludis/environment.hh b/paludis/environment.hh
index 2d7351f..a691f3a 100644
--- a/paludis/environment.hh
+++ b/paludis/environment.hh
@@ -93,7 +93,7 @@ namespace paludis
* the specified prefix or merely all enabled use flags. It is not safe to assume
* that all flags in the returned value will be enabled for the specified package.
*/
- virtual tr1::shared_ptr<const UseFlagNameSet> known_use_expand_names(
+ virtual std::tr1::shared_ptr<const UseFlagNameSet> known_use_expand_names(
const UseFlagName &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
@@ -119,7 +119,7 @@ namespace paludis
* Used by PackageID implementations. Generally PackageID's masks methods
* should be used rather than calling this directly.
*/
- virtual bool accept_keywords(tr1::shared_ptr<const KeywordNameSet>, const PackageID &) const
+ virtual bool accept_keywords(std::tr1::shared_ptr<const KeywordNameSet>, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
/**
@@ -130,7 +130,7 @@ namespace paludis
* Used by PackageID implementations. Generally PackageID's masks methods
* should be used rather than calling this directly.
*/
- virtual const tr1::shared_ptr<const Mask> mask_for_breakage(const PackageID &) const
+ virtual const std::tr1::shared_ptr<const Mask> mask_for_breakage(const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
/**
@@ -141,7 +141,7 @@ namespace paludis
* Used by PackageID implementations. Generally PackageID's masks methods
* should be used rather than calling this directly.
*/
- virtual const tr1::shared_ptr<const Mask> mask_for_user(const PackageID &) const
+ virtual const std::tr1::shared_ptr<const Mask> mask_for_user(const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
/**
@@ -161,10 +161,10 @@ namespace paludis
///\name Database-related functions
///\{
- virtual tr1::shared_ptr<PackageDatabase> package_database()
+ virtual std::tr1::shared_ptr<PackageDatabase> package_database()
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
- virtual tr1::shared_ptr<const PackageDatabase> package_database() const
+ virtual std::tr1::shared_ptr<const PackageDatabase> package_database() const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
///\}
@@ -176,25 +176,25 @@ namespace paludis
* Return a collection of bashrc files to be used by the various components
* that are implemented in bash.
*/
- virtual tr1::shared_ptr<const FSEntrySequence> bashrc_files() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> bashrc_files() const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
/**
* Return directories to search for syncer scripts.
*/
- virtual tr1::shared_ptr<const FSEntrySequence> syncers_dirs() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> syncers_dirs() const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
/**
* Return directories to search for fetcher scripts.
*/
- virtual tr1::shared_ptr<const FSEntrySequence> fetchers_dirs() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> fetchers_dirs() const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
/**
* Return directories to search for hooks.
*/
- virtual tr1::shared_ptr<const FSEntrySequence> hook_dirs() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> hook_dirs() const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
/**
@@ -240,7 +240,7 @@ namespace paludis
/**
* Return the mirror URI prefixes for a named mirror.
*/
- virtual tr1::shared_ptr<const MirrorsSequence> mirrors(const std::string &) const
+ virtual std::tr1::shared_ptr<const MirrorsSequence> mirrors(const std::string &) const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
///\}
@@ -251,7 +251,7 @@ namespace paludis
/**
* Return all known named sets.
*/
- virtual tr1::shared_ptr<const SetNameSet> set_names() const
+ virtual std::tr1::shared_ptr<const SetNameSet> set_names() const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
/**
@@ -259,7 +259,7 @@ namespace paludis
*
* If the named set is not known, returns a zero pointer.
*/
- virtual tr1::shared_ptr<SetSpecTree::ConstItem> set(const SetName &) const
+ virtual std::tr1::shared_ptr<SetSpecTree::ConstItem> set(const SetName &) const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
///\}
@@ -270,7 +270,7 @@ namespace paludis
/**
* Default destination candidates for installing packages.
*/
- virtual tr1::shared_ptr<const DestinationsSet> default_destinations() const
+ virtual std::tr1::shared_ptr<const DestinationsSet> default_destinations() const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
///\}
diff --git a/paludis/environment_implementation.cc b/paludis/environment_implementation.cc
index 235cfc8..e373927 100644
--- a/paludis/environment_implementation.cc
+++ b/paludis/environment_implementation.cc
@@ -40,25 +40,25 @@ EnvironmentImplementation::~EnvironmentImplementation()
}
-tr1::shared_ptr<const FSEntrySequence>
+std::tr1::shared_ptr<const FSEntrySequence>
EnvironmentImplementation::bashrc_files() const
{
return make_shared_ptr(new FSEntrySequence);
}
-tr1::shared_ptr<const FSEntrySequence>
+std::tr1::shared_ptr<const FSEntrySequence>
EnvironmentImplementation::syncers_dirs() const
{
- tr1::shared_ptr<FSEntrySequence> result(new FSEntrySequence);
+ std::tr1::shared_ptr<FSEntrySequence> result(new FSEntrySequence);
result->push_back(FSEntry(DATADIR "/paludis/syncers"));
result->push_back(FSEntry(LIBEXECDIR "/paludis/syncers"));
return result;
}
-tr1::shared_ptr<const FSEntrySequence>
+std::tr1::shared_ptr<const FSEntrySequence>
EnvironmentImplementation::fetchers_dirs() const
{
- tr1::shared_ptr<FSEntrySequence> result(new FSEntrySequence);
+ std::tr1::shared_ptr<FSEntrySequence> result(new FSEntrySequence);
std::string fetchers_dir(getenv_with_default("PALUDIS_FETCHERS_DIR", ""));
if (fetchers_dir.empty())
{
@@ -70,10 +70,10 @@ EnvironmentImplementation::fetchers_dirs() const
return result;
}
-tr1::shared_ptr<const DestinationsSet>
+std::tr1::shared_ptr<const DestinationsSet>
EnvironmentImplementation::default_destinations() const
{
- tr1::shared_ptr<DestinationsSet> result(new DestinationsSet);
+ std::tr1::shared_ptr<DestinationsSet> result(new DestinationsSet);
for (PackageDatabase::RepositoryConstIterator r(package_database()->begin_repositories()),
r_end(package_database()->end_repositories()) ;
@@ -85,11 +85,11 @@ EnvironmentImplementation::default_destinations() const
return result;
}
-tr1::shared_ptr<SetSpecTree::ConstItem>
+std::tr1::shared_ptr<SetSpecTree::ConstItem>
EnvironmentImplementation::set(const SetName & s) const
{
{
- tr1::shared_ptr<SetSpecTree::ConstItem> l(local_set(s));
+ std::tr1::shared_ptr<SetSpecTree::ConstItem> l(local_set(s));
if (l)
{
Log::get_instance()->message("environment_implementation.local_set", ll_debug, lc_context) << "Set '" << s << "' is a local set";
@@ -97,13 +97,13 @@ EnvironmentImplementation::set(const SetName & s) const
}
}
- tr1::shared_ptr<ConstTreeSequence<SetSpecTree, AllDepSpec> > result;
+ std::tr1::shared_ptr<ConstTreeSequence<SetSpecTree, AllDepSpec> > result;
/* these sets always exist, even if empty */
if (s.data() == "everything" || s.data() == "system" || s.data() == "world" || s.data() == "security")
{
Log::get_instance()->message("environment_implementation.standard_set", ll_debug, lc_context) << "Set '" << s << "' is a standard set";
- result.reset(new ConstTreeSequence<SetSpecTree, AllDepSpec>(tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
+ result.reset(new ConstTreeSequence<SetSpecTree, AllDepSpec>(std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
}
for (PackageDatabase::RepositoryConstIterator r(package_database()->begin_repositories()),
@@ -113,13 +113,13 @@ EnvironmentImplementation::set(const SetName & s) const
if (! (**r)[k::sets_interface()])
continue;
- tr1::shared_ptr<SetSpecTree::ConstItem> add((**r)[k::sets_interface()]->package_set(s));
+ std::tr1::shared_ptr<SetSpecTree::ConstItem> add((**r)[k::sets_interface()]->package_set(s));
if (add)
{
Log::get_instance()->message("environment_implementation.set_found_in_repository", ll_debug, lc_context)
<< "Set '" << s << "' found in '" << (*r)->name() << "'";
if (! result)
- result.reset(new ConstTreeSequence<SetSpecTree, AllDepSpec>(tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
+ result.reset(new ConstTreeSequence<SetSpecTree, AllDepSpec>(std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
result->add(add);
}
}
@@ -130,7 +130,7 @@ EnvironmentImplementation::set(const SetName & s) const
if ("world" == s.data())
{
- tr1::shared_ptr<SetSpecTree::ConstItem> w(world_set());
+ std::tr1::shared_ptr<SetSpecTree::ConstItem> w(world_set());
if (w)
result->add(w);
}
@@ -176,7 +176,7 @@ EnvironmentImplementation::default_distribution() const
return result;
}
-tr1::shared_ptr<const SetNameSet>
+std::tr1::shared_ptr<const SetNameSet>
EnvironmentImplementation::set_names() const
{
return make_shared_ptr(new SetNameSet);
diff --git a/paludis/environment_implementation.hh b/paludis/environment_implementation.hh
index 1d7b0b7..a463747 100644
--- a/paludis/environment_implementation.hh
+++ b/paludis/environment_implementation.hh
@@ -50,10 +50,10 @@ namespace paludis
public Environment
{
protected:
- virtual tr1::shared_ptr<SetSpecTree::ConstItem> local_set(const SetName &) const
+ virtual std::tr1::shared_ptr<SetSpecTree::ConstItem> local_set(const SetName &) const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
- virtual tr1::shared_ptr<SetSpecTree::ConstItem> world_set() const
+ virtual std::tr1::shared_ptr<SetSpecTree::ConstItem> world_set() const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
public:
@@ -67,22 +67,22 @@ namespace paludis
virtual bool query_use(const UseFlagName &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const FSEntrySequence> bashrc_files() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> bashrc_files() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const FSEntrySequence> syncers_dirs() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> syncers_dirs() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const FSEntrySequence> fetchers_dirs() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> fetchers_dirs() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const SetNameSet> set_names() const
+ virtual std::tr1::shared_ptr<const SetNameSet> set_names() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<SetSpecTree::ConstItem> set(const SetName &) const
+ virtual std::tr1::shared_ptr<SetSpecTree::ConstItem> set(const SetName &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const DestinationsSet> default_destinations() const
+ virtual std::tr1::shared_ptr<const DestinationsSet> default_destinations() const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual std::string default_distribution() const
diff --git a/paludis/environment_maker.cc b/paludis/environment_maker.cc
index 51b5e40..5cd3b4f 100644
--- a/paludis/environment_maker.cc
+++ b/paludis/environment_maker.cc
@@ -37,7 +37,7 @@
using namespace paludis;
template class VirtualConstructor<std::string,
- tr1::shared_ptr<Environment> (*) (const std::string &),
+ std::tr1::shared_ptr<Environment> (*) (const std::string &),
virtual_constructor_not_found::ThrowException<NoSuchEnvironmentTypeError> >;
template class InstantiationPolicy<EnvironmentMaker, instantiation_method::SingletonTag>;
@@ -135,7 +135,7 @@ EnvironmentMaker::~EnvironmentMaker()
{
}
-tr1::shared_ptr<Environment>
+std::tr1::shared_ptr<Environment>
EnvironmentMaker::make_from_spec(const std::string & s) const
{
Context context("When making environment from specification '" + s + "':");
diff --git a/paludis/environment_maker.hh b/paludis/environment_maker.hh
index c3cf3a6..2dc9b88 100644
--- a/paludis/environment_maker.hh
+++ b/paludis/environment_maker.hh
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007 Ciaran McCreesh
+ * Copyright (c) 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -131,7 +131,7 @@ namespace paludis
*/
class PALUDIS_VISIBLE EnvironmentMaker :
public VirtualConstructor<std::string,
- tr1::shared_ptr<Environment> (*) (const std::string &),
+ std::tr1::shared_ptr<Environment> (*) (const std::string &),
virtual_constructor_not_found::ThrowException<NoSuchEnvironmentTypeError> >,
public InstantiationPolicy<EnvironmentMaker, instantiation_method::SingletonTag>,
private PrivateImplementationPattern<EnvironmentMaker>
@@ -171,7 +171,7 @@ namespace paludis
* \see Environment
* \ingroup g_environment
*/
- tr1::shared_ptr<Environment> make_from_spec(const std::string & spec) const;
+ std::tr1::shared_ptr<Environment> make_from_spec(const std::string & spec) const;
};
}
diff --git a/paludis/environments/adapted/adapted_environment.cc b/paludis/environments/adapted/adapted_environment.cc
index 17e67cf..046a6b6 100644
--- a/paludis/environments/adapted/adapted_environment.cc
+++ b/paludis/environments/adapted/adapted_environment.cc
@@ -18,34 +18,35 @@
*/
#include "adapted_environment.hh"
-#include <paludis/hashed_containers.hh>
#include <paludis/dep_spec.hh>
#include <paludis/hook.hh>
#include <paludis/util/stringify.hh>
#include <paludis/util/fs_entry.hh>
#include <paludis/util/private_implementation_pattern-impl.hh>
+#include <paludis/util/hashes.hh>
#include <paludis/match_package.hh>
+#include <tr1/unordered_map>
using namespace paludis;
-typedef MakeHashedMultiMap<UseFlagName, std::pair<tr1::shared_ptr<const PackageDepSpec>, UseFlagState> >::Type Use;
+typedef std::tr1::unordered_multimap<UseFlagName, std::pair<std::tr1::shared_ptr<const PackageDepSpec>, UseFlagState>, Hash<UseFlagName> > Use;
namespace paludis
{
template<>
struct Implementation<AdaptedEnvironment>
{
- tr1::shared_ptr<Environment> env;
+ std::tr1::shared_ptr<Environment> env;
Use use;
- Implementation(tr1::shared_ptr<Environment> e) :
+ Implementation(std::tr1::shared_ptr<Environment> e) :
env(e)
{
}
};
}
-AdaptedEnvironment::AdaptedEnvironment(tr1::shared_ptr<Environment> e) :
+AdaptedEnvironment::AdaptedEnvironment(std::tr1::shared_ptr<Environment> e) :
PrivateImplementationPattern<AdaptedEnvironment>(new Implementation<AdaptedEnvironment>(e))
{
}
@@ -55,7 +56,7 @@ AdaptedEnvironment::~AdaptedEnvironment()
}
void
-AdaptedEnvironment::adapt_use(tr1::shared_ptr<const PackageDepSpec> p,
+AdaptedEnvironment::adapt_use(std::tr1::shared_ptr<const PackageDepSpec> p,
const UseFlagName & u, const UseFlagState s)
{
_imp->use.insert(std::make_pair(u, std::make_pair(p, s)));
@@ -67,13 +68,13 @@ AdaptedEnvironment::clear_adaptions()
_imp.reset(new Implementation<AdaptedEnvironment>(_imp->env));
}
-tr1::shared_ptr<PackageDatabase>
+std::tr1::shared_ptr<PackageDatabase>
AdaptedEnvironment::package_database()
{
return _imp->env->package_database();
}
-tr1::shared_ptr<const PackageDatabase>
+std::tr1::shared_ptr<const PackageDatabase>
AdaptedEnvironment::package_database() const
{
return _imp->env->package_database();
@@ -106,7 +107,7 @@ AdaptedEnvironment::query_use(const UseFlagName & u, const PackageID & e) const
throw InternalError(PALUDIS_HERE, "Bad state");
}
-tr1::shared_ptr<const UseFlagNameSet>
+std::tr1::shared_ptr<const UseFlagNameSet>
AdaptedEnvironment::known_use_expand_names(const UseFlagName & u, const PackageID & e) const
{
return _imp->env->known_use_expand_names(u, e);
@@ -119,30 +120,30 @@ AdaptedEnvironment::accept_license(const std::string & l, const PackageID & e) c
}
bool
-AdaptedEnvironment::accept_keywords(tr1::shared_ptr<const KeywordNameSet> k, const PackageID & e) const
+AdaptedEnvironment::accept_keywords(std::tr1::shared_ptr<const KeywordNameSet> k, const PackageID & e) const
{
return _imp->env->accept_keywords(k, e);
}
-tr1::shared_ptr<const FSEntrySequence>
+std::tr1::shared_ptr<const FSEntrySequence>
AdaptedEnvironment::bashrc_files() const
{
return _imp->env->bashrc_files();
}
-tr1::shared_ptr<const FSEntrySequence>
+std::tr1::shared_ptr<const FSEntrySequence>
AdaptedEnvironment::syncers_dirs() const
{
return _imp->env->syncers_dirs();
}
-tr1::shared_ptr<const FSEntrySequence>
+std::tr1::shared_ptr<const FSEntrySequence>
AdaptedEnvironment::fetchers_dirs() const
{
return _imp->env->fetchers_dirs();
}
-tr1::shared_ptr<const FSEntrySequence>
+std::tr1::shared_ptr<const FSEntrySequence>
AdaptedEnvironment::hook_dirs() const
{
return _imp->env->hook_dirs();
@@ -178,25 +179,25 @@ AdaptedEnvironment::reduced_gid() const
return _imp->env->reduced_gid();
}
-tr1::shared_ptr<const MirrorsSequence>
+std::tr1::shared_ptr<const MirrorsSequence>
AdaptedEnvironment::mirrors(const std::string & m) const
{
return _imp->env->mirrors(m);
}
-tr1::shared_ptr<const SetNameSet>
+std::tr1::shared_ptr<const SetNameSet>
AdaptedEnvironment::set_names() const
{
return _imp->env->set_names();
}
-tr1::shared_ptr<SetSpecTree::ConstItem>
+std::tr1::shared_ptr<SetSpecTree::ConstItem>
AdaptedEnvironment::set(const SetName & s) const
{
return _imp->env->set(s);
}
-tr1::shared_ptr<const DestinationsSet>
+std::tr1::shared_ptr<const DestinationsSet>
AdaptedEnvironment::default_destinations() const
{
return _imp->env->default_destinations();
@@ -214,13 +215,13 @@ AdaptedEnvironment::default_distribution() const
return _imp->env->default_distribution();
}
-const tr1::shared_ptr<const Mask>
+const std::tr1::shared_ptr<const Mask>
AdaptedEnvironment::mask_for_breakage(const PackageID & id) const
{
return _imp->env->mask_for_breakage(id);
}
-const tr1::shared_ptr<const Mask>
+const std::tr1::shared_ptr<const Mask>
AdaptedEnvironment::mask_for_user(const PackageID & id) const
{
return _imp->env->mask_for_user(id);
diff --git a/paludis/environments/adapted/adapted_environment.hh b/paludis/environments/adapted/adapted_environment.hh
index e64d0ff..a4861fa 100644
--- a/paludis/environments/adapted/adapted_environment.hh
+++ b/paludis/environments/adapted/adapted_environment.hh
@@ -40,7 +40,7 @@ namespace paludis
private PrivateImplementationPattern<AdaptedEnvironment>
{
public:
- AdaptedEnvironment(tr1::shared_ptr<Environment>);
+ AdaptedEnvironment(std::tr1::shared_ptr<Environment>);
~AdaptedEnvironment();
///\name Adapting methods
@@ -49,7 +49,7 @@ namespace paludis
/**
* Set the state of a USE flag for the given PackageDepSpec.
*/
- void adapt_use(tr1::shared_ptr<const PackageDepSpec>, const UseFlagName &, const UseFlagState);
+ void adapt_use(std::tr1::shared_ptr<const PackageDepSpec>, const UseFlagName &, const UseFlagState);
/**
* Clear all adaptions from this Environemnt.
@@ -61,32 +61,32 @@ namespace paludis
virtual bool query_use(const UseFlagName &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const UseFlagNameSet> known_use_expand_names(
+ virtual std::tr1::shared_ptr<const UseFlagNameSet> known_use_expand_names(
const UseFlagName &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual bool accept_license(const std::string &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual bool accept_keywords(tr1::shared_ptr<const KeywordNameSet>, const PackageID &) const
+ virtual bool accept_keywords(std::tr1::shared_ptr<const KeywordNameSet>, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<PackageDatabase> package_database()
+ virtual std::tr1::shared_ptr<PackageDatabase> package_database()
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const PackageDatabase> package_database() const
+ virtual std::tr1::shared_ptr<const PackageDatabase> package_database() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const FSEntrySequence> bashrc_files() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> bashrc_files() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const FSEntrySequence> syncers_dirs() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> syncers_dirs() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const FSEntrySequence> fetchers_dirs() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> fetchers_dirs() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const FSEntrySequence> hook_dirs() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> hook_dirs() const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual std::string paludis_command() const
@@ -100,15 +100,15 @@ namespace paludis
virtual gid_t reduced_gid() const;
- virtual tr1::shared_ptr<const MirrorsSequence> mirrors(const std::string &) const
+ virtual std::tr1::shared_ptr<const MirrorsSequence> mirrors(const std::string &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const SetNameSet> set_names() const
+ virtual std::tr1::shared_ptr<const SetNameSet> set_names() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<SetSpecTree::ConstItem> set(const SetName & id) const;
+ virtual std::tr1::shared_ptr<SetSpecTree::ConstItem> set(const SetName & id) const;
- virtual tr1::shared_ptr<const DestinationsSet> default_destinations() const
+ virtual std::tr1::shared_ptr<const DestinationsSet> default_destinations() const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual HookResult perform_hook(const Hook &) const
@@ -117,10 +117,10 @@ namespace paludis
virtual std::string default_distribution() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual const tr1::shared_ptr<const Mask> mask_for_breakage(const PackageID &) const
+ virtual const std::tr1::shared_ptr<const Mask> mask_for_breakage(const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual const tr1::shared_ptr<const Mask> mask_for_user(const PackageID &) const
+ virtual const std::tr1::shared_ptr<const Mask> mask_for_user(const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual bool unmasked_by_user(const PackageID &) const
diff --git a/paludis/environments/adapted/adapted_environment_TEST.cc b/paludis/environments/adapted/adapted_environment_TEST.cc
index e39cbf0..9446003 100644
--- a/paludis/environments/adapted/adapted_environment_TEST.cc
+++ b/paludis/environments/adapted/adapted_environment_TEST.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007 Ciaran McCreesh
+ * Copyright (c) 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -33,7 +33,7 @@ namespace test_cases
void run()
{
- AdaptedEnvironment e(tr1::shared_ptr<TestEnvironment>(new TestEnvironment));
+ AdaptedEnvironment e(std::tr1::shared_ptr<TestEnvironment>(new TestEnvironment));
}
} test_adapted_environment;
}
diff --git a/paludis/environments/no_config/no_config_environment.cc b/paludis/environments/no_config/no_config_environment.cc
index aa11d7c..03cb296 100644
--- a/paludis/environments/no_config/no_config_environment.cc
+++ b/paludis/environments/no_config/no_config_environment.cc
@@ -57,12 +57,12 @@ namespace paludis
bool accept_unstable;
bool is_vdb;
- tr1::shared_ptr<Repository> main_repo;
- tr1::shared_ptr<Repository> master_repo;
+ std::tr1::shared_ptr<Repository> main_repo;
+ std::tr1::shared_ptr<Repository> master_repo;
std::string paludis_command;
- tr1::shared_ptr<PackageDatabase> package_database;
+ std::tr1::shared_ptr<PackageDatabase> package_database;
Implementation(NoConfigEnvironment * const env, const no_config_environment::Params & params);
void initialise(NoConfigEnvironment * const env);
@@ -156,7 +156,7 @@ Implementation<NoConfigEnvironment>::initialise(NoConfigEnvironment * const env)
else
{
- tr1::shared_ptr<Map<std::string, std::string> > keys(new Map<std::string, std::string>);
+ std::tr1::shared_ptr<Map<std::string, std::string> > keys(new Map<std::string, std::string>);
if (params.extra_params)
std::copy(params.extra_params->begin(), params.extra_params->end(), keys->inserter());
@@ -175,7 +175,7 @@ Implementation<NoConfigEnvironment>::initialise(NoConfigEnvironment * const env)
}
}
- tr1::shared_ptr<Map<std::string, std::string> > keys( new Map<std::string, std::string>);
+ std::tr1::shared_ptr<Map<std::string, std::string> > keys( new Map<std::string, std::string>);
if (params.extra_params)
std::copy(params.extra_params->begin(), params.extra_params->end(), keys->inserter());
@@ -201,13 +201,13 @@ Implementation<NoConfigEnvironment>::initialise(NoConfigEnvironment * const env)
if ((*DistributionData::get_instance()->distribution_from_string(env->default_distribution()))[k::support_old_style_virtuals()])
package_database->add_repository(-2, RepositoryMaker::get_instance()->find_maker("virtuals")(env,
- tr1::shared_ptr<Map<std::string, std::string> >()));
+ std::tr1::shared_ptr<Map<std::string, std::string> >()));
}
else
{
Log::get_instance()->message("no_config_environment.vdb_detected", ll_debug, lc_context) << "VDB, using vdb_db";
- tr1::shared_ptr<Map<std::string, std::string> > keys(new Map<std::string, std::string>);
+ std::tr1::shared_ptr<Map<std::string, std::string> > keys(new Map<std::string, std::string>);
if (params.extra_params)
std::copy(params.extra_params->begin(), params.extra_params->end(), keys->inserter());
@@ -218,7 +218,7 @@ Implementation<NoConfigEnvironment>::initialise(NoConfigEnvironment * const env)
package_database->add_repository(1, RepositoryMaker::get_instance()->find_maker("vdb")(env, keys));
- tr1::shared_ptr<Map<std::string, std::string> > iv_keys(
+ std::tr1::shared_ptr<Map<std::string, std::string> > iv_keys(
new Map<std::string, std::string>);
iv_keys->insert("root", "/");
@@ -265,37 +265,37 @@ NoConfigEnvironment::set_accept_unstable(const bool value)
(*it)->invalidate_masks();
}
-tr1::shared_ptr<Repository>
+std::tr1::shared_ptr<Repository>
NoConfigEnvironment::main_repository()
{
return _imp->main_repo;
}
-tr1::shared_ptr<const Repository>
+std::tr1::shared_ptr<const Repository>
NoConfigEnvironment::main_repository() const
{
return _imp->main_repo;
}
-tr1::shared_ptr<Repository>
+std::tr1::shared_ptr<Repository>
NoConfigEnvironment::master_repository()
{
return _imp->master_repo;
}
-tr1::shared_ptr<const Repository>
+std::tr1::shared_ptr<const Repository>
NoConfigEnvironment::master_repository() const
{
return _imp->master_repo;
}
-tr1::shared_ptr<PackageDatabase>
+std::tr1::shared_ptr<PackageDatabase>
NoConfigEnvironment::package_database()
{
return _imp->package_database;
}
-tr1::shared_ptr<const PackageDatabase>
+std::tr1::shared_ptr<const PackageDatabase>
NoConfigEnvironment::package_database() const
{
return _imp->package_database;
@@ -314,7 +314,7 @@ NoConfigEnvironment::set_paludis_command(const std::string & s)
}
bool
-NoConfigEnvironment::accept_keywords(tr1::shared_ptr<const KeywordNameSet> keywords,
+NoConfigEnvironment::accept_keywords(std::tr1::shared_ptr<const KeywordNameSet> keywords,
const PackageID &) const
{
if (_imp->is_vdb)
@@ -360,16 +360,16 @@ NoConfigEnvironment::accept_keywords(tr1::shared_ptr<const KeywordNameSet> keywo
return false;
}
-tr1::shared_ptr<SetSpecTree::ConstItem>
+std::tr1::shared_ptr<SetSpecTree::ConstItem>
NoConfigEnvironment::local_set(const SetName &) const
{
- return tr1::shared_ptr<SetSpecTree::ConstItem>();
+ return std::tr1::shared_ptr<SetSpecTree::ConstItem>();
}
-tr1::shared_ptr<SetSpecTree::ConstItem>
+std::tr1::shared_ptr<SetSpecTree::ConstItem>
NoConfigEnvironment::world_set() const
{
- return tr1::shared_ptr<SetSpecTree::ConstItem>();
+ return std::tr1::shared_ptr<SetSpecTree::ConstItem>();
}
void
@@ -398,16 +398,16 @@ NoConfigEnvironment::unmasked_by_user(const PackageID &) const
return false;
}
-const tr1::shared_ptr<const Mask>
+const std::tr1::shared_ptr<const Mask>
NoConfigEnvironment::mask_for_breakage(const PackageID &) const
{
- return tr1::shared_ptr<const Mask>();
+ return std::tr1::shared_ptr<const Mask>();
}
-const tr1::shared_ptr<const Mask>
+const std::tr1::shared_ptr<const Mask>
NoConfigEnvironment::mask_for_user(const PackageID &) const
{
- return tr1::shared_ptr<const Mask>();
+ return std::tr1::shared_ptr<const Mask>();
}
uid_t
@@ -422,7 +422,7 @@ NoConfigEnvironment::reduced_gid() const
return getgid();
}
-tr1::shared_ptr<const MirrorsSequence>
+std::tr1::shared_ptr<const MirrorsSequence>
NoConfigEnvironment::mirrors(const std::string &) const
{
return make_shared_ptr(new MirrorsSequence);
@@ -446,13 +446,13 @@ NoConfigEnvironment::perform_hook(const Hook &) const
return HookResult(0, "");
}
-tr1::shared_ptr<const FSEntrySequence>
+std::tr1::shared_ptr<const FSEntrySequence>
NoConfigEnvironment::hook_dirs() const
{
return make_shared_ptr(new FSEntrySequence);
}
-tr1::shared_ptr<const UseFlagNameSet>
+std::tr1::shared_ptr<const UseFlagNameSet>
NoConfigEnvironment::known_use_expand_names(const UseFlagName &, const PackageID &) const
{
return make_shared_ptr(new UseFlagNameSet);
diff --git a/paludis/environments/no_config/no_config_environment.hh b/paludis/environments/no_config/no_config_environment.hh
index 1946be2..9e5d2c3 100644
--- a/paludis/environments/no_config/no_config_environment.hh
+++ b/paludis/environments/no_config/no_config_environment.hh
@@ -58,10 +58,10 @@ namespace paludis
private InstantiationPolicy<NoConfigEnvironment, instantiation_method::NonCopyableTag>
{
protected:
- virtual tr1::shared_ptr<SetSpecTree::ConstItem> local_set(const SetName &) const
+ virtual std::tr1::shared_ptr<SetSpecTree::ConstItem> local_set(const SetName &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<SetSpecTree::ConstItem> world_set() const
+ virtual std::tr1::shared_ptr<SetSpecTree::ConstItem> world_set() const
PALUDIS_ATTRIBUTE((warn_unused_result));
public:
@@ -95,29 +95,29 @@ namespace paludis
/**
* Fetch our 'main' repository.
*/
- tr1::shared_ptr<Repository> main_repository();
+ std::tr1::shared_ptr<Repository> main_repository();
/**
* Fetch our 'main' repository.
*/
- tr1::shared_ptr<const Repository> main_repository() const;
+ std::tr1::shared_ptr<const Repository> main_repository() const;
/**
* Fetch our 'master' repository (may be zero).
*/
- tr1::shared_ptr<Repository> master_repository();
+ std::tr1::shared_ptr<Repository> master_repository();
/**
* Fetch our 'master' repository (may be zero).
*/
- tr1::shared_ptr<const Repository> master_repository() const;
+ std::tr1::shared_ptr<const Repository> master_repository() const;
///\}
- virtual tr1::shared_ptr<PackageDatabase> package_database()
+ virtual std::tr1::shared_ptr<PackageDatabase> package_database()
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const PackageDatabase> package_database() const
+ virtual std::tr1::shared_ptr<const PackageDatabase> package_database() const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual std::string paludis_command() const
@@ -125,26 +125,26 @@ namespace paludis
virtual void set_paludis_command(const std::string &);
- virtual tr1::shared_ptr<const UseFlagNameSet> known_use_expand_names(
+ virtual std::tr1::shared_ptr<const UseFlagNameSet> known_use_expand_names(
const UseFlagName &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual bool accept_license(const std::string &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual bool accept_keywords(tr1::shared_ptr<const KeywordNameSet>, const PackageID &) const
+ virtual bool accept_keywords(std::tr1::shared_ptr<const KeywordNameSet>, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual const tr1::shared_ptr<const Mask> mask_for_breakage(const PackageID &) const
+ virtual const std::tr1::shared_ptr<const Mask> mask_for_breakage(const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual const tr1::shared_ptr<const Mask> mask_for_user(const PackageID &) const
+ virtual const std::tr1::shared_ptr<const Mask> mask_for_user(const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual bool unmasked_by_user(const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const FSEntrySequence> hook_dirs() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> hook_dirs() const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual const FSEntry root() const;
@@ -153,7 +153,7 @@ namespace paludis
virtual gid_t reduced_gid() const;
- virtual tr1::shared_ptr<const MirrorsSequence> mirrors(const std::string &) const
+ virtual std::tr1::shared_ptr<const MirrorsSequence> mirrors(const std::string &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual HookResult perform_hook(const Hook &) const
diff --git a/paludis/environments/no_config/no_config_environment.sr b/paludis/environments/no_config/no_config_environment.sr
index b5934fe..003b12d 100644
--- a/paludis/environments/no_config/no_config_environment.sr
+++ b/paludis/environments/no_config/no_config_environment.sr
@@ -11,7 +11,7 @@ make_class_Params()
key accept_unstable bool
key repository_type no_config_environment::RepositoryType
key master_repository_dir "FSEntry"
- key extra_params "tr1::shared_ptr<Map<std::string, std::string> >"
+ key extra_params "std::tr1::shared_ptr<Map<std::string, std::string> >"
allow_named_args
doxygen_comment << "END"
diff --git a/paludis/environments/no_config/no_config_environment_TEST.cc b/paludis/environments/no_config/no_config_environment_TEST.cc
index 8b38e9e..aff988f 100644
--- a/paludis/environments/no_config/no_config_environment_TEST.cc
+++ b/paludis/environments/no_config/no_config_environment_TEST.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -38,7 +38,7 @@ namespace test_cases
.accept_unstable(false)
.repository_type(no_config_environment::ncer_auto)
.disable_metadata_cache(false)
- .extra_params(tr1::shared_ptr<Map<std::string, std::string> >())
+ .extra_params(std::tr1::shared_ptr<Map<std::string, std::string> >())
.master_repository_dir(FSEntry("/var/empty")));
TEST_CHECK(e.package_database());
diff --git a/paludis/environments/paludis/bashable_conf.cc b/paludis/environments/paludis/bashable_conf.cc
index ea80181..69bf774 100644
--- a/paludis/environments/paludis/bashable_conf.cc
+++ b/paludis/environments/paludis/bashable_conf.cc
@@ -28,12 +28,12 @@
using namespace paludis;
using namespace paludis::paludis_environment;
-tr1::shared_ptr<LineConfigFile>
+std::tr1::shared_ptr<LineConfigFile>
paludis::paludis_environment::make_bashable_conf(const FSEntry & f)
{
Context context("When making a config file out of '" + stringify(f) + "':");
- tr1::shared_ptr<LineConfigFile> result;
+ std::tr1::shared_ptr<LineConfigFile> result;
if (is_file_with_extension(f, ".bash", IsFileWithOptions()))
{
diff --git a/paludis/environments/paludis/bashable_conf.hh b/paludis/environments/paludis/bashable_conf.hh
index ab91a12..f3819a8 100644
--- a/paludis/environments/paludis/bashable_conf.hh
+++ b/paludis/environments/paludis/bashable_conf.hh
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007 Ciaran McCreesh
+ * Copyright (c) 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -20,16 +20,15 @@
#ifndef PALUDIS_GUARD_PALUDIS_ENVIRONMENTS_PALUDIS_BASHABLE_CONF_HH
#define PALUDIS_GUARD_PALUDIS_ENVIRONMENTS_PALUDIS_BASHABLE_CONF_HH 1
-#include <paludis/util/tr1_memory.hh>
+#include <paludis/util/fs_entry-fwd.hh>
+#include <paludis/util/config_file-fwd.hh>
+#include <tr1/memory>
namespace paludis
{
- class LineConfigFile;
- class FSEntry;
-
namespace paludis_environment
{
- tr1::shared_ptr<LineConfigFile> make_bashable_conf(const FSEntry &);
+ std::tr1::shared_ptr<LineConfigFile> make_bashable_conf(const FSEntry &);
}
}
diff --git a/paludis/environments/paludis/keywords_conf.cc b/paludis/environments/paludis/keywords_conf.cc
index d785ac2..d2e6e16 100644
--- a/paludis/environments/paludis/keywords_conf.cc
+++ b/paludis/environments/paludis/keywords_conf.cc
@@ -19,7 +19,6 @@
#include "keywords_conf.hh"
#include <paludis/environment.hh>
-#include <paludis/hashed_containers.hh>
#include <paludis/name.hh>
#include <paludis/dep_spec.hh>
#include <paludis/user_dep_spec.hh>
@@ -36,6 +35,8 @@
#include <paludis/util/wrapped_forward_iterator.hh>
#include <paludis/util/mutex.hh>
#include <paludis/util/set.hh>
+#include <paludis/util/hashes.hh>
+#include <tr1/unordered_map>
#include <list>
#include <vector>
#include <map>
@@ -44,12 +45,12 @@ using namespace paludis;
using namespace paludis::paludis_environment;
typedef std::list<KeywordName> KeywordsList;
-typedef std::map<tr1::shared_ptr<const PackageDepSpec>, KeywordsList> PDSToKeywordsList;
-typedef std::pair<tr1::shared_ptr<const SetSpecTree::ConstItem>, KeywordsList> SetNameEntry;
+typedef std::map<std::tr1::shared_ptr<const PackageDepSpec>, KeywordsList> PDSToKeywordsList;
+typedef std::pair<std::tr1::shared_ptr<const SetSpecTree::ConstItem>, KeywordsList> SetNameEntry;
-typedef MakeHashedMap<QualifiedPackageName, PDSToKeywordsList>::Type SpecificMap;
+typedef std::tr1::unordered_map<QualifiedPackageName, PDSToKeywordsList, Hash<QualifiedPackageName> > SpecificMap;
typedef PDSToKeywordsList UnspecificMap;
-typedef MakeHashedMap<SetName, SetNameEntry>::Type NamedSetMap;
+typedef std::tr1::unordered_map<SetName, SetNameEntry, Hash<SetName> > NamedSetMap;
namespace paludis
{
@@ -84,7 +85,7 @@ KeywordsConf::add(const FSEntry & filename)
{
Context context("When adding source '" + stringify(filename) + "' as a keywords file:");
- tr1::shared_ptr<LineConfigFile> f(make_bashable_conf(filename));
+ std::tr1::shared_ptr<LineConfigFile> f(make_bashable_conf(filename));
if (! f)
return;
@@ -107,7 +108,7 @@ KeywordsConf::add(const FSEntry & filename)
if (std::string::npos == tokens.at(0).find("/"))
{
NamedSetMap::iterator i(_imp->set.insert(std::make_pair(SetName(tokens.at(0)), std::make_pair(
- tr1::shared_ptr<SetSpecTree::ConstItem>(), KeywordsList()))).first);
+ std::tr1::shared_ptr<SetSpecTree::ConstItem>(), KeywordsList()))).first);
for (std::vector<std::string>::const_iterator t(next(tokens.begin())), t_end(tokens.end()) ;
t != t_end ; ++t)
@@ -115,7 +116,7 @@ KeywordsConf::add(const FSEntry & filename)
}
else
{
- tr1::shared_ptr<PackageDepSpec> d(new PackageDepSpec(parse_user_package_dep_spec(
+ std::tr1::shared_ptr<PackageDepSpec> d(new PackageDepSpec(parse_user_package_dep_spec(
tokens.at(0), UserPackageDepSpecOptions() + updso_allow_wildcards)));
if (d->package_ptr())
{
@@ -136,7 +137,7 @@ KeywordsConf::add(const FSEntry & filename)
}
bool
-KeywordsConf::query(tr1::shared_ptr<const KeywordNameSet> k, const PackageID & e) const
+KeywordsConf::query(std::tr1::shared_ptr<const KeywordNameSet> k, const PackageID & e) const
{
static const KeywordName star_keyword("*");
static const KeywordName minus_star_keyword("-*");
@@ -190,7 +191,7 @@ KeywordsConf::query(tr1::shared_ptr<const KeywordNameSet> k, const PackageID & e
Log::get_instance()->message("paludis_environment.keywords_conf.unknown_set", ll_warning, lc_no_context) << "Set name '"
<< i->first << "' does not exist";
i->second.first.reset(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
- tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
+ std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
}
}
diff --git a/paludis/environments/paludis/keywords_conf.hh b/paludis/environments/paludis/keywords_conf.hh
index 58471c6..e5c6e4c 100644
--- a/paludis/environments/paludis/keywords_conf.hh
+++ b/paludis/environments/paludis/keywords_conf.hh
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007 Ciaran McCreesh
+ * Copyright (c) 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -59,7 +59,7 @@ namespace paludis
/**
* Query a collection of keywords.
*/
- bool query(tr1::shared_ptr<const KeywordNameSet>, const PackageID &) const;
+ bool query(std::tr1::shared_ptr<const KeywordNameSet>, const PackageID &) const;
};
}
}
diff --git a/paludis/environments/paludis/licenses_conf.cc b/paludis/environments/paludis/licenses_conf.cc
index 2bdbbff..1d45d0f 100644
--- a/paludis/environments/paludis/licenses_conf.cc
+++ b/paludis/environments/paludis/licenses_conf.cc
@@ -19,7 +19,6 @@
#include "licenses_conf.hh"
#include <paludis/environment.hh>
-#include <paludis/hashed_containers.hh>
#include <paludis/name.hh>
#include <paludis/dep_spec.hh>
#include <paludis/user_dep_spec.hh>
@@ -35,6 +34,8 @@
#include <paludis/util/mutex.hh>
#include <paludis/util/wrapped_forward_iterator.hh>
#include <paludis/util/iterator_funcs.hh>
+#include <paludis/util/hashes.hh>
+#include <tr1/unordered_map>
#include <list>
#include <vector>
#include <map>
@@ -43,12 +44,12 @@ using namespace paludis;
using namespace paludis::paludis_environment;
typedef std::list<std::string> LicensesList;
-typedef std::map<tr1::shared_ptr<const PackageDepSpec>, LicensesList> PDSToLicensesList;
-typedef std::pair<tr1::shared_ptr<const SetSpecTree::ConstItem>, LicensesList> SetNameEntry;
+typedef std::map<std::tr1::shared_ptr<const PackageDepSpec>, LicensesList> PDSToLicensesList;
+typedef std::pair<std::tr1::shared_ptr<const SetSpecTree::ConstItem>, LicensesList> SetNameEntry;
-typedef MakeHashedMap<QualifiedPackageName, PDSToLicensesList>::Type SpecificMap;
+typedef std::tr1::unordered_map<QualifiedPackageName, PDSToLicensesList, Hash<QualifiedPackageName> > SpecificMap;
typedef PDSToLicensesList UnspecificMap;
-typedef MakeHashedMap<SetName, SetNameEntry>::Type NamedSetMap;
+typedef std::tr1::unordered_map<SetName, SetNameEntry, Hash<SetName> > NamedSetMap;
namespace paludis
{
@@ -83,7 +84,7 @@ LicensesConf::add(const FSEntry & filename)
{
Context context("When adding source '" + stringify(filename) + "' as a licenses file:");
- tr1::shared_ptr<LineConfigFile> f(make_bashable_conf(filename));
+ std::tr1::shared_ptr<LineConfigFile> f(make_bashable_conf(filename));
if (! f)
return;
@@ -106,7 +107,7 @@ LicensesConf::add(const FSEntry & filename)
if (std::string::npos == tokens.at(0).find("/"))
{
NamedSetMap::iterator i(_imp->set.insert(std::make_pair(SetName(tokens.at(0)), std::make_pair(
- tr1::shared_ptr<SetSpecTree::ConstItem>(), LicensesList()))).first);
+ std::tr1::shared_ptr<SetSpecTree::ConstItem>(), LicensesList()))).first);
for (std::vector<std::string>::const_iterator t(next(tokens.begin())), t_end(tokens.end()) ;
t != t_end ; ++t)
@@ -114,7 +115,7 @@ LicensesConf::add(const FSEntry & filename)
}
else
{
- tr1::shared_ptr<PackageDepSpec> d(new PackageDepSpec(parse_user_package_dep_spec(
+ std::tr1::shared_ptr<PackageDepSpec> d(new PackageDepSpec(parse_user_package_dep_spec(
tokens.at(0), UserPackageDepSpecOptions() + updso_allow_wildcards)));
if (d->package_ptr())
{
@@ -182,7 +183,7 @@ LicensesConf::query(const std::string & t, const PackageID & e) const
Log::get_instance()->message("paludis_environment.licenses_conf.unknown_set", ll_warning, lc_no_context) << "Set name '"
<< i->first << "' does not exist";
i->second.first.reset(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
- tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
+ std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
}
}
diff --git a/paludis/environments/paludis/mirrors_conf.cc b/paludis/environments/paludis/mirrors_conf.cc
index b868cf5..4eadafb 100644
--- a/paludis/environments/paludis/mirrors_conf.cc
+++ b/paludis/environments/paludis/mirrors_conf.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007 Ciaran McCreesh
+ * Copyright (c) 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -19,25 +19,26 @@
#include "mirrors_conf.hh"
#include <paludis/environment.hh>
-#include <paludis/hashed_containers.hh>
#include <paludis/name.hh>
#include <paludis/environments/paludis/paludis_environment.hh>
#include <paludis/environments/paludis/bashable_conf.hh>
#include <paludis/util/log.hh>
#include <paludis/util/private_implementation_pattern-impl.hh>
#include <paludis/util/tokeniser.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/sequence.hh>
#include <paludis/util/iterator_funcs.hh>
#include <paludis/util/wrapped_forward_iterator.hh>
#include <paludis/util/wrapped_output_iterator.hh>
+#include <paludis/util/hashes.hh>
+#include <tr1/functional>
+#include <tr1/unordered_map>
#include <algorithm>
#include <vector>
using namespace paludis;
using namespace paludis::paludis_environment;
-typedef MakeHashedMultiMap<std::string, std::string>::Type Mirrors;
+typedef std::tr1::unordered_multimap<std::string, std::string, Hash<std::string> > Mirrors;
namespace paludis
{
@@ -68,7 +69,7 @@ MirrorsConf::add(const FSEntry & filename)
{
Context context("When adding source '" + stringify(filename) + "' as a mirrors file:");
- tr1::shared_ptr<LineConfigFile> f(make_bashable_conf(filename));
+ std::tr1::shared_ptr<LineConfigFile> f(make_bashable_conf(filename));
if (! f)
return;
@@ -87,13 +88,13 @@ MirrorsConf::add(const FSEntry & filename)
}
}
-tr1::shared_ptr<const MirrorsSequence>
+std::tr1::shared_ptr<const MirrorsSequence>
MirrorsConf::query(const std::string & m) const
{
- tr1::shared_ptr<MirrorsSequence> result(new MirrorsSequence);
+ std::tr1::shared_ptr<MirrorsSequence> result(new MirrorsSequence);
std::pair<Mirrors::const_iterator, Mirrors::const_iterator> p(_imp->mirrors.equal_range(m));
std::transform(p.first, p.second, result->back_inserter(),
- paludis::tr1::mem_fn(&std::pair<const std::string, std::string>::second));
+ std::tr1::mem_fn(&std::pair<const std::string, std::string>::second));
return result;
}
diff --git a/paludis/environments/paludis/mirrors_conf.hh b/paludis/environments/paludis/mirrors_conf.hh
index faacca3..8352ae2 100644
--- a/paludis/environments/paludis/mirrors_conf.hh
+++ b/paludis/environments/paludis/mirrors_conf.hh
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007 Ciaran McCreesh
+ * Copyright (c) 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -59,7 +59,7 @@ namespace paludis
/**
* Query a mirror.
*/
- tr1::shared_ptr<const MirrorsSequence> query(const std::string &) const
+ std::tr1::shared_ptr<const MirrorsSequence> query(const std::string &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
};
}
diff --git a/paludis/environments/paludis/package_mask_conf.cc b/paludis/environments/paludis/package_mask_conf.cc
index ea1505a..3eb679b 100644
--- a/paludis/environments/paludis/package_mask_conf.cc
+++ b/paludis/environments/paludis/package_mask_conf.cc
@@ -19,7 +19,6 @@
#include "package_mask_conf.hh"
#include <paludis/environment.hh>
-#include <paludis/hashed_containers.hh>
#include <paludis/name.hh>
#include <paludis/dep_spec.hh>
#include <paludis/user_dep_spec.hh>
@@ -35,14 +34,15 @@
#include <paludis/util/private_implementation_pattern-impl.hh>
#include <paludis/util/indirect_iterator-impl.hh>
#include <paludis/util/mutex.hh>
+#include <paludis/util/hashes.hh>
#include <list>
#include <algorithm>
-#include <paludis/util/tr1_functional.hh>
+#include <tr1/functional>
using namespace paludis;
using namespace paludis::paludis_environment;
-typedef std::list<std::pair<SetName, tr1::shared_ptr<const SetSpecTree::ConstItem> > > Sets;
+typedef std::list<std::pair<SetName, std::tr1::shared_ptr<const SetSpecTree::ConstItem> > > Sets;
namespace paludis
{
@@ -50,7 +50,7 @@ namespace paludis
struct Implementation<PackageMaskConf>
{
const PaludisEnvironment * const env;
- std::list<tr1::shared_ptr<const PackageDepSpec> > masks;
+ std::list<std::tr1::shared_ptr<const PackageDepSpec> > masks;
mutable Sets sets;
mutable Mutex set_mutex;
@@ -75,7 +75,7 @@ PackageMaskConf::add(const FSEntry & filename)
{
Context context("When adding source '" + stringify(filename) + "' as a package mask or unmask file:");
- tr1::shared_ptr<LineConfigFile> f(make_bashable_conf(filename));
+ std::tr1::shared_ptr<LineConfigFile> f(make_bashable_conf(filename));
if (! f)
return;
@@ -83,9 +83,9 @@ PackageMaskConf::add(const FSEntry & filename)
line != line_end ; ++line)
{
if (std::string::npos == line->find("/"))
- _imp->sets.push_back(std::make_pair(SetName(*line), tr1::shared_ptr<const SetSpecTree::ConstItem>()));
+ _imp->sets.push_back(std::make_pair(SetName(*line), std::tr1::shared_ptr<const SetSpecTree::ConstItem>()));
else
- _imp->masks.push_back(tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(parse_user_package_dep_spec(
+ _imp->masks.push_back(std::tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(parse_user_package_dep_spec(
*line, UserPackageDepSpecOptions() + updso_allow_wildcards))));
}
}
@@ -93,11 +93,11 @@ PackageMaskConf::add(const FSEntry & filename)
bool
PackageMaskConf::query(const PackageID & e) const
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
if (indirect_iterator(_imp->masks.end()) != std::find_if(
indirect_iterator(_imp->masks.begin()),
indirect_iterator(_imp->masks.end()),
- tr1::bind(&match_package, tr1::ref(*_imp->env), _1, tr1::cref(e))))
+ std::tr1::bind(&match_package, std::tr1::ref(*_imp->env), _1, std::tr1::cref(e))))
return true;
{
@@ -114,7 +114,7 @@ PackageMaskConf::query(const PackageID & e) const
Log::get_instance()->message("paludis_environment.package_mask.unknown_set", ll_warning, lc_no_context) << "Set name '"
<< it->first << "' does not exist";
it->second.reset(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
- tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
+ std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
}
}
diff --git a/paludis/environments/paludis/paludis_config.cc b/paludis/environments/paludis/paludis_config.cc
index 26bab0e..1435c78 100644
--- a/paludis/environments/paludis/paludis_config.cc
+++ b/paludis/environments/paludis/paludis_config.cc
@@ -46,7 +46,7 @@
#include <paludis/util/wrapped_forward_iterator-impl.hh>
#include <paludis/util/kc.hh>
-#include <paludis/util/tr1_functional.hh>
+#include <tr1/functional>
#include <fstream>
#include <algorithm>
#include <sstream>
@@ -91,21 +91,21 @@ namespace paludis
std::string config_dir;
mutable Mutex distribution_mutex;
mutable std::string distribution;
- tr1::shared_ptr<FSEntrySequence> bashrc_files;
+ std::tr1::shared_ptr<FSEntrySequence> bashrc_files;
std::list<RepositoryConfigEntry> repos;
- tr1::shared_ptr<KeywordsConf> keywords_conf;
- tr1::shared_ptr<UseConf> use_conf;
- tr1::shared_ptr<LicensesConf> licenses_conf;
- tr1::shared_ptr<PackageMaskConf> package_mask_conf;
- tr1::shared_ptr<PackageMaskConf> package_unmask_conf;
- tr1::shared_ptr<MirrorsConf> mirrors_conf;
- mutable tr1::shared_ptr<World> world;
+ std::tr1::shared_ptr<KeywordsConf> keywords_conf;
+ std::tr1::shared_ptr<UseConf> use_conf;
+ std::tr1::shared_ptr<LicensesConf> licenses_conf;
+ std::tr1::shared_ptr<PackageMaskConf> package_mask_conf;
+ std::tr1::shared_ptr<PackageMaskConf> package_unmask_conf;
+ std::tr1::shared_ptr<MirrorsConf> mirrors_conf;
+ mutable std::tr1::shared_ptr<World> world;
mutable Mutex reduced_mutex;
- mutable tr1::shared_ptr<uid_t> reduced_uid;
- mutable tr1::shared_ptr<gid_t> reduced_gid;
+ mutable std::tr1::shared_ptr<uid_t> reduced_uid;
+ mutable std::tr1::shared_ptr<gid_t> reduced_gid;
mutable Mutex environment_conf_mutex;
mutable bool has_environment_conf;
@@ -145,13 +145,13 @@ namespace paludis
Context context("When loading environment.conf:");
- tr1::shared_ptr<KeyValueConfigFile> kv;
- tr1::shared_ptr<Map<std::string, std::string> > conf_vars(
+ std::tr1::shared_ptr<KeyValueConfigFile> kv;
+ std::tr1::shared_ptr<Map<std::string, std::string> > conf_vars(
new Map<std::string, std::string>);
conf_vars->insert("ROOT", root);
conf_vars->insert("root", root);
conf_vars->insert("accept_breaks_portage", "*");
- tr1::shared_ptr<FSEntry> world_file;
+ std::tr1::shared_ptr<FSEntry> world_file;
if ((FSEntry(config_dir) / "environment.conf").exists())
kv.reset(new KeyValueConfigFile(FSEntry(config_dir) / "environment.conf", KeyValueConfigFileOptions(), KeyValueConfigFile::Defaults(conf_vars)));
@@ -232,7 +232,7 @@ PaludisConfigNoDirectoryError::PaludisConfigNoDirectoryError(const std::string &
PaludisConfig::PaludisConfig(PaludisEnvironment * const e, const std::string & suffix) :
PrivateImplementationPattern<PaludisConfig>(new Implementation<PaludisConfig>(e))
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
Context context("When loading paludis configuration:");
@@ -302,7 +302,7 @@ PaludisConfig::PaludisConfig(PaludisEnvironment * const e, const std::string & s
}
}
- tr1::shared_ptr<Map<std::string, std::string> > conf_vars(
+ std::tr1::shared_ptr<Map<std::string, std::string> > conf_vars(
new Map<std::string, std::string>);
conf_vars->insert("ROOT", root_prefix);
conf_vars->insert("root", root_prefix);
@@ -317,13 +317,13 @@ PaludisConfig::PaludisConfig(PaludisEnvironment * const e, const std::string & s
if ((*DistributionData::get_instance()->distribution_from_string(distribution()))[k::support_old_style_virtuals()])
{
- tr1::shared_ptr<Map<std::string, std::string> > iv_keys(
+ std::tr1::shared_ptr<Map<std::string, std::string> > iv_keys(
new Map<std::string, std::string>);
iv_keys->insert("root", root_prefix.empty() ? "/" : root_prefix);
_imp->repos.push_back(RepositoryConfigEntry("installed_virtuals", -1, iv_keys));
_imp->repos.push_back(RepositoryConfigEntry("virtuals", -2,
- tr1::shared_ptr<Map<std::string, std::string> >()));
+ std::tr1::shared_ptr<Map<std::string, std::string> >()));
}
/* add normal repositories */
@@ -362,18 +362,18 @@ PaludisConfig::PaludisConfig(PaludisEnvironment * const e, const std::string & s
continue;
std::remove_copy_if(DirIterator(*dir), DirIterator(), std::back_inserter(repo_files),
- tr1::bind(std::logical_not<bool>(), tr1::bind(&is_file_with_extension, _1, ".conf", IsFileWithOptions())));
+ std::tr1::bind(std::logical_not<bool>(), std::tr1::bind(&is_file_with_extension, _1, ".conf", IsFileWithOptions())));
std::remove_copy_if(DirIterator(*dir), DirIterator(), std::back_inserter(repo_files),
- tr1::bind(std::logical_not<bool>(), tr1::bind(&is_file_with_extension, _1, ".bash", IsFileWithOptions())));
+ std::tr1::bind(std::logical_not<bool>(), std::tr1::bind(&is_file_with_extension, _1, ".bash", IsFileWithOptions())));
}
- std::list<tr1::shared_ptr<Map<std::string, std::string> > > later_keys;
+ std::list<std::tr1::shared_ptr<Map<std::string, std::string> > > later_keys;
for (std::list<FSEntry>::const_iterator repo_file(repo_files.begin()), repo_file_end(repo_files.end()) ;
repo_file != repo_file_end ; ++repo_file)
{
Context local_context("When reading repository file '" + stringify(*repo_file) + "':");
- tr1::shared_ptr<KeyValueConfigFile> kv;
+ std::tr1::shared_ptr<KeyValueConfigFile> kv;
if (is_file_with_extension(*repo_file, ".bash", IsFileWithOptions()))
{
std::stringstream s;
@@ -406,7 +406,7 @@ PaludisConfig::PaludisConfig(PaludisEnvironment * const e, const std::string & s
if (! kv->get("importance").empty())
importance = destringify<int>(kv->get("importance"));
- tr1::shared_ptr<Map<std::string, std::string> > keys(new Map<std::string, std::string>);
+ std::tr1::shared_ptr<Map<std::string, std::string> > keys(new Map<std::string, std::string>);
std::copy(kv->begin(), kv->end(), keys->inserter());
keys->erase(stringify("importance"));
@@ -432,7 +432,7 @@ PaludisConfig::PaludisConfig(PaludisEnvironment * const e, const std::string & s
}
}
- for (std::list<tr1::shared_ptr<Map<std::string, std::string> > >::const_iterator
+ for (std::list<std::tr1::shared_ptr<Map<std::string, std::string> > >::const_iterator
k(later_keys.begin()), k_end(later_keys.end()) ; k != k_end ; ++k)
_imp->repos.push_back(RepositoryConfigEntry((*k)->find("format")->second,
destringify<int>((*k)->find("importance")->second), *k));
@@ -449,9 +449,9 @@ PaludisConfig::PaludisConfig(PaludisEnvironment * const e, const std::string & s
if ((local_config_dir / "keywords.conf.d").exists())
{
std::remove_copy_if(DirIterator(local_config_dir / "keywords.conf.d"), DirIterator(), std::back_inserter(files),
- tr1::bind(std::logical_not<bool>(), tr1::bind(&is_file_with_extension, _1, ".conf", IsFileWithOptions())));
+ std::tr1::bind(std::logical_not<bool>(), std::tr1::bind(&is_file_with_extension, _1, ".conf", IsFileWithOptions())));
std::remove_copy_if(DirIterator(local_config_dir / "keywords.conf.d"), DirIterator(), std::back_inserter(files),
- tr1::bind(std::logical_not<bool>(), tr1::bind(&is_file_with_extension, _1, ".bash", IsFileWithOptions())));
+ std::tr1::bind(std::logical_not<bool>(), std::tr1::bind(&is_file_with_extension, _1, ".bash", IsFileWithOptions())));
}
for (std::list<FSEntry>::const_iterator file(files.begin()), file_end(files.end()) ;
@@ -474,9 +474,9 @@ PaludisConfig::PaludisConfig(PaludisEnvironment * const e, const std::string & s
if ((local_config_dir / "use.conf.d").exists())
{
std::remove_copy_if(DirIterator(local_config_dir / "use.conf.d"), DirIterator(), std::back_inserter(files),
- tr1::bind(std::logical_not<bool>(), tr1::bind(&is_file_with_extension, _1, ".conf", IsFileWithOptions())));
+ std::tr1::bind(std::logical_not<bool>(), std::tr1::bind(&is_file_with_extension, _1, ".conf", IsFileWithOptions())));
std::remove_copy_if(DirIterator(local_config_dir / "use.conf.d"), DirIterator(), std::back_inserter(files),
- tr1::bind(std::logical_not<bool>(), tr1::bind(&is_file_with_extension, _1, ".bash", IsFileWithOptions())));
+ std::tr1::bind(std::logical_not<bool>(), std::tr1::bind(&is_file_with_extension, _1, ".bash", IsFileWithOptions())));
}
for (std::list<FSEntry>::const_iterator file(files.begin()), file_end(files.end()) ;
@@ -499,9 +499,9 @@ PaludisConfig::PaludisConfig(PaludisEnvironment * const e, const std::string & s
if ((local_config_dir / "licenses.conf.d").exists())
{
std::remove_copy_if(DirIterator(local_config_dir / "licenses.conf.d"), DirIterator(), std::back_inserter(files),
- tr1::bind(std::logical_not<bool>(), tr1::bind(&is_file_with_extension, _1, ".conf", IsFileWithOptions())));
+ std::tr1::bind(std::logical_not<bool>(), std::tr1::bind(&is_file_with_extension, _1, ".conf", IsFileWithOptions())));
std::remove_copy_if(DirIterator(local_config_dir / "licenses.conf.d"), DirIterator(), std::back_inserter(files),
- tr1::bind(std::logical_not<bool>(), tr1::bind(&is_file_with_extension, _1, ".bash", IsFileWithOptions())));
+ std::tr1::bind(std::logical_not<bool>(), std::tr1::bind(&is_file_with_extension, _1, ".bash", IsFileWithOptions())));
}
for (std::list<FSEntry>::const_iterator file(files.begin()), file_end(files.end()) ;
@@ -524,9 +524,9 @@ PaludisConfig::PaludisConfig(PaludisEnvironment * const e, const std::string & s
if ((local_config_dir / "package_mask.conf.d").exists())
{
std::remove_copy_if(DirIterator(local_config_dir / "package_mask.conf.d"), DirIterator(), std::back_inserter(files),
- tr1::bind(std::logical_not<bool>(), tr1::bind(&is_file_with_extension, _1, ".conf", IsFileWithOptions())));
+ std::tr1::bind(std::logical_not<bool>(), std::tr1::bind(&is_file_with_extension, _1, ".conf", IsFileWithOptions())));
std::remove_copy_if(DirIterator(local_config_dir / "package_mask.conf.d"), DirIterator(), std::back_inserter(files),
- tr1::bind(std::logical_not<bool>(), tr1::bind(&is_file_with_extension, _1, ".bash", IsFileWithOptions())));
+ std::tr1::bind(std::logical_not<bool>(), std::tr1::bind(&is_file_with_extension, _1, ".bash", IsFileWithOptions())));
}
for (std::list<FSEntry>::const_iterator file(files.begin()), file_end(files.end()) ;
@@ -549,9 +549,9 @@ PaludisConfig::PaludisConfig(PaludisEnvironment * const e, const std::string & s
if ((local_config_dir / "package_unmask.conf.d").exists())
{
std::remove_copy_if(DirIterator(local_config_dir / "package_unmask.conf.d"), DirIterator(), std::back_inserter(files),
- tr1::bind(std::logical_not<bool>(), tr1::bind(&is_file_with_extension, _1, ".conf", IsFileWithOptions())));
+ std::tr1::bind(std::logical_not<bool>(), std::tr1::bind(&is_file_with_extension, _1, ".conf", IsFileWithOptions())));
std::remove_copy_if(DirIterator(local_config_dir / "package_unmask.conf.d"), DirIterator(), std::back_inserter(files),
- tr1::bind(std::logical_not<bool>(), tr1::bind(&is_file_with_extension, _1, ".bash", IsFileWithOptions())));
+ std::tr1::bind(std::logical_not<bool>(), std::tr1::bind(&is_file_with_extension, _1, ".bash", IsFileWithOptions())));
}
for (std::list<FSEntry>::const_iterator file(files.begin()), file_end(files.end()) ;
@@ -574,9 +574,9 @@ PaludisConfig::PaludisConfig(PaludisEnvironment * const e, const std::string & s
if ((local_config_dir / "mirrors.conf.d").exists())
{
std::remove_copy_if(DirIterator(local_config_dir / "mirrors.conf.d"), DirIterator(), std::back_inserter(files),
- tr1::bind(std::logical_not<bool>(), tr1::bind(&is_file_with_extension, _1, ".conf", IsFileWithOptions())));
+ std::tr1::bind(std::logical_not<bool>(), std::tr1::bind(&is_file_with_extension, _1, ".conf", IsFileWithOptions())));
std::remove_copy_if(DirIterator(local_config_dir / "mirrors.conf.d"), DirIterator(), std::back_inserter(files),
- tr1::bind(std::logical_not<bool>(), tr1::bind(&is_file_with_extension, _1, ".bash", IsFileWithOptions())));
+ std::tr1::bind(std::logical_not<bool>(), std::tr1::bind(&is_file_with_extension, _1, ".bash", IsFileWithOptions())));
}
for (std::list<FSEntry>::const_iterator file(files.begin()), file_end(files.end()) ;
@@ -598,7 +598,7 @@ PaludisConfig::~PaludisConfig()
{
}
-tr1::shared_ptr<const FSEntrySequence>
+std::tr1::shared_ptr<const FSEntrySequence>
PaludisConfig::bashrc_files() const
{
return _imp->bashrc_files;
@@ -713,43 +713,43 @@ PaludisConfig::accept_breaks_portage() const
return _imp->accept_breaks_portage;
}
-tr1::shared_ptr<const KeywordsConf>
+std::tr1::shared_ptr<const KeywordsConf>
PaludisConfig::keywords_conf() const
{
return _imp->keywords_conf;
}
-tr1::shared_ptr<const UseConf>
+std::tr1::shared_ptr<const UseConf>
PaludisConfig::use_conf() const
{
return _imp->use_conf;
}
-tr1::shared_ptr<const LicensesConf>
+std::tr1::shared_ptr<const LicensesConf>
PaludisConfig::licenses_conf() const
{
return _imp->licenses_conf;
}
-tr1::shared_ptr<const PackageMaskConf>
+std::tr1::shared_ptr<const PackageMaskConf>
PaludisConfig::package_mask_conf() const
{
return _imp->package_mask_conf;
}
-tr1::shared_ptr<const PackageMaskConf>
+std::tr1::shared_ptr<const PackageMaskConf>
PaludisConfig::package_unmask_conf() const
{
return _imp->package_unmask_conf;
}
-tr1::shared_ptr<const MirrorsConf>
+std::tr1::shared_ptr<const MirrorsConf>
PaludisConfig::mirrors_conf() const
{
return _imp->mirrors_conf;
}
-tr1::shared_ptr<const World>
+std::tr1::shared_ptr<const World>
PaludisConfig::world() const
{
_imp->need_environment_conf();
diff --git a/paludis/environments/paludis/paludis_config.hh b/paludis/environments/paludis/paludis_config.hh
index a5260ac..e3c7ee9 100644
--- a/paludis/environments/paludis/paludis_config.hh
+++ b/paludis/environments/paludis/paludis_config.hh
@@ -114,13 +114,13 @@ namespace paludis
///\name Config files
///\{
- tr1::shared_ptr<const KeywordsConf> keywords_conf() const;
- tr1::shared_ptr<const UseConf> use_conf() const;
- tr1::shared_ptr<const LicensesConf> licenses_conf() const;
- tr1::shared_ptr<const PackageMaskConf> package_mask_conf() const;
- tr1::shared_ptr<const PackageMaskConf> package_unmask_conf() const;
- tr1::shared_ptr<const MirrorsConf> mirrors_conf() const;
- tr1::shared_ptr<const World> world() const;
+ std::tr1::shared_ptr<const KeywordsConf> keywords_conf() const;
+ std::tr1::shared_ptr<const UseConf> use_conf() const;
+ std::tr1::shared_ptr<const LicensesConf> licenses_conf() const;
+ std::tr1::shared_ptr<const PackageMaskConf> package_mask_conf() const;
+ std::tr1::shared_ptr<const PackageMaskConf> package_unmask_conf() const;
+ std::tr1::shared_ptr<const MirrorsConf> mirrors_conf() const;
+ std::tr1::shared_ptr<const World> world() const;
///\}
@@ -139,7 +139,7 @@ namespace paludis
/**
* Our bashrc files.
*/
- tr1::shared_ptr<const FSEntrySequence> bashrc_files() const;
+ std::tr1::shared_ptr<const FSEntrySequence> bashrc_files() const;
/**
* The ROOT.
diff --git a/paludis/environments/paludis/paludis_environment.cc b/paludis/environments/paludis/paludis_environment.cc
index 3f0f6ea..db4e41e 100644
--- a/paludis/environments/paludis/paludis_environment.cc
+++ b/paludis/environments/paludis/paludis_environment.cc
@@ -47,7 +47,6 @@
#include <paludis/util/make_shared_ptr.hh>
#include <paludis/util/save.hh>
#include <paludis/util/strip.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/set.hh>
#include <paludis/util/sequence.hh>
#include <paludis/util/mutex.hh>
@@ -56,6 +55,7 @@
#include <paludis/util/visitor-impl.hh>
#include <paludis/util/options.hh>
+#include <tr1/functional>
#include <functional>
#include <algorithm>
#include <list>
@@ -71,19 +71,19 @@ namespace paludis
{
mutable Mutex hook_mutex;
mutable bool done_hooks;
- mutable tr1::shared_ptr<Hooker> hooker;
+ mutable std::tr1::shared_ptr<Hooker> hooker;
mutable std::list<std::pair<FSEntry, bool> > hook_dirs;
- tr1::shared_ptr<PaludisConfig> config;
+ std::tr1::shared_ptr<PaludisConfig> config;
std::string paludis_command;
std::list<UseConfigEntry> forced_use;
- tr1::shared_ptr<PackageDatabase> package_database;
+ std::tr1::shared_ptr<PackageDatabase> package_database;
mutable Mutex sets_mutex;
- mutable std::map<SetName, tr1::shared_ptr<SetSpecTree::ConstItem> > sets;
+ mutable std::map<SetName, std::tr1::shared_ptr<SetSpecTree::ConstItem> > sets;
- Implementation(PaludisEnvironment * const e, tr1::shared_ptr<PaludisConfig> c) :
+ Implementation(PaludisEnvironment * const e, std::tr1::shared_ptr<PaludisConfig> c) :
done_hooks(false),
config(c),
paludis_command("paludis"),
@@ -132,7 +132,7 @@ namespace paludis
PaludisEnvironment::PaludisEnvironment(const std::string & s) :
PrivateImplementationPattern<PaludisEnvironment>(new Implementation<PaludisEnvironment>(
- this, tr1::shared_ptr<PaludisConfig>(new PaludisConfig(this, s))))
+ this, std::tr1::shared_ptr<PaludisConfig>(new PaludisConfig(this, s))))
{
Context context("When loading paludis environment:");
@@ -234,7 +234,7 @@ PaludisEnvironment::query_use(const UseFlagName & f, const PackageID & e) const
}
bool
-PaludisEnvironment::accept_keywords(tr1::shared_ptr<const KeywordNameSet> k,
+PaludisEnvironment::accept_keywords(std::tr1::shared_ptr<const KeywordNameSet> k,
const PackageID & e) const
{
return _imp->config->keywords_conf()->query(k, e);
@@ -259,7 +259,7 @@ PaludisEnvironment::unmasked_by_user(const PackageID & d) const
return _imp->config->package_unmask_conf()->query(d);
}
-tr1::shared_ptr<const FSEntrySequence>
+std::tr1::shared_ptr<const FSEntrySequence>
PaludisEnvironment::bashrc_files() const
{
return _imp->config->bashrc_files();
@@ -294,76 +294,76 @@ PaludisEnvironment::perform_hook(const Hook & hook) const
return _imp->hooker->perform_hook(hook);
}
-tr1::shared_ptr<const FSEntrySequence>
+std::tr1::shared_ptr<const FSEntrySequence>
PaludisEnvironment::hook_dirs() const
{
Lock lock(_imp->hook_mutex);
_imp->need_hook_dirs(_imp->config->config_dir());
- tr1::shared_ptr<FSEntrySequence> result(new FSEntrySequence);
+ std::tr1::shared_ptr<FSEntrySequence> result(new FSEntrySequence);
std::transform(_imp->hook_dirs.begin(), _imp->hook_dirs.end(), result->back_inserter(),
- tr1::mem_fn(&std::pair<FSEntry, bool>::first));
+ std::tr1::mem_fn(&std::pair<FSEntry, bool>::first));
return result;
}
-tr1::shared_ptr<const FSEntrySequence>
+std::tr1::shared_ptr<const FSEntrySequence>
PaludisEnvironment::fetchers_dirs() const
{
- tr1::shared_ptr<FSEntrySequence> result(new FSEntrySequence);
+ std::tr1::shared_ptr<FSEntrySequence> result(new FSEntrySequence);
result->push_back(FSEntry(_imp->config->config_dir()) / "fetchers");
if (getenv_with_default("PALUDIS_NO_GLOBAL_FETCHERS", "").empty())
{
- tr1::shared_ptr<const FSEntrySequence> r(EnvironmentImplementation::fetchers_dirs());
+ std::tr1::shared_ptr<const FSEntrySequence> r(EnvironmentImplementation::fetchers_dirs());
std::copy(r->begin(), r->end(), result->back_inserter());
}
return result;
}
-tr1::shared_ptr<const FSEntrySequence>
+std::tr1::shared_ptr<const FSEntrySequence>
PaludisEnvironment::syncers_dirs() const
{
- tr1::shared_ptr<FSEntrySequence> result(new FSEntrySequence);
+ std::tr1::shared_ptr<FSEntrySequence> result(new FSEntrySequence);
result->push_back(FSEntry(_imp->config->config_dir()) / "syncers");
if (getenv_with_default("PALUDIS_NO_GLOBAL_SYNCERS", "").empty())
{
- tr1::shared_ptr<const FSEntrySequence> r(EnvironmentImplementation::syncers_dirs());
+ std::tr1::shared_ptr<const FSEntrySequence> r(EnvironmentImplementation::syncers_dirs());
std::copy(r->begin(), r->end(), result->back_inserter());
}
return result;
}
-tr1::shared_ptr<SetSpecTree::ConstItem>
+std::tr1::shared_ptr<SetSpecTree::ConstItem>
PaludisEnvironment::local_set(const SetName & ss) const
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
Context context("When looking for package set '" + stringify(ss) + "' in paludis environment:");
Lock l(_imp->sets_mutex);
- std::map<SetName, tr1::shared_ptr<SetSpecTree::ConstItem> >::const_iterator i(_imp->sets.find(ss));
+ std::map<SetName, std::tr1::shared_ptr<SetSpecTree::ConstItem> >::const_iterator i(_imp->sets.find(ss));
if (i != _imp->sets.end())
return i->second;
std::pair<SetName, SetFileSetOperatorMode> s(find_base_set_name_and_suffix_mode(ss));
FSEntry dir(FSEntry(_imp->config->config_dir()) / "sets");
- tr1::shared_ptr<GeneralSetDepTag> tag(new GeneralSetDepTag(ss, stringify(s.first) + ".conf"));
+ std::tr1::shared_ptr<GeneralSetDepTag> tag(new GeneralSetDepTag(ss, stringify(s.first) + ".conf"));
if ((dir / (stringify(s.first) + ".bash")).exists())
{
SetFile f(SetFileParams::create()
.file_name(dir / (stringify(s.first) + ".bash"))
.type(sft_paludis_bash)
- .parser(tr1::bind(&parse_user_package_dep_spec, _1, UserPackageDepSpecOptions() + updso_allow_wildcards))
+ .parser(std::tr1::bind(&parse_user_package_dep_spec, _1, UserPackageDepSpecOptions() + updso_allow_wildcards))
.tag(tag)
.set_operator_mode(s.second)
.environment(this));
@@ -376,7 +376,7 @@ PaludisEnvironment::local_set(const SetName & ss) const
SetFile f(SetFileParams::create()
.file_name(dir / (stringify(s.first) + ".conf"))
.type(sft_paludis_conf)
- .parser(tr1::bind(&parse_user_package_dep_spec, _1, UserPackageDepSpecOptions() + updso_allow_wildcards))
+ .parser(std::tr1::bind(&parse_user_package_dep_spec, _1, UserPackageDepSpecOptions() + updso_allow_wildcards))
.tag(tag)
.set_operator_mode(s.second)
.environment(this));
@@ -386,12 +386,12 @@ PaludisEnvironment::local_set(const SetName & ss) const
}
else
{
- _imp->sets.insert(std::make_pair(ss, tr1::shared_ptr<SetSpecTree::ConstItem>()));
- return tr1::shared_ptr<SetSpecTree::ConstItem>();
+ _imp->sets.insert(std::make_pair(ss, std::tr1::shared_ptr<SetSpecTree::ConstItem>()));
+ return std::tr1::shared_ptr<SetSpecTree::ConstItem>();
}
}
-tr1::shared_ptr<SetSpecTree::ConstItem>
+std::tr1::shared_ptr<SetSpecTree::ConstItem>
PaludisEnvironment::world_set() const
{
return _imp->config->world()->world_set();
@@ -421,10 +421,10 @@ PaludisEnvironment::remove_from_world(const SetName & s) const
_imp->config->world()->remove_from_world(s);
}
-tr1::shared_ptr<const SetNameSet>
+std::tr1::shared_ptr<const SetNameSet>
PaludisEnvironment::set_names() const
{
- tr1::shared_ptr<SetNameSet> result(new SetNameSet);
+ std::tr1::shared_ptr<SetNameSet> result(new SetNameSet);
if ((FSEntry(_imp->config->config_dir()) / "sets").exists())
for (DirIterator d(FSEntry(_imp->config->config_dir()) / "sets"), d_end ;
@@ -439,13 +439,13 @@ PaludisEnvironment::set_names() const
return result;
}
-tr1::shared_ptr<const MirrorsSequence>
+std::tr1::shared_ptr<const MirrorsSequence>
PaludisEnvironment::mirrors(const std::string & m) const
{
return _imp->config->mirrors_conf()->query(m);
}
-tr1::shared_ptr<const UseFlagNameSet>
+std::tr1::shared_ptr<const UseFlagNameSet>
PaludisEnvironment::known_use_expand_names(const UseFlagName & prefix, const PackageID & e) const
{
return _imp->config->use_conf()->known_use_expand_names(prefix, e);
@@ -483,13 +483,13 @@ PaludisEnvironment::config_dir() const
return _imp->config->config_dir();
}
-tr1::shared_ptr<PackageDatabase>
+std::tr1::shared_ptr<PackageDatabase>
PaludisEnvironment::package_database()
{
return _imp->package_database;
}
-tr1::shared_ptr<const PackageDatabase>
+std::tr1::shared_ptr<const PackageDatabase>
PaludisEnvironment::package_database() const
{
return _imp->package_database;
@@ -546,12 +546,12 @@ namespace
};
}
-const tr1::shared_ptr<const Mask>
+const std::tr1::shared_ptr<const Mask>
PaludisEnvironment::mask_for_breakage(const PackageID & id) const
{
if (! _imp->config->accept_all_breaks_portage())
{
- tr1::shared_ptr<const Set<std::string> > breakages(id.breaks_portage());
+ std::tr1::shared_ptr<const Set<std::string> > breakages(id.breaks_portage());
if (breakages)
{
std::list<std::string> bad_breakages;
@@ -563,15 +563,15 @@ PaludisEnvironment::mask_for_breakage(const PackageID & id) const
}
}
- return tr1::shared_ptr<const Mask>();
+ return std::tr1::shared_ptr<const Mask>();
}
-const tr1::shared_ptr<const Mask>
+const std::tr1::shared_ptr<const Mask>
PaludisEnvironment::mask_for_user(const PackageID & d) const
{
if (_imp->config->package_mask_conf()->query(d))
return make_shared_ptr(new UserConfigMask);
- return tr1::shared_ptr<const Mask>();
+ return std::tr1::shared_ptr<const Mask>();
}
diff --git a/paludis/environments/paludis/paludis_environment.hh b/paludis/environments/paludis/paludis_environment.hh
index af76769..7b0af4a 100644
--- a/paludis/environments/paludis/paludis_environment.hh
+++ b/paludis/environments/paludis/paludis_environment.hh
@@ -50,9 +50,9 @@ namespace paludis
private PrivateImplementationPattern<PaludisEnvironment>
{
protected:
- virtual tr1::shared_ptr<SetSpecTree::ConstItem> local_set(const SetName & id) const;
+ virtual std::tr1::shared_ptr<SetSpecTree::ConstItem> local_set(const SetName & id) const;
- virtual tr1::shared_ptr<SetSpecTree::ConstItem> world_set() const;
+ virtual std::tr1::shared_ptr<SetSpecTree::ConstItem> world_set() const;
public:
///\name Basic operations
@@ -77,20 +77,20 @@ namespace paludis
virtual bool query_use(const UseFlagName &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const UseFlagNameSet> known_use_expand_names(
+ virtual std::tr1::shared_ptr<const UseFlagNameSet> known_use_expand_names(
const UseFlagName &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const FSEntrySequence> bashrc_files() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> bashrc_files() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const FSEntrySequence> syncers_dirs() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> syncers_dirs() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const FSEntrySequence> fetchers_dirs() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> fetchers_dirs() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const FSEntrySequence> hook_dirs() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> hook_dirs() const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual const FSEntry root() const
@@ -102,10 +102,10 @@ namespace paludis
virtual gid_t reduced_gid() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const MirrorsSequence> mirrors(const std::string &) const
+ virtual std::tr1::shared_ptr<const MirrorsSequence> mirrors(const std::string &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const SetNameSet> set_names() const
+ virtual std::tr1::shared_ptr<const SetNameSet> set_names() const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual HookResult perform_hook(const Hook &) const
@@ -116,25 +116,25 @@ namespace paludis
virtual void set_paludis_command(const std::string &);
- virtual tr1::shared_ptr<PackageDatabase> package_database()
+ virtual std::tr1::shared_ptr<PackageDatabase> package_database()
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const PackageDatabase> package_database() const
+ virtual std::tr1::shared_ptr<const PackageDatabase> package_database() const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual std::string default_distribution() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual bool accept_keywords(tr1::shared_ptr<const KeywordNameSet>, const PackageID &) const
+ virtual bool accept_keywords(std::tr1::shared_ptr<const KeywordNameSet>, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual bool accept_license(const std::string &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual const tr1::shared_ptr<const Mask> mask_for_breakage(const PackageID &) const
+ virtual const std::tr1::shared_ptr<const Mask> mask_for_breakage(const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual const tr1::shared_ptr<const Mask> mask_for_user(const PackageID &) const
+ virtual const std::tr1::shared_ptr<const Mask> mask_for_user(const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual bool unmasked_by_user(const PackageID &) const
diff --git a/paludis/environments/paludis/paludis_environment_TEST.cc b/paludis/environments/paludis/paludis_environment_TEST.cc
index ef0f26f..7c785ee 100644
--- a/paludis/environments/paludis/paludis_environment_TEST.cc
+++ b/paludis/environments/paludis/paludis_environment_TEST.cc
@@ -45,10 +45,10 @@ namespace test_cases
setenv("PALUDIS_HOME", stringify(FSEntry::cwd() / "paludis_environment_TEST_dir" / "home1").c_str(), 1);
unsetenv("PALUDIS_SKIP_CONFIG");
- tr1::shared_ptr<Environment> env(new PaludisEnvironment(""));
- const tr1::shared_ptr<const PackageID> one(*env->package_database()->query(
+ std::tr1::shared_ptr<Environment> env(new PaludisEnvironment(""));
+ const std::tr1::shared_ptr<const PackageID> one(*env->package_database()->query(
query::Matches(PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-one-1", UserPackageDepSpecOptions()))), qo_require_exactly_one)->begin());
- const tr1::shared_ptr<const PackageID> three(*env->package_database()->query(
+ const std::tr1::shared_ptr<const PackageID> three(*env->package_database()->query(
query::Matches(PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-two-3", UserPackageDepSpecOptions()))), qo_require_exactly_one)->begin());
TEST_CHECK(env->query_use(UseFlagName("foo"), *one));
@@ -76,11 +76,11 @@ namespace test_cases
setenv("PALUDIS_HOME", stringify(FSEntry::cwd() / "paludis_environment_TEST_dir" / "home5").c_str(), 1);
unsetenv("PALUDIS_SKIP_CONFIG");
- tr1::shared_ptr<Environment> env(new PaludisEnvironment(""));
+ std::tr1::shared_ptr<Environment> env(new PaludisEnvironment(""));
- const tr1::shared_ptr<const PackageID> one(*env->package_database()->query(
+ const std::tr1::shared_ptr<const PackageID> one(*env->package_database()->query(
query::Matches(PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-one-1", UserPackageDepSpecOptions()))), qo_require_exactly_one)->begin());
- tr1::shared_ptr<const UseFlagNameSet> k1(env->known_use_expand_names(UseFlagName("foo_cards"), *one));
+ std::tr1::shared_ptr<const UseFlagNameSet> k1(env->known_use_expand_names(UseFlagName("foo_cards"), *one));
TEST_CHECK_EQUAL(join(k1->begin(), k1->end(), " "), "foo_cards_one foo_cards_three foo_cards_two");
}
} paludis_environment_use_test_known;
@@ -94,11 +94,11 @@ namespace test_cases
setenv("PALUDIS_HOME", stringify(FSEntry::cwd() / "paludis_environment_TEST_dir" / "home2").c_str(), 1);
unsetenv("PALUDIS_SKIP_CONFIG");
- tr1::shared_ptr<Environment> env(new PaludisEnvironment(""));
+ std::tr1::shared_ptr<Environment> env(new PaludisEnvironment(""));
- const tr1::shared_ptr<const PackageID> one(*env->package_database()->query(
+ const std::tr1::shared_ptr<const PackageID> one(*env->package_database()->query(
query::Matches(PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-one-1", UserPackageDepSpecOptions()))), qo_require_exactly_one)->begin());
- const tr1::shared_ptr<const PackageID> three(*env->package_database()->query(
+ const std::tr1::shared_ptr<const PackageID> three(*env->package_database()->query(
query::Matches(PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-two-3", UserPackageDepSpecOptions()))), qo_require_exactly_one)->begin());
TEST_CHECK(env->query_use(UseFlagName("foo"), *one));
@@ -125,11 +125,11 @@ namespace test_cases
setenv("PALUDIS_HOME", stringify(FSEntry::cwd() / "paludis_environment_TEST_dir" / "home3").c_str(), 1);
unsetenv("PALUDIS_SKIP_CONFIG");
- tr1::shared_ptr<Environment> env(new PaludisEnvironment(""));
+ std::tr1::shared_ptr<Environment> env(new PaludisEnvironment(""));
- const tr1::shared_ptr<const PackageID> one(*env->package_database()->query(
+ const std::tr1::shared_ptr<const PackageID> one(*env->package_database()->query(
query::Matches(PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-one-1", UserPackageDepSpecOptions()))), qo_require_exactly_one)->begin());
- const tr1::shared_ptr<const PackageID> three(*env->package_database()->query(
+ const std::tr1::shared_ptr<const PackageID> three(*env->package_database()->query(
query::Matches(PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-two-3", UserPackageDepSpecOptions()))), qo_require_exactly_one)->begin());
TEST_CHECK(env->query_use(UseFlagName("foo"), *one));
@@ -156,7 +156,7 @@ namespace test_cases
setenv("PALUDIS_HOME", stringify(FSEntry::cwd() / "paludis_environment_TEST_dir" / "home4").c_str(), 1);
unsetenv("PALUDIS_SKIP_CONFIG");
- tr1::shared_ptr<Environment> env(new PaludisEnvironment(""));
+ std::tr1::shared_ptr<Environment> env(new PaludisEnvironment(""));
TEST_CHECK(env->package_database()->fetch_repository(RepositoryName("first")));
TEST_CHECK(env->package_database()->fetch_repository(RepositoryName("second")));
diff --git a/paludis/environments/paludis/registration.cc b/paludis/environments/paludis/registration.cc
index a230f9f..8b8dd3e 100644
--- a/paludis/environments/paludis/registration.cc
+++ b/paludis/environments/paludis/registration.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007 Ciaran McCreesh
+ * Copyright (c) 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -24,10 +24,10 @@ using namespace paludis;
namespace
{
- tr1::shared_ptr<Environment>
+ std::tr1::shared_ptr<Environment>
make_paludis_environment(const std::string & s)
{
- return tr1::shared_ptr<Environment>(new PaludisEnvironment(s));
+ return std::tr1::shared_ptr<Environment>(new PaludisEnvironment(s));
}
}
diff --git a/paludis/environments/paludis/repository_config_entry.sr b/paludis/environments/paludis/repository_config_entry.sr
index 52422fa..07eec25 100644
--- a/paludis/environments/paludis/repository_config_entry.sr
+++ b/paludis/environments/paludis/repository_config_entry.sr
@@ -5,7 +5,7 @@ make_class_RepositoryConfigEntry()
{
key format std::string
key importance int
- key keys "tr1::shared_ptr<Map<std::string, std::string> >"
+ key keys "std::tr1::shared_ptr<Map<std::string, std::string> >"
doxygen_comment << "END"
/**
diff --git a/paludis/environments/paludis/use_conf.cc b/paludis/environments/paludis/use_conf.cc
index 0948a67..22ecbe4 100644
--- a/paludis/environments/paludis/use_conf.cc
+++ b/paludis/environments/paludis/use_conf.cc
@@ -19,7 +19,6 @@
#include "use_conf.hh"
#include <paludis/environment.hh>
-#include <paludis/hashed_containers.hh>
#include <paludis/name.hh>
#include <paludis/dep_spec.hh>
#include <paludis/match_package.hh>
@@ -37,6 +36,8 @@
#include <paludis/util/wrapped_forward_iterator.hh>
#include <paludis/util/set.hh>
#include <paludis/util/mutex.hh>
+#include <paludis/util/hashes.hh>
+#include <tr1/unordered_map>
#include <algorithm>
#include <list>
#include <vector>
@@ -44,15 +45,15 @@
using namespace paludis;
using namespace paludis::paludis_environment;
-typedef MakeHashedMap<UseFlagName, UseFlagState>::Type UseFlagWithStateMap;
+typedef std::tr1::unordered_map<UseFlagName, UseFlagState, Hash<UseFlagName> > UseFlagWithStateMap;
typedef std::list<std::string> MinusStarPrefixList;
typedef std::pair<UseFlagWithStateMap, MinusStarPrefixList> UseInfo;
-typedef std::pair<tr1::shared_ptr<const PackageDepSpec>, UseInfo> PDSWithUseInfo;
-typedef std::pair<tr1::shared_ptr<const SetSpecTree::ConstItem>, UseInfo> DSWithUseInfo;
+typedef std::pair<std::tr1::shared_ptr<const PackageDepSpec>, UseInfo> PDSWithUseInfo;
+typedef std::pair<std::tr1::shared_ptr<const SetSpecTree::ConstItem>, UseInfo> DSWithUseInfo;
typedef std::list<PDSWithUseInfo> PDSWithUseInfoList;
-typedef MakeHashedMap<QualifiedPackageName, PDSWithUseInfoList>::Type Qualified;
+typedef std::tr1::unordered_map<QualifiedPackageName, PDSWithUseInfoList, Hash<QualifiedPackageName> > Qualified;
typedef std::list<PDSWithUseInfo> Unqualified;
-typedef MakeHashedMap<SetName, DSWithUseInfo>::Type Sets;
+typedef std::tr1::unordered_map<SetName, DSWithUseInfo, Hash<SetName> > Sets;
namespace paludis
{
@@ -86,7 +87,7 @@ UseConf::add(const FSEntry & filename)
{
Context context("When adding source '" + stringify(filename) + "' as a use file:");
- tr1::shared_ptr<LineConfigFile> f(make_bashable_conf(filename));
+ std::tr1::shared_ptr<LineConfigFile> f(make_bashable_conf(filename));
if (! f)
return;
@@ -132,7 +133,7 @@ UseConf::add(const FSEntry & filename)
}
else
{
- tr1::shared_ptr<PackageDepSpec> d(new PackageDepSpec(parse_user_package_dep_spec(
+ std::tr1::shared_ptr<PackageDepSpec> d(new PackageDepSpec(parse_user_package_dep_spec(
tokens.at(0), UserPackageDepSpecOptions() + updso_allow_wildcards)));
if (d->additional_requirements_ptr())
@@ -206,7 +207,7 @@ UseConf::query(const UseFlagName & f, const PackageID & e) const
bool ignore_empty_minus_star(false);
if ((*e.repository())[k::use_interface()])
{
- tr1::shared_ptr<const UseFlagNameSet> prefixes((*e.repository())[k::use_interface()]->use_expand_prefixes());
+ std::tr1::shared_ptr<const UseFlagNameSet> prefixes((*e.repository())[k::use_interface()]->use_expand_prefixes());
for (UseFlagNameSet::ConstIterator p(prefixes->begin()), p_end(prefixes->end()) ;
p != p_end ; ++p)
if (0 == p->data().compare(0, p->data().length(), stringify(f), 0, p->data().length()))
@@ -260,7 +261,7 @@ UseConf::query(const UseFlagName & f, const PackageID & e) const
Log::get_instance()->message("paludis_environment.use_conf.unknown_set", ll_warning, lc_no_context) << "Set name '"
<< r->first << "' does not exist";
r->second.first.reset(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
- tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
+ std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
}
}
@@ -318,12 +319,12 @@ UseConf::query(const UseFlagName & f, const PackageID & e) const
return result;
}
-tr1::shared_ptr<const UseFlagNameSet>
+std::tr1::shared_ptr<const UseFlagNameSet>
UseConf::known_use_expand_names(const UseFlagName & prefix, const PackageID & e) const
{
Context context("When loading known use expand names for prefix '" + stringify(prefix) + ":");
- tr1::shared_ptr<UseFlagNameSet> result(new UseFlagNameSet);
+ std::tr1::shared_ptr<UseFlagNameSet> result(new UseFlagNameSet);
std::string prefix_lower;
std::transform(prefix.data().begin(), prefix.data().end(), std::back_inserter(prefix_lower), &::tolower);
prefix_lower.append("_");
@@ -353,7 +354,7 @@ UseConf::known_use_expand_names(const UseFlagName & prefix, const PackageID & e)
Log::get_instance()->message("paludis_environment.use_conf.unknown_set", ll_warning, lc_no_context) << "Set name '"
<< r->first << "' does not exist";
r->second.first.reset(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
- tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
+ std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
}
}
diff --git a/paludis/environments/paludis/use_conf.hh b/paludis/environments/paludis/use_conf.hh
index f5fe56e..cd5cc75 100644
--- a/paludis/environments/paludis/use_conf.hh
+++ b/paludis/environments/paludis/use_conf.hh
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007 Ciaran McCreesh
+ * Copyright (c) 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -65,7 +65,7 @@ namespace paludis
/**
* Fetch the known use expand names for a prefix.
*/
- tr1::shared_ptr<const UseFlagNameSet> known_use_expand_names(
+ std::tr1::shared_ptr<const UseFlagNameSet> known_use_expand_names(
const UseFlagName &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
};
diff --git a/paludis/environments/paludis/use_config_entry.sr b/paludis/environments/paludis/use_config_entry.sr
index d623abf..046c045 100644
--- a/paludis/environments/paludis/use_config_entry.sr
+++ b/paludis/environments/paludis/use_config_entry.sr
@@ -3,7 +3,7 @@
make_class_UseConfigEntry()
{
- key dep_spec "tr1::shared_ptr<const PackageDepSpec>"
+ key dep_spec "std::tr1::shared_ptr<const PackageDepSpec>"
key flag_name UseFlagName
key flag_state UseFlagState
@@ -20,8 +20,8 @@ END
make_class_SetUseConfigEntry()
{
- key set_name "tr1::shared_ptr<const SetName>"
- key dep_spec "tr1::shared_ptr<const DepSpec>"
+ key set_name "std::tr1::shared_ptr<const SetName>"
+ key dep_spec "std::tr1::shared_ptr<const DepSpec>"
key flag_name UseFlagName
key flag_state UseFlagState
@@ -38,8 +38,8 @@ END
make_class_SetUseConfigMinusStarEntry()
{
- key set_name "tr1::shared_ptr<const SetName>"
- key dep_spec "tr1::shared_ptr<const DepSpec>"
+ key set_name "std::tr1::shared_ptr<const SetName>"
+ key dep_spec "std::tr1::shared_ptr<const DepSpec>"
key prefix std::string
doxygen_comment << "END"
@@ -55,8 +55,8 @@ END
make_class_SetKeywordConfigEntry()
{
- key set_name "tr1::shared_ptr<const SetName>"
- key dep_spec "tr1::shared_ptr<const DepSpec>"
+ key set_name "std::tr1::shared_ptr<const SetName>"
+ key dep_spec "std::tr1::shared_ptr<const DepSpec>"
key keyword KeywordName
doxygen_comment << "END"
@@ -72,8 +72,8 @@ END
make_class_SetLicenseConfigEntry()
{
- key set_name "tr1::shared_ptr<const SetName>"
- key dep_spec "tr1::shared_ptr<const DepSpec>"
+ key set_name "std::tr1::shared_ptr<const SetName>"
+ key dep_spec "std::tr1::shared_ptr<const DepSpec>"
key license std::string
doxygen_comment << "END"
@@ -89,8 +89,8 @@ END
make_class_SetMaskConfigEntry()
{
- key set_name "tr1::shared_ptr<const SetName>"
- key dep_spec "tr1::shared_ptr<const DepSpec>"
+ key set_name "std::tr1::shared_ptr<const SetName>"
+ key dep_spec "std::tr1::shared_ptr<const DepSpec>"
doxygen_comment << "END"
/**
diff --git a/paludis/environments/paludis/world.cc b/paludis/environments/paludis/world.cc
index ed4ecb9..08259f4 100644
--- a/paludis/environments/paludis/world.cc
+++ b/paludis/environments/paludis/world.cc
@@ -22,11 +22,11 @@
#include <paludis/util/fs_entry.hh>
#include <paludis/util/mutex.hh>
#include <paludis/util/stringify.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/log.hh>
#include <paludis/set_file.hh>
#include <paludis/user_dep_spec.hh>
#include <paludis/dep_tag.hh>
+#include <tr1/functional>
#include <fstream>
using namespace paludis;
@@ -38,10 +38,10 @@ namespace paludis
struct Implementation<World>
{
const Environment * const env;
- const tr1::shared_ptr<const FSEntry> maybe_world_file;
+ const std::tr1::shared_ptr<const FSEntry> maybe_world_file;
mutable Mutex mutex;
- Implementation(const Environment * const e, const tr1::shared_ptr<const FSEntry> & m) :
+ Implementation(const Environment * const e, const std::tr1::shared_ptr<const FSEntry> & m) :
env(e),
maybe_world_file(m)
{
@@ -49,7 +49,7 @@ namespace paludis
};
}
-World::World(const Environment * const e, const tr1::shared_ptr<const FSEntry> & f) :
+World::World(const Environment * const e, const std::tr1::shared_ptr<const FSEntry> & f) :
PrivateImplementationPattern<World>(new Implementation<World>(e, f))
{
}
@@ -85,7 +85,7 @@ World::remove_from_world(const QualifiedPackageName & q) const
void
World::_add_string_to_world(const std::string & n) const
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
if (! _imp->maybe_world_file)
{
@@ -114,8 +114,8 @@ World::_add_string_to_world(const std::string & n) const
SetFile world(SetFileParams::create()
.file_name(*_imp->maybe_world_file)
.type(sft_simple)
- .parser(tr1::bind(&parse_user_package_dep_spec, _1, UserPackageDepSpecOptions()))
- .tag(tr1::shared_ptr<DepTag>())
+ .parser(std::tr1::bind(&parse_user_package_dep_spec, _1, UserPackageDepSpecOptions()))
+ .tag(std::tr1::shared_ptr<DepTag>())
.set_operator_mode(sfsmo_natural)
.environment(_imp->env));
world.add(n);
@@ -125,7 +125,7 @@ World::_add_string_to_world(const std::string & n) const
void
World::_remove_string_from_world(const std::string & n) const
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
if (! _imp->maybe_world_file)
{
@@ -143,8 +143,8 @@ World::_remove_string_from_world(const std::string & n) const
SetFile world(SetFileParams::create()
.file_name(*_imp->maybe_world_file)
.type(sft_simple)
- .parser(tr1::bind(&parse_user_package_dep_spec, _1, UserPackageDepSpecOptions()))
- .tag(tr1::shared_ptr<DepTag>())
+ .parser(std::tr1::bind(&parse_user_package_dep_spec, _1, UserPackageDepSpecOptions()))
+ .tag(std::tr1::shared_ptr<DepTag>())
.set_operator_mode(sfsmo_natural)
.environment(_imp->env));
@@ -153,12 +153,12 @@ World::_remove_string_from_world(const std::string & n) const
}
}
-tr1::shared_ptr<SetSpecTree::ConstItem>
+std::tr1::shared_ptr<SetSpecTree::ConstItem>
World::world_set() const
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
- tr1::shared_ptr<GeneralSetDepTag> tag(new GeneralSetDepTag(SetName("world"), "Environment"));
+ std::tr1::shared_ptr<GeneralSetDepTag> tag(new GeneralSetDepTag(SetName("world"), "Environment"));
if (_imp->maybe_world_file)
{
@@ -167,7 +167,7 @@ World::world_set() const
SetFile world(SetFileParams::create()
.file_name(*_imp->maybe_world_file)
.type(sft_simple)
- .parser(tr1::bind(&parse_user_package_dep_spec, _1, UserPackageDepSpecOptions()))
+ .parser(std::tr1::bind(&parse_user_package_dep_spec, _1, UserPackageDepSpecOptions()))
.tag(tag)
.set_operator_mode(sfsmo_natural)
.environment(_imp->env));
@@ -178,7 +178,7 @@ World::world_set() const
<< "World file '" << *_imp->maybe_world_file << "' doesn't exist";
}
- return tr1::shared_ptr<SetSpecTree::ConstItem>(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
- tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
+ return std::tr1::shared_ptr<SetSpecTree::ConstItem>(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
+ std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
}
diff --git a/paludis/environments/paludis/world.hh b/paludis/environments/paludis/world.hh
index 87b05a0..a901505 100644
--- a/paludis/environments/paludis/world.hh
+++ b/paludis/environments/paludis/world.hh
@@ -22,10 +22,10 @@
#include <paludis/util/private_implementation_pattern.hh>
#include <paludis/util/fs_entry-fwd.hh>
-#include <paludis/util/tr1_memory.hh>
#include <paludis/name-fwd.hh>
#include <paludis/dep_tree.hh>
#include <paludis/environment-fwd.hh>
+#include <tr1/memory>
#include <string>
namespace paludis
@@ -40,10 +40,10 @@ namespace paludis
void _remove_string_from_world(const std::string &) const;
public:
- World(const Environment * const, const tr1::shared_ptr<const FSEntry> &);
+ World(const Environment * const, const std::tr1::shared_ptr<const FSEntry> &);
~World();
- tr1::shared_ptr<SetSpecTree::ConstItem> world_set() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ std::tr1::shared_ptr<SetSpecTree::ConstItem> world_set() const PALUDIS_ATTRIBUTE((warn_unused_result));
void add_to_world(const SetName &) const;
void add_to_world(const QualifiedPackageName &) const;
diff --git a/paludis/environments/portage/portage_environment.cc b/paludis/environments/portage/portage_environment.cc
index 5651214..be442d5 100644
--- a/paludis/environments/portage/portage_environment.cc
+++ b/paludis/environments/portage/portage_environment.cc
@@ -46,8 +46,8 @@
#include <paludis/user_dep_spec.hh>
#include <paludis/set_file.hh>
#include <paludis/dep_tag.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/mutex.hh>
+#include <tr1/functional>
#include <functional>
#include <algorithm>
#include <set>
@@ -59,10 +59,10 @@
using namespace paludis;
using namespace paludis::portage_environment;
-typedef std::list<std::pair<tr1::shared_ptr<const PackageDepSpec>, std::string> > PackageUse;
-typedef std::list<std::pair<tr1::shared_ptr<const PackageDepSpec>, std::string> > PackageKeywords;
-typedef std::list<tr1::shared_ptr<const PackageDepSpec> > PackageMask;
-typedef std::list<tr1::shared_ptr<const PackageDepSpec> > PackageUnmask;
+typedef std::list<std::pair<std::tr1::shared_ptr<const PackageDepSpec>, std::string> > PackageUse;
+typedef std::list<std::pair<std::tr1::shared_ptr<const PackageDepSpec>, std::string> > PackageKeywords;
+typedef std::list<std::tr1::shared_ptr<const PackageDepSpec> > PackageMask;
+typedef std::list<std::tr1::shared_ptr<const PackageDepSpec> > PackageUnmask;
PortageEnvironmentConfigurationError::PortageEnvironmentConfigurationError(const std::string & s) throw () :
ConfigurationError(s)
@@ -77,7 +77,7 @@ namespace paludis
const FSEntry conf_dir;
std::string paludis_command;
- tr1::shared_ptr<KeyValueConfigFile> vars;
+ std::tr1::shared_ptr<KeyValueConfigFile> vars;
std::set<std::string> use_with_expands;
std::set<std::string> use_expand;
@@ -94,12 +94,12 @@ namespace paludis
mutable Mutex hook_mutex;
mutable bool done_hooks;
- mutable tr1::shared_ptr<Hooker> hooker;
+ mutable std::tr1::shared_ptr<Hooker> hooker;
mutable std::list<FSEntry> hook_dirs;
int overlay_importance;
- tr1::shared_ptr<PackageDatabase> package_database;
+ std::tr1::shared_ptr<PackageDatabase> package_database;
const FSEntry world_file;
mutable Mutex world_mutex;
@@ -178,7 +178,7 @@ namespace
PortageEnvironment::PortageEnvironment(const std::string & s) :
PrivateImplementationPattern<PortageEnvironment>(new Implementation<PortageEnvironment>(this, s))
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
Context context("When creating PortageEnvironment using config root '" + s + "':");
@@ -209,7 +209,7 @@ PortageEnvironment::PortageEnvironment(const std::string & s) :
tokenise_whitespace(_imp->vars->get("PORTDIR_OVERLAY"),
create_inserter<FSEntry>(std::back_inserter(portdir_overlay)));
std::for_each(portdir_overlay.begin(), portdir_overlay.end(),
- tr1::bind(tr1::mem_fn(&PortageEnvironment::_add_portdir_overlay_repository), this, _1));
+ std::tr1::bind(std::tr1::mem_fn(&PortageEnvironment::_add_portdir_overlay_repository), this, _1));
/* use etc */
@@ -286,7 +286,7 @@ template<typename I_>
void
PortageEnvironment::_load_atom_file(const FSEntry & f, I_ i, const std::string & def_value)
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
Context context("When loading '" + stringify(f) + "':");
@@ -295,7 +295,7 @@ PortageEnvironment::_load_atom_file(const FSEntry & f, I_ i, const std::string &
if (f.is_directory())
{
- std::for_each(DirIterator(f), DirIterator(), tr1::bind(
+ std::for_each(DirIterator(f), DirIterator(), std::tr1::bind(
&PortageEnvironment::_load_atom_file<I_>, this, _1, i, def_value));
}
else
@@ -310,7 +310,7 @@ PortageEnvironment::_load_atom_file(const FSEntry & f, I_ i, const std::string &
if (tokens.empty())
continue;
- tr1::shared_ptr<PackageDepSpec> p(new PackageDepSpec(parse_user_package_dep_spec(
+ std::tr1::shared_ptr<PackageDepSpec> p(new PackageDepSpec(parse_user_package_dep_spec(
tokens.at(0), UserPackageDepSpecOptions())));
if (1 == tokens.size())
{
@@ -331,7 +331,7 @@ template<typename I_>
void
PortageEnvironment::_load_lined_file(const FSEntry & f, I_ i)
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
Context context("When loading '" + stringify(f) + "':");
@@ -340,7 +340,7 @@ PortageEnvironment::_load_lined_file(const FSEntry & f, I_ i)
if (f.is_directory())
{
- std::for_each(DirIterator(f), DirIterator(), tr1::bind(
+ std::for_each(DirIterator(f), DirIterator(), std::tr1::bind(
&PortageEnvironment::_load_lined_file<I_>, this, _1, i));
}
else
@@ -348,7 +348,7 @@ PortageEnvironment::_load_lined_file(const FSEntry & f, I_ i)
LineConfigFile file(f, LineConfigFileOptions());
for (LineConfigFile::ConstIterator line(file.begin()), line_end(file.end()) ;
line != line_end ; ++line)
- *i++ = tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(
+ *i++ = std::tr1::shared_ptr<PackageDepSpec>(new PackageDepSpec(
parse_user_package_dep_spec(strip_trailing(strip_leading(*line, " \t"), " \t"), UserPackageDepSpecOptions())));
}
}
@@ -375,7 +375,7 @@ PortageEnvironment::_load_profile(const FSEntry & d)
void
PortageEnvironment::_add_virtuals_repository()
{
- tr1::shared_ptr<Map<std::string, std::string> > keys(
+ std::tr1::shared_ptr<Map<std::string, std::string> > keys(
new Map<std::string, std::string>);
package_database()->add_repository(-2,
RepositoryMaker::get_instance()->find_maker("virtuals")(this, keys));
@@ -384,7 +384,7 @@ PortageEnvironment::_add_virtuals_repository()
void
PortageEnvironment::_add_installed_virtuals_repository()
{
- tr1::shared_ptr<Map<std::string, std::string> > keys(
+ std::tr1::shared_ptr<Map<std::string, std::string> > keys(
new Map<std::string, std::string>);
keys->insert("root", stringify(root()));
package_database()->add_repository(-1,
@@ -402,7 +402,7 @@ void
PortageEnvironment::_add_ebuild_repository(const FSEntry & portdir, const std::string & master,
const std::string & sync, int importance)
{
- tr1::shared_ptr<Map<std::string, std::string> > keys(
+ std::tr1::shared_ptr<Map<std::string, std::string> > keys(
new Map<std::string, std::string>);
keys->insert("root", stringify(root()));
keys->insert("location", stringify(portdir));
@@ -435,7 +435,7 @@ PortageEnvironment::_add_vdb_repository()
{
Context context("When creating vdb repository:");
- tr1::shared_ptr<Map<std::string, std::string> > keys(
+ std::tr1::shared_ptr<Map<std::string, std::string> > keys(
new Map<std::string, std::string>);
keys->insert("root", stringify(root()));
keys->insert("location", stringify(root() / "/var/db/pkg"));
@@ -531,7 +531,7 @@ PortageEnvironment::set_paludis_command(const std::string & s)
}
bool
-PortageEnvironment::accept_keywords(tr1::shared_ptr <const KeywordNameSet> keywords,
+PortageEnvironment::accept_keywords(std::tr1::shared_ptr <const KeywordNameSet> keywords,
const PackageID & d) const
{
bool result(false);
@@ -589,13 +589,13 @@ PortageEnvironment::unmasked_by_user(const PackageID & e) const
return false;
}
-tr1::shared_ptr<const UseFlagNameSet>
+std::tr1::shared_ptr<const UseFlagNameSet>
PortageEnvironment::known_use_expand_names(const UseFlagName & prefix,
const PackageID & pde) const
{
Context context("When loading known use expand names for prefix '" + stringify(prefix) + ":");
- tr1::shared_ptr<UseFlagNameSet> result(new UseFlagNameSet);
+ std::tr1::shared_ptr<UseFlagNameSet> result(new UseFlagNameSet);
std::string prefix_lower;
std::transform(prefix.data().begin(), prefix.data().end(), std::back_inserter(prefix_lower), &::tolower);
prefix_lower.append("_");
@@ -625,7 +625,7 @@ PortageEnvironment::known_use_expand_names(const UseFlagName & prefix,
HookResult
PortageEnvironment::perform_hook(const Hook & hook) const
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
Lock l(_imp->hook_mutex);
if (! _imp->hooker)
@@ -633,59 +633,59 @@ PortageEnvironment::perform_hook(const Hook & hook) const
_imp->need_hook_dirs();
_imp->hooker.reset(new Hooker(this));
std::for_each(_imp->hook_dirs.begin(), _imp->hook_dirs.end(),
- tr1::bind(tr1::mem_fn(&Hooker::add_dir), _imp->hooker.get(), _1, false));
+ std::tr1::bind(std::tr1::mem_fn(&Hooker::add_dir), _imp->hooker.get(), _1, false));
}
return _imp->hooker->perform_hook(hook);
}
-tr1::shared_ptr<const FSEntrySequence>
+std::tr1::shared_ptr<const FSEntrySequence>
PortageEnvironment::hook_dirs() const
{
Lock l(_imp->hook_mutex);
_imp->need_hook_dirs();
- tr1::shared_ptr<FSEntrySequence> result(new FSEntrySequence);
+ std::tr1::shared_ptr<FSEntrySequence> result(new FSEntrySequence);
std::copy(_imp->hook_dirs.begin(), _imp->hook_dirs.end(), result->back_inserter());
return result;
}
-tr1::shared_ptr<const FSEntrySequence>
+std::tr1::shared_ptr<const FSEntrySequence>
PortageEnvironment::bashrc_files() const
{
- tr1::shared_ptr<FSEntrySequence> result(new FSEntrySequence);
+ std::tr1::shared_ptr<FSEntrySequence> result(new FSEntrySequence);
result->push_back(FSEntry(LIBEXECDIR) / "paludis" / "environments" / "portage" / "bashrc");
result->push_back(_imp->conf_dir / "make.globals");
result->push_back(_imp->conf_dir / "make.conf");
return result;
}
-tr1::shared_ptr<PackageDatabase>
+std::tr1::shared_ptr<PackageDatabase>
PortageEnvironment::package_database()
{
return _imp->package_database;
}
-tr1::shared_ptr<const PackageDatabase>
+std::tr1::shared_ptr<const PackageDatabase>
PortageEnvironment::package_database() const
{
return _imp->package_database;
}
-tr1::shared_ptr<const MirrorsSequence>
+std::tr1::shared_ptr<const MirrorsSequence>
PortageEnvironment::mirrors(const std::string & m) const
{
std::pair<std::multimap<std::string, std::string>::const_iterator, std::multimap<std::string, std::string>::const_iterator>
p(_imp->mirrors.equal_range(m));
- tr1::shared_ptr<MirrorsSequence> result(new MirrorsSequence);
+ std::tr1::shared_ptr<MirrorsSequence> result(new MirrorsSequence);
std::transform(p.first, p.second, result->back_inserter(),
- tr1::mem_fn(&std::pair<const std::string, std::string>::second));
+ std::tr1::mem_fn(&std::pair<const std::string, std::string>::second));
return result;
}
-tr1::shared_ptr<SetSpecTree::ConstItem>
+std::tr1::shared_ptr<SetSpecTree::ConstItem>
PortageEnvironment::local_set(const SetName &) const
{
- return tr1::shared_ptr<SetSpecTree::ConstItem>();
+ return std::tr1::shared_ptr<SetSpecTree::ConstItem>();
}
bool
@@ -739,12 +739,12 @@ namespace
};
}
-const tr1::shared_ptr<const Mask>
+const std::tr1::shared_ptr<const Mask>
PortageEnvironment::mask_for_breakage(const PackageID & id) const
{
if (! _imp->ignore_all_breaks_portage)
{
- tr1::shared_ptr<const Set<std::string> > breakages(id.breaks_portage());
+ std::tr1::shared_ptr<const Set<std::string> > breakages(id.breaks_portage());
if (breakages)
{
std::set<std::string> bad_breakages;
@@ -756,10 +756,10 @@ PortageEnvironment::mask_for_breakage(const PackageID & id) const
}
}
- return tr1::shared_ptr<const Mask>();
+ return std::tr1::shared_ptr<const Mask>();
}
-const tr1::shared_ptr<const Mask>
+const std::tr1::shared_ptr<const Mask>
PortageEnvironment::mask_for_user(const PackageID & d) const
{
for (PackageMask::const_iterator i(_imp->package_mask.begin()), i_end(_imp->package_mask.end()) ;
@@ -767,7 +767,7 @@ PortageEnvironment::mask_for_user(const PackageID & d) const
if (match_package(*this, **i, d))
return make_shared_ptr(new UserConfigMask);
- return tr1::shared_ptr<const Mask>();
+ return std::tr1::shared_ptr<const Mask>();
}
gid_t
@@ -813,7 +813,7 @@ PortageEnvironment::_add_string_to_world(const std::string & s) const
Context context("When adding '" + s + "' to world file '" + stringify(_imp->world_file) + "':");
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
if (! _imp->world_file.exists())
{
@@ -829,8 +829,8 @@ PortageEnvironment::_add_string_to_world(const std::string & s) const
SetFile world(SetFileParams::create()
.file_name(_imp->world_file)
.type(sft_simple)
- .parser(tr1::bind(&parse_user_package_dep_spec, _1, UserPackageDepSpecOptions()))
- .tag(tr1::shared_ptr<DepTag>())
+ .parser(std::tr1::bind(&parse_user_package_dep_spec, _1, UserPackageDepSpecOptions()))
+ .tag(std::tr1::shared_ptr<DepTag>())
.set_operator_mode(sfsmo_natural)
.environment(this));
world.add(s);
@@ -844,15 +844,15 @@ PortageEnvironment::_remove_string_from_world(const std::string & s) const
Context context("When removing '" + s + "' from world file '" + stringify(_imp->world_file) + "':");
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
if (_imp->world_file.exists())
{
SetFile world(SetFileParams::create()
.file_name(_imp->world_file)
.type(sft_simple)
- .parser(tr1::bind(&parse_user_package_dep_spec, _1, UserPackageDepSpecOptions()))
- .tag(tr1::shared_ptr<DepTag>())
+ .parser(std::tr1::bind(&parse_user_package_dep_spec, _1, UserPackageDepSpecOptions()))
+ .tag(std::tr1::shared_ptr<DepTag>())
.set_operator_mode(sfsmo_natural)
.environment(this));
@@ -861,14 +861,14 @@ PortageEnvironment::_remove_string_from_world(const std::string & s) const
}
}
-tr1::shared_ptr<SetSpecTree::ConstItem>
+std::tr1::shared_ptr<SetSpecTree::ConstItem>
PortageEnvironment::world_set() const
{
Context context("When fetching environment world set:");
- tr1::shared_ptr<GeneralSetDepTag> tag(new GeneralSetDepTag(SetName("world"), stringify("Environment")));
+ std::tr1::shared_ptr<GeneralSetDepTag> tag(new GeneralSetDepTag(SetName("world"), stringify("Environment")));
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
Lock l(_imp->world_mutex);
@@ -877,7 +877,7 @@ PortageEnvironment::world_set() const
SetFile world(SetFileParams::create()
.file_name(_imp->world_file)
.type(sft_simple)
- .parser(tr1::bind(&parse_user_package_dep_spec, _1, UserPackageDepSpecOptions()))
+ .parser(std::tr1::bind(&parse_user_package_dep_spec, _1, UserPackageDepSpecOptions()))
.tag(tag)
.set_operator_mode(sfsmo_natural)
.environment(this));
@@ -887,7 +887,7 @@ PortageEnvironment::world_set() const
Log::get_instance()->message("portage_environment.world_file.does_not_exist", ll_warning, lc_no_context) <<
"World file '" << _imp->world_file << "' doesn't exist";
- return tr1::shared_ptr<SetSpecTree::ConstItem>(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
- tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
+ return std::tr1::shared_ptr<SetSpecTree::ConstItem>(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
+ std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
}
diff --git a/paludis/environments/portage/portage_environment.hh b/paludis/environments/portage/portage_environment.hh
index 0370220..094ceb7 100644
--- a/paludis/environments/portage/portage_environment.hh
+++ b/paludis/environments/portage/portage_environment.hh
@@ -78,10 +78,10 @@ namespace paludis
void _remove_string_from_world(const std::string &) const;
protected:
- virtual tr1::shared_ptr<SetSpecTree::ConstItem> local_set(const SetName &) const
+ virtual std::tr1::shared_ptr<SetSpecTree::ConstItem> local_set(const SetName &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<SetSpecTree::ConstItem> world_set() const
+ virtual std::tr1::shared_ptr<SetSpecTree::ConstItem> world_set() const
PALUDIS_ATTRIBUTE((warn_unused_result));
public:
@@ -96,29 +96,29 @@ namespace paludis
virtual bool query_use(const UseFlagName &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const UseFlagNameSet> known_use_expand_names(
+ virtual std::tr1::shared_ptr<const UseFlagNameSet> known_use_expand_names(
const UseFlagName &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const FSEntrySequence> bashrc_files() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> bashrc_files() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const FSEntrySequence> hook_dirs() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> hook_dirs() const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual const FSEntry root() const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const MirrorsSequence> mirrors(const std::string &) const
+ virtual std::tr1::shared_ptr<const MirrorsSequence> mirrors(const std::string &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual HookResult perform_hook(const Hook &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<PackageDatabase> package_database()
+ virtual std::tr1::shared_ptr<PackageDatabase> package_database()
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const PackageDatabase> package_database() const
+ virtual std::tr1::shared_ptr<const PackageDatabase> package_database() const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual std::string paludis_command() const
@@ -129,13 +129,13 @@ namespace paludis
virtual bool accept_license(const std::string &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual bool accept_keywords(tr1::shared_ptr<const KeywordNameSet>, const PackageID &) const
+ virtual bool accept_keywords(std::tr1::shared_ptr<const KeywordNameSet>, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual const tr1::shared_ptr<const Mask> mask_for_breakage(const PackageID &) const
+ virtual const std::tr1::shared_ptr<const Mask> mask_for_breakage(const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual const tr1::shared_ptr<const Mask> mask_for_user(const PackageID &) const
+ virtual const std::tr1::shared_ptr<const Mask> mask_for_user(const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual bool unmasked_by_user(const PackageID &) const
diff --git a/paludis/environments/portage/portage_environment_TEST.cc b/paludis/environments/portage/portage_environment_TEST.cc
index 02877f6..1d70b20 100644
--- a/paludis/environments/portage/portage_environment_TEST.cc
+++ b/paludis/environments/portage/portage_environment_TEST.cc
@@ -52,7 +52,7 @@ namespace
bool accept_keyword(const TestPortageEnvironment & env,
const KeywordName & k, const PackageID & e)
{
- tr1::shared_ptr<KeywordNameSet> kk(new KeywordNameSet);
+ std::tr1::shared_ptr<KeywordNameSet> kk(new KeywordNameSet);
kk->insert(k);
return env.accept_keywords(kk, e);
}
@@ -68,10 +68,10 @@ namespace test_cases
{
PortageEnvironment env("portage_environment_TEST_dir/query_use");
- const tr1::shared_ptr<const PackageID> idx(*env.package_database()->query(
+ const std::tr1::shared_ptr<const PackageID> idx(*env.package_database()->query(
query::Matches(PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-x-1", UserPackageDepSpecOptions()))), qo_require_exactly_one)->begin());
- const tr1::shared_ptr<const PackageID> id1(*env.package_database()->query(
+ const std::tr1::shared_ptr<const PackageID> id1(*env.package_database()->query(
query::Matches(PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-one-1", UserPackageDepSpecOptions()))), qo_require_exactly_one)->begin());
TEST_CHECK(env.query_use(UseFlagName("one"), *idx));
@@ -96,9 +96,9 @@ namespace test_cases
{
PortageEnvironment env("portage_environment_TEST_dir/known_use_expand_names");
- const tr1::shared_ptr<const PackageID> id1(*env.package_database()->query(
+ const std::tr1::shared_ptr<const PackageID> id1(*env.package_database()->query(
query::Matches(PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-one-1", UserPackageDepSpecOptions()))), qo_require_exactly_one)->begin());
- tr1::shared_ptr<const UseFlagNameSet> k1(env.known_use_expand_names(UseFlagName("foo_cards"), *id1));
+ std::tr1::shared_ptr<const UseFlagNameSet> k1(env.known_use_expand_names(UseFlagName("foo_cards"), *id1));
TEST_CHECK_EQUAL(join(k1->begin(), k1->end(), " "), "foo_cards_one foo_cards_three");
}
} test_known_use_expand;
@@ -111,35 +111,35 @@ namespace test_cases
{
TestPortageEnvironment env("portage_environment_TEST_dir/accept_keywords");
- const tr1::shared_ptr<const PackageID> idx(*env.package_database()->query(
+ const std::tr1::shared_ptr<const PackageID> idx(*env.package_database()->query(
query::Matches(PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-x-1", UserPackageDepSpecOptions()))), qo_require_exactly_one)->begin());
TEST_CHECK(accept_keyword(env, KeywordName("arch"), *idx));
TEST_CHECK(accept_keyword(env, KeywordName("other_arch"), *idx));
TEST_CHECK(! accept_keyword(env, KeywordName("~arch"), *idx));
- const tr1::shared_ptr<const PackageID> id1(*env.package_database()->query(
+ const std::tr1::shared_ptr<const PackageID> id1(*env.package_database()->query(
query::Matches(PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-one-1", UserPackageDepSpecOptions()))), qo_require_exactly_one)->begin());
TEST_CHECK(accept_keyword(env, KeywordName("arch"), *id1));
TEST_CHECK(accept_keyword(env, KeywordName("other_arch"), *id1));
TEST_CHECK(accept_keyword(env, KeywordName("~arch"), *id1));
- const tr1::shared_ptr<const PackageID> id2(*env.package_database()->query(
+ const std::tr1::shared_ptr<const PackageID> id2(*env.package_database()->query(
query::Matches(PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-two-1", UserPackageDepSpecOptions()))), qo_require_exactly_one)->begin());
TEST_CHECK(accept_keyword(env, KeywordName("other_arch"), *id2));
TEST_CHECK(accept_keyword(env, KeywordName("arch"), *id2));
TEST_CHECK(accept_keyword(env, KeywordName("~arch"), *id2));
- const tr1::shared_ptr<const PackageID> id3(*env.package_database()->query(
+ const std::tr1::shared_ptr<const PackageID> id3(*env.package_database()->query(
query::Matches(PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-three-1", UserPackageDepSpecOptions()))), qo_require_exactly_one)->begin());
TEST_CHECK(! accept_keyword(env, KeywordName("other_arch"), *id3));
TEST_CHECK(! accept_keyword(env, KeywordName("arch"), *id3));
TEST_CHECK(! accept_keyword(env, KeywordName("~arch"), *id3));
- const tr1::shared_ptr<const PackageID> id4(*env.package_database()->query(
+ const std::tr1::shared_ptr<const PackageID> id4(*env.package_database()->query(
query::Matches(PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-four-1", UserPackageDepSpecOptions()))), qo_require_exactly_one)->begin());
TEST_CHECK(accept_keyword(env, KeywordName("fred"), *id4));
}
diff --git a/paludis/environments/portage/registration.cc b/paludis/environments/portage/registration.cc
index 9f589d3..bdc6ada 100644
--- a/paludis/environments/portage/registration.cc
+++ b/paludis/environments/portage/registration.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007 Ciaran McCreesh
+ * Copyright (c) 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -24,10 +24,10 @@ using namespace paludis;
namespace
{
- tr1::shared_ptr<Environment>
+ std::tr1::shared_ptr<Environment>
make_portage_environment(const std::string & s)
{
- return tr1::shared_ptr<Environment>(new PortageEnvironment(s));
+ return std::tr1::shared_ptr<Environment>(new PortageEnvironment(s));
}
}
diff --git a/paludis/environments/test/test_environment.cc b/paludis/environments/test/test_environment.cc
index 0243fbf..525e800 100644
--- a/paludis/environments/test/test_environment.cc
+++ b/paludis/environments/test/test_environment.cc
@@ -19,7 +19,6 @@
#include <paludis/environments/test/test_environment.hh>
#include <paludis/util/private_implementation_pattern-impl.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/set.hh>
#include <paludis/util/wrapped_forward_iterator.hh>
#include <paludis/util/sequence.hh>
@@ -27,6 +26,7 @@
#include <paludis/package_database.hh>
#include <paludis/package_id.hh>
#include <paludis/hook.hh>
+#include <tr1/functional>
#include <string>
using namespace paludis;
@@ -36,7 +36,7 @@ namespace paludis
template<>
struct Implementation<TestEnvironment>
{
- tr1::shared_ptr<PackageDatabase> package_database;
+ std::tr1::shared_ptr<PackageDatabase> package_database;
std::string paludis_command;
Implementation(Environment * const e) :
@@ -66,7 +66,7 @@ TestEnvironment::query_use(const UseFlagName & u, const PackageID & p) const
}
bool
-TestEnvironment::accept_keywords(tr1::shared_ptr<const KeywordNameSet> k, const PackageID &) const
+TestEnvironment::accept_keywords(std::tr1::shared_ptr<const KeywordNameSet> k, const PackageID &) const
{
return k->end() != k->find(KeywordName("test")) || k->end() != k->find(KeywordName("*"));
}
@@ -77,13 +77,13 @@ TestEnvironment::accept_license(const std::string &, const PackageID &) const
return true;
}
-tr1::shared_ptr<PackageDatabase>
+std::tr1::shared_ptr<PackageDatabase>
TestEnvironment::package_database()
{
return _imp->package_database;
}
-tr1::shared_ptr<const PackageDatabase>
+std::tr1::shared_ptr<const PackageDatabase>
TestEnvironment::package_database() const
{
return _imp->package_database;
@@ -101,13 +101,13 @@ TestEnvironment::set_paludis_command(const std::string & s)
_imp->paludis_command = s;
}
-const tr1::shared_ptr<const PackageID>
+const std::tr1::shared_ptr<const PackageID>
TestEnvironment::fetch_package_id(const QualifiedPackageName & q,
const VersionSpec & v, const RepositoryName & r) const
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
- tr1::shared_ptr<const PackageIDSequence> ids(package_database()->fetch_repository(r)->package_ids(q));
+ std::tr1::shared_ptr<const PackageIDSequence> ids(package_database()->fetch_repository(r)->package_ids(q));
for (PackageIDSequence::ConstIterator i(ids->begin()), i_end(ids->end()) ;
i != i_end ; ++i)
if (v == (*i)->version())
@@ -115,10 +115,10 @@ TestEnvironment::fetch_package_id(const QualifiedPackageName & q,
throw NoSuchPackageError(stringify(q) + "-" + stringify(v) + "::" + stringify(r));
}
-tr1::shared_ptr<SetSpecTree::ConstItem>
+std::tr1::shared_ptr<SetSpecTree::ConstItem>
TestEnvironment::local_set(const SetName &) const
{
- return tr1::shared_ptr<SetSpecTree::ConstItem>();
+ return std::tr1::shared_ptr<SetSpecTree::ConstItem>();
}
uid_t
@@ -139,10 +139,10 @@ TestEnvironment::root() const
return FSEntry("/");
}
-tr1::shared_ptr<const MirrorsSequence>
+std::tr1::shared_ptr<const MirrorsSequence>
TestEnvironment::mirrors(const std::string & s) const
{
- tr1::shared_ptr<MirrorsSequence> result(new MirrorsSequence);
+ std::tr1::shared_ptr<MirrorsSequence> result(new MirrorsSequence);
if (s == "example")
{
@@ -159,22 +159,22 @@ TestEnvironment::perform_hook(const Hook &) const
return HookResult(0, "");
}
-tr1::shared_ptr<const FSEntrySequence>
+std::tr1::shared_ptr<const FSEntrySequence>
TestEnvironment::hook_dirs() const
{
return make_shared_ptr(new FSEntrySequence);
}
-const tr1::shared_ptr<const Mask>
+const std::tr1::shared_ptr<const Mask>
TestEnvironment::mask_for_breakage(const PackageID &) const
{
- return tr1::shared_ptr<const Mask>();
+ return std::tr1::shared_ptr<const Mask>();
}
-const tr1::shared_ptr<const Mask>
+const std::tr1::shared_ptr<const Mask>
TestEnvironment::mask_for_user(const PackageID &) const
{
- return tr1::shared_ptr<const Mask>();
+ return std::tr1::shared_ptr<const Mask>();
}
bool
@@ -183,16 +183,16 @@ TestEnvironment::unmasked_by_user(const PackageID &) const
return false;
}
-tr1::shared_ptr<const UseFlagNameSet>
+std::tr1::shared_ptr<const UseFlagNameSet>
TestEnvironment::known_use_expand_names(const UseFlagName &, const PackageID &) const
{
return make_shared_ptr(new UseFlagNameSet);
}
-tr1::shared_ptr<SetSpecTree::ConstItem>
+std::tr1::shared_ptr<SetSpecTree::ConstItem>
TestEnvironment::world_set() const
{
- return tr1::shared_ptr<SetSpecTree::ConstItem>();
+ return std::tr1::shared_ptr<SetSpecTree::ConstItem>();
}
void
diff --git a/paludis/environments/test/test_environment.hh b/paludis/environments/test/test_environment.hh
index d4a9dcc..4f6384f 100644
--- a/paludis/environments/test/test_environment.hh
+++ b/paludis/environments/test/test_environment.hh
@@ -44,10 +44,10 @@ namespace paludis
public EnvironmentImplementation
{
protected:
- virtual tr1::shared_ptr<SetSpecTree::ConstItem> local_set(const SetName &) const
+ virtual std::tr1::shared_ptr<SetSpecTree::ConstItem> local_set(const SetName &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<SetSpecTree::ConstItem> world_set() const
+ virtual std::tr1::shared_ptr<SetSpecTree::ConstItem> world_set() const
PALUDIS_ATTRIBUTE((warn_unused_result));
public:
@@ -63,10 +63,10 @@ namespace paludis
virtual bool query_use(const UseFlagName &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<PackageDatabase> package_database()
+ virtual std::tr1::shared_ptr<PackageDatabase> package_database()
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const PackageDatabase> package_database() const
+ virtual std::tr1::shared_ptr<const PackageDatabase> package_database() const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual std::string paludis_command() const
@@ -77,29 +77,29 @@ namespace paludis
/**
* Convenience way of getting a package id.
*/
- const tr1::shared_ptr<const PackageID> fetch_package_id(const QualifiedPackageName &,
+ const std::tr1::shared_ptr<const PackageID> fetch_package_id(const QualifiedPackageName &,
const VersionSpec &, const RepositoryName &) const PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const UseFlagNameSet> known_use_expand_names(
+ virtual std::tr1::shared_ptr<const UseFlagNameSet> known_use_expand_names(
const UseFlagName &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual bool accept_license(const std::string &, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual bool accept_keywords(tr1::shared_ptr<const KeywordNameSet>, const PackageID &) const
+ virtual bool accept_keywords(std::tr1::shared_ptr<const KeywordNameSet>, const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual const tr1::shared_ptr<const Mask> mask_for_breakage(const PackageID &) const
+ virtual const std::tr1::shared_ptr<const Mask> mask_for_breakage(const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual const tr1::shared_ptr<const Mask> mask_for_user(const PackageID &) const
+ virtual const std::tr1::shared_ptr<const Mask> mask_for_user(const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual bool unmasked_by_user(const PackageID &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
- virtual tr1::shared_ptr<const FSEntrySequence> hook_dirs() const
+ virtual std::tr1::shared_ptr<const FSEntrySequence> hook_dirs() const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual const FSEntry root() const;
@@ -108,7 +108,7 @@ namespace paludis
virtual gid_t reduced_gid() const;
- virtual tr1::shared_ptr<const MirrorsSequence> mirrors(const std::string &) const
+ virtual std::tr1::shared_ptr<const MirrorsSequence> mirrors(const std::string &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
virtual HookResult perform_hook(const Hook &) const
diff --git a/paludis/files.m4 b/paludis/files.m4
index 2e9ad5a..8cbd5b6 100644
--- a/paludis/files.m4
+++ b/paludis/files.m4
@@ -28,7 +28,6 @@ add(`find_unused_packages_task', `hh', `cc')
add(`fuzzy_finder', `hh', `cc', `test')
add(`formatter', `hh', `fwd', `cc')
add(`handled_information', `hh', `fwd', `cc')
-add(`hashed_containers', `hh', `cc', `test')
add(`hook', `hh', `cc', `fwd',`se', `sr')
add(`hooker', `hh', `cc', `test', `testscript')
add(`host_tuple_name', `hh', `cc', `sr', `test')
diff --git a/paludis/find_unused_packages_task.cc b/paludis/find_unused_packages_task.cc
index d02121b..ba0a8a2 100644
--- a/paludis/find_unused_packages_task.cc
+++ b/paludis/find_unused_packages_task.cc
@@ -38,11 +38,11 @@ FindUnusedPackagesTask::~FindUnusedPackagesTask()
{
}
-tr1::shared_ptr<const PackageIDSequence>
+std::tr1::shared_ptr<const PackageIDSequence>
FindUnusedPackagesTask::execute(const QualifiedPackageName & package)
{
- tr1::shared_ptr<PackageIDSequence> result(new PackageIDSequence);
- tr1::shared_ptr<const PackageIDSequence> packages(_env->package_database()->query(
+ std::tr1::shared_ptr<PackageIDSequence> result(new PackageIDSequence);
+ std::tr1::shared_ptr<const PackageIDSequence> packages(_env->package_database()->query(
query::Matches(make_package_dep_spec()
.package(package)
.repository(_repo->name())),
@@ -62,7 +62,7 @@ FindUnusedPackagesTask::execute(const QualifiedPackageName & package)
old_slot = (*p)->slot();
}
- tr1::shared_ptr<const KeywordNameSet> current_keywords((*p)->keywords_key()->value());
+ std::tr1::shared_ptr<const KeywordNameSet> current_keywords((*p)->keywords_key()->value());
bool used(false);
for (KeywordNameSet::ConstIterator k(current_keywords->begin()), k_end(current_keywords->end()) ;
k != k_end ; ++k)
diff --git a/paludis/find_unused_packages_task.hh b/paludis/find_unused_packages_task.hh
index 1807650..7f5e390 100644
--- a/paludis/find_unused_packages_task.hh
+++ b/paludis/find_unused_packages_task.hh
@@ -68,7 +68,7 @@ namespace paludis
/**
* Run the task.
*/
- tr1::shared_ptr<const PackageIDSequence> execute(const QualifiedPackageName &);
+ std::tr1::shared_ptr<const PackageIDSequence> execute(const QualifiedPackageName &);
};
}
diff --git a/paludis/formatter.hh b/paludis/formatter.hh
index 470d22b..82cbcba 100644
--- a/paludis/formatter.hh
+++ b/paludis/formatter.hh
@@ -355,28 +355,28 @@ namespace paludis
};
/**
- * A tr1::shared_ptr<T_> shouldn't be specified.
+ * A std::tr1::shared_ptr<T_> shouldn't be specified.
*
* \ingroup g_formatters
* \since 0.26
* \nosubgrouping
*/
template <typename T_>
- struct CategorySelector<tr1::shared_ptr<T_> >
+ struct CategorySelector<std::tr1::shared_ptr<T_> >
{
/// This role is wrong.
typedef typename CategorySelector<T_>::ThisRoleIsWrong ThisRoleIsWrong;
};
/**
- * A tr1::shared_ptr<const T_> shouldn't be specified.
+ * A std::tr1::shared_ptr<const T_> shouldn't be specified.
*
* \ingroup g_formatters
* \since 0.26
* \nosubgrouping
*/
template <typename T_>
- struct CategorySelector<tr1::shared_ptr<const T_> >
+ struct CategorySelector<std::tr1::shared_ptr<const T_> >
{
/// This role is wrong.
typedef typename CategorySelector<T_>::ThisRoleIsWrong ThisRoleIsWrong;
diff --git a/paludis/fuzzy_finder.cc b/paludis/fuzzy_finder.cc
index 1b7ccf7..595c83c 100644
--- a/paludis/fuzzy_finder.cc
+++ b/paludis/fuzzy_finder.cc
@@ -77,9 +77,9 @@ namespace
{
}
- virtual tr1::shared_ptr<QualifiedPackageNameSet> packages(const Environment &,
- tr1::shared_ptr<const RepositoryNameSequence>,
- tr1::shared_ptr<const CategoryNamePartSet>) const;
+ virtual std::tr1::shared_ptr<QualifiedPackageNameSet> packages(const Environment &,
+ std::tr1::shared_ptr<const RepositoryNameSequence>,
+ std::tr1::shared_ptr<const CategoryNamePartSet>) const;
std::string as_human_readable_string() const
{
@@ -87,22 +87,22 @@ namespace
}
};
- tr1::shared_ptr<QualifiedPackageNameSet>
+ std::tr1::shared_ptr<QualifiedPackageNameSet>
FuzzyPackageNameDelegate::packages(const Environment & e,
- tr1::shared_ptr<const RepositoryNameSequence> repos,
- tr1::shared_ptr<const CategoryNamePartSet> cats) const
+ std::tr1::shared_ptr<const RepositoryNameSequence> repos,
+ std::tr1::shared_ptr<const CategoryNamePartSet> cats) const
{
- tr1::shared_ptr<QualifiedPackageNameSet> result(new QualifiedPackageNameSet);
+ std::tr1::shared_ptr<QualifiedPackageNameSet> result(new QualifiedPackageNameSet);
for (RepositoryNameSequence::ConstIterator r(repos->begin()),
r_end(repos->end()); r_end != r; ++r)
{
- tr1::shared_ptr<const Repository> repo(e.package_database()->fetch_repository(*r));
+ std::tr1::shared_ptr<const Repository> repo(e.package_database()->fetch_repository(*r));
for (CategoryNamePartSet::ConstIterator c(cats->begin()),
c_end(cats->end()); c_end != c; ++c)
{
- tr1::shared_ptr<const QualifiedPackageNameSet> pkgs(repo->package_names(*c));
+ std::tr1::shared_ptr<const QualifiedPackageNameSet> pkgs(repo->package_names(*c));
for (QualifiedPackageNameSet::ConstIterator p(pkgs->begin()),
p_end(pkgs->end()); p_end != p; ++p)
if (tolower(p->package.data()[0]) == _first_char &&
@@ -119,7 +119,7 @@ namespace
{
public:
FuzzyPackageName(const std::string & p) :
- Query(tr1::shared_ptr<QueryDelegate>(new FuzzyPackageNameDelegate(p)))
+ Query(std::tr1::shared_ptr<QueryDelegate>(new FuzzyPackageNameDelegate(p)))
{
}
};
@@ -154,7 +154,7 @@ FuzzyCandidatesFinder::FuzzyCandidatesFinder(const Environment & e, const std::s
real_generator = real_generator & query::Repository(*pds.repository_ptr());
}
- tr1::shared_ptr<const PackageIDSequence> ids(e.package_database()->query(real_generator & FuzzyPackageName(package), qo_best_version_only));
+ std::tr1::shared_ptr<const PackageIDSequence> ids(e.package_database()->query(real_generator & FuzzyPackageName(package), qo_best_version_only));
for (PackageIDSequence::ConstIterator i(ids->begin()), i_end(ids->end())
; i != i_end ; ++i)
diff --git a/paludis/fuzzy_finder_TEST.cc b/paludis/fuzzy_finder_TEST.cc
index fbf8db2..9781cfa 100644
--- a/paludis/fuzzy_finder_TEST.cc
+++ b/paludis/fuzzy_finder_TEST.cc
@@ -40,14 +40,14 @@ namespace test_cases
{
TestEnvironment e;
- tr1::shared_ptr<FakeRepository> r1(new FakeRepository(&e, RepositoryName("r1")));
+ std::tr1::shared_ptr<FakeRepository> r1(new FakeRepository(&e, RepositoryName("r1")));
r1->add_version("some-cat", "foo", "1");
r1->add_version("other-cat", "foo", "1");
r1->add_version("some-cat", "bar", "1");
r1->add_version("some-cat", "one-two-three", "1");
e.package_database()->add_repository(1, r1);
- tr1::shared_ptr<FakeRepository> r2(new FakeRepository(&e, RepositoryName("r2")));
+ std::tr1::shared_ptr<FakeRepository> r2(new FakeRepository(&e, RepositoryName("r2")));
e.package_database()->add_repository(2, r2);
FuzzyCandidatesFinder f1(e, std::string("some-cat/one-two-thee"), query::All());
@@ -80,11 +80,11 @@ namespace test_cases
TestEnvironment e;
PackageDatabase & p(*e.package_database());
- p.add_repository(1, tr1::shared_ptr<FakeRepository>(new FakeRepository(&e, RepositoryName("my-main-repository"))));
- p.add_repository(1, tr1::shared_ptr<FakeRepository>(new FakeRepository(&e, RepositoryName("x-new-repository"))));
- p.add_repository(1, tr1::shared_ptr<FakeRepository>(new FakeRepository(&e, RepositoryName("bar-overlay"))));
- p.add_repository(1, tr1::shared_ptr<FakeRepository>(new FakeRepository(&e, RepositoryName("baz-overlay"))));
- p.add_repository(1, tr1::shared_ptr<FakeRepository>(new FakeRepository(&e, RepositoryName("sunrise"))));
+ p.add_repository(1, std::tr1::shared_ptr<FakeRepository>(new FakeRepository(&e, RepositoryName("my-main-repository"))));
+ p.add_repository(1, std::tr1::shared_ptr<FakeRepository>(new FakeRepository(&e, RepositoryName("x-new-repository"))));
+ p.add_repository(1, std::tr1::shared_ptr<FakeRepository>(new FakeRepository(&e, RepositoryName("bar-overlay"))));
+ p.add_repository(1, std::tr1::shared_ptr<FakeRepository>(new FakeRepository(&e, RepositoryName("baz-overlay"))));
+ p.add_repository(1, std::tr1::shared_ptr<FakeRepository>(new FakeRepository(&e, RepositoryName("sunrise"))));
FuzzyRepositoriesFinder f1(e, "my-main-respository");
TEST_CHECK_EQUAL(std::distance(f1.begin(), f1.end()), 1);
diff --git a/paludis/handled_information.cc b/paludis/handled_information.cc
index b3767ba..e62795f 100644
--- a/paludis/handled_information.cc
+++ b/paludis/handled_information.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007 Ciaran McCreesh
+ * Copyright (c) 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -62,16 +62,16 @@ namespace paludis
template <>
struct Implementation<DepListEntryHandledSkippedDependent>
{
- const tr1::shared_ptr<const PackageID> id;
+ const std::tr1::shared_ptr<const PackageID> id;
- Implementation(const tr1::shared_ptr<const PackageID> & i) :
+ Implementation(const std::tr1::shared_ptr<const PackageID> & i) :
id(i)
{
}
};
}
-DepListEntryHandledSkippedDependent::DepListEntryHandledSkippedDependent(const tr1::shared_ptr<const PackageID> & i) :
+DepListEntryHandledSkippedDependent::DepListEntryHandledSkippedDependent(const std::tr1::shared_ptr<const PackageID> & i) :
PrivateImplementationPattern<DepListEntryHandledSkippedDependent>(new Implementation<DepListEntryHandledSkippedDependent>(i))
{
}
@@ -80,7 +80,7 @@ DepListEntryHandledSkippedDependent::~DepListEntryHandledSkippedDependent()
{
}
-const tr1::shared_ptr<const PackageID>
+const std::tr1::shared_ptr<const PackageID>
DepListEntryHandledSkippedDependent::id() const
{
return _imp->id;
diff --git a/paludis/handled_information.hh b/paludis/handled_information.hh
index a55c912..986c16b 100644
--- a/paludis/handled_information.hh
+++ b/paludis/handled_information.hh
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007 Ciaran McCreesh
+ * Copyright (c) 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -160,7 +160,7 @@ namespace paludis
///\name Basic operations
///\{
- DepListEntryHandledSkippedDependent(const tr1::shared_ptr<const PackageID> &);
+ DepListEntryHandledSkippedDependent(const std::tr1::shared_ptr<const PackageID> &);
~DepListEntryHandledSkippedDependent();
///\}
@@ -169,7 +169,7 @@ namespace paludis
* Upon which PackageID are we dependent? If multiple dependent IDs are
* unsatisfied, returns one of them.
*/
- const tr1::shared_ptr<const PackageID> id() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ const std::tr1::shared_ptr<const PackageID> id() const PALUDIS_ATTRIBUTE((warn_unused_result));
};
/**
diff --git a/paludis/hashed_containers.cc b/paludis/hashed_containers.cc
deleted file mode 100644
index a7f96de..0000000
--- a/paludis/hashed_containers.cc
+++ /dev/null
@@ -1,128 +0,0 @@
-/* vim: set sw=4 sts=4 et foldmethod=syntax : */
-
-/*
- * Copyright (c) 2006, 2007 Ciaran McCreesh
- *
- * This file is part of the Paludis package manager. Paludis is free software;
- * you can redistribute it and/or modify it under the terms of the GNU General
- * Public License version 2, as published by the Free Software Foundation.
- *
- * Paludis is distributed in the hope that it will be useful, but WITHOUT ANY
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
- * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
- * details.
- *
- * You should have received a copy of the GNU General Public License along with
- * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
- * Place, Suite 330, Boston, MA 02111-1307 USA
- */
-
-#include <paludis/hashed_containers.hh>
-#include <paludis/name.hh>
-#include <paludis/version_spec.hh>
-#include <paludis/package_id.hh>
-#include <paludis/repository.hh>
-
-using namespace paludis;
-
-#if defined(PALUDIS_HASH_IS_STD_TR1_UNORDERED) || defined(PALUDIS_HASH_IS_GNU_CXX_HASH) || defined(PALUDIS_HASH_IS_STD_HASH)
-
-std::size_t
-CRCHash<QualifiedPackageName>::operator() (const QualifiedPackageName & val) const
-{
- const std::string & s1(val.category.data()), s2(val.package.data());
- std::size_t h(0);
-
- for (std::string::size_type t(0) ; t < s1.length() ; ++t)
- {
- std::size_t hh(h & h_mask);
- h <<= 5;
- h ^= (hh >> h_shift);
- h ^= s1[t];
- }
-
- for (std::string::size_type t(0) ; t < s2.length() ; ++t)
- {
- std::size_t hh(h & h_mask);
- h <<= 5;
- h ^= (hh >> h_shift);
- h ^= s2[t];
- }
-
- return h;
-}
-
-std::size_t
-CRCHash<std::string>::operator() (const std::string & val) const
-{
- std::size_t h(0);
-
- for (std::string::size_type t(0) ; t < val.length() ; ++t)
- {
- std::size_t hh(h & h_mask);
- h <<= 5;
- h ^= (hh >> h_shift);
- h ^= val[t];
- }
-
- return h;
-}
-
-std::size_t
-CRCHash<std::pair<QualifiedPackageName, VersionSpec> >::operator() (
- const std::pair<QualifiedPackageName, VersionSpec> & val) const
-{
- const std::string & s1(val.first.category.data()),
- s2(val.first.package.data());
-
- std::size_t h(0);
-
- for (std::string::size_type t(0) ; t < s1.length() ; ++t)
- {
- std::size_t hh(h & h_mask);
- h <<= 5;
- h ^= (hh >> h_shift);
- h ^= s1[t];
- }
-
- for (std::string::size_type t(0) ; t < s2.length() ; ++t)
- {
- std::size_t hh(h & h_mask);
- h <<= 5;
- h ^= (hh >> h_shift);
- h ^= s2[t];
- }
-
- h ^= val.second.hash_value();
-
- return h;
-}
-
-std::size_t
-CRCHash<std::pair<dev_t, ino_t> >::operator() (
- const std::pair<dev_t, ino_t> & val) const
-{
- return val.first ^ val.second;
-}
-
-std::size_t
-CRCHash<PackageID>::operator() (const PackageID & val) const
-{
- return
- CRCHash<QualifiedPackageName>()(val.name()) ^
- (val.version().hash_value() << 5) ^
- (CRCHash<RepositoryName>()(val.repository()->name()) << 9) ^
- (val.extra_hash_value() << 13);
-}
-
-#if (! defined(PALUDIS_HASH_IS_STD_TR1_UNORDERED)) && (! defined(PALUDIS_HASH_IS_GNU_CXX_HASH))
-
-bool
-CRCHash<PackageID, PackageID>::operator() (const PackageID & i1, const PackageID & i2) const
-{
- return PackageIDSetComparator()(i1, i2);
-}
-
-#endif
-#endif
-
diff --git a/paludis/hashed_containers.hh b/paludis/hashed_containers.hh
deleted file mode 100644
index 22e697a..0000000
--- a/paludis/hashed_containers.hh
+++ /dev/null
@@ -1,423 +0,0 @@
-/* vim: set sw=4 sts=4 et foldmethod=syntax : */
-
-/*
- * Copyright (c) 2006, 2007, 2008 Ciaran McCreesh
- *
- * This file is part of the Paludis package manager. Paludis is free software;
- * you can redistribute it and/or modify it under the terms of the GNU General
- * Public License version 2, as published by the Free Software Foundation.
- *
- * Paludis is distributed in the hope that it will be useful, but WITHOUT ANY
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
- * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
- * details.
- *
- * You should have received a copy of the GNU General Public License along with
- * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
- * Place, Suite 330, Boston, MA 02111-1307 USA
- */
-
-#ifndef PALUDIS_GUARD_PALUDIS_HASHED_CONTAINERS_HH
-#define PALUDIS_GUARD_PALUDIS_HASHED_CONTAINERS_HH 1
-
-/** \file
- * Declarations for various hashed container things.
- *
- * These are more complicated than they should be for two reasons:
- *
- * - There is no standard hashed container in C++. There is one in TR1, but not
- * all compilers support TR1 yet. Most pre-TR1 standard library
- * implementations do include hashed containers, but with various different
- * class names and in different header files. For performance reasons, we need
- * hashed containers if at all possible.
- *
- * - The current C++ standard doesn't have template typedefs.
- *
- * \ingroup g_data_structures
- *
- * \section Examples
- *
- * - None at this time.
- */
-
-#include <paludis/util/validated.hh>
-#include <paludis/util/tr1_type_traits.hh>
-#include <paludis/name-fwd.hh>
-#include <paludis/version_spec-fwd.hh>
-#include <paludis/package_id-fwd.hh>
-
-#ifdef PALUDIS_HASH_IS_STD_TR1_UNORDERED
-# include <tr1/unordered_set>
-# include <tr1/unordered_map>
-#elif defined(PALUDIS_HASH_IS_GNU_CXX_HASH)
-# include <ext/hash_set>
-# include <ext/hash_map>
-#elif defined(PALUDIS_HASH_IS_STD_HASH)
-# include <hash_set>
-# include <hash_map>
-#else
-# include <set>
-# include <map>
-#endif
-
-#include <limits>
-#include <string>
-#include <functional>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <unistd.h>
-
-namespace paludis
-{
- /**
- * Hash function base template.
- *
- * \ingroup g_data_structures
- */
- template <typename T_>
- struct CRCHash;
-
- /**
- * Make a hashed map of some kind from Key_ to Value_.
- *
- * \ingroup g_data_structures
- */
- template <typename Key_, typename Value_>
- struct MakeHashedMap
- {
-#ifdef PALUDIS_HASH_IS_STD_TR1_UNORDERED
- /// Our map type.
- typedef std::tr1::unordered_map<Key_, Value_, CRCHash<Key_> > Type;
-
-#elif defined(PALUDIS_HASH_IS_GNU_CXX_HASH)
- /// Our map type.
- typedef __gnu_cxx::hash_map<Key_, Value_, CRCHash<Key_> > Type;
-
-#elif defined(PALUDIS_HASH_IS_STD_HASH)
- /// Our map type.
- typedef std::hash_map<Key_, Value_, CRCHash<Key_> > Type;
-
-#else
- /// Our map type.
- typedef std::map<Key_, Value_> Type;
-#endif
- };
-
- /**
- * Make a hashed map of some kind from Key_ to Value_.
- *
- * \ingroup g_data_structures
- */
- template <typename Key_, typename Value_>
- struct MakeHashedMultiMap
- {
-#ifdef PALUDIS_HASH_IS_STD_TR1_UNORDERED
- /// Our map type.
- typedef std::tr1::unordered_multimap<Key_, Value_, CRCHash<Key_> > Type;
-
-#elif defined(PALUDIS_HASH_IS_GNU_CXX_HASH)
- /// Our map type.
- typedef __gnu_cxx::hash_multimap<Key_, Value_, CRCHash<Key_> > Type;
-
-#elif defined(PALUDIS_HASH_IS_STD_HASH)
- /// Our map type.
- typedef std::hash_multimap<Key_, Value_, CRCHash<Key_> > Type;
-
-#else
- /// Our map type.
- typedef std::multimap<Key_, Value_> Type;
-#endif
- };
-
- /**
- * Make a hashed set of some kind of Key_.
- *
- * \ingroup g_data_structures
- */
- template <typename Key_>
- struct MakeHashedSet
- {
-#ifdef PALUDIS_HASH_IS_STD_TR1_UNORDERED
- /// Our set type.
- typedef std::tr1::unordered_set<Key_, CRCHash<Key_> > Type;
-
-#elif defined(PALUDIS_HASH_IS_GNU_CXX_HASH)
- /// Our set type.
- typedef __gnu_cxx::hash_set<Key_, CRCHash<Key_> > Type;
-
-#elif defined(PALUDIS_HASH_IS_STD_HASH)
- /// Our set type.
- typedef std::hash_set<Key_, CRCHash<Key_> > Type;
-
-#else
- /// Our set type.
- typedef std::set<Key_> Type;
-#endif
- };
-
- /**
- * Make a hashed set of some kind of Key_.
- *
- * \ingroup g_data_structures
- */
- template <typename Key_>
- struct MakeHashedMultiSet
- {
-#ifdef PALUDIS_HASH_IS_STD_TR1_UNORDERED
- /// Our set type.
- typedef std::tr1::unordered_multiset<Key_, CRCHash<Key_> > Type;
-
-#elif defined(PALUDIS_HASH_IS_GNU_CXX_HASH)
- /// Our set type.
- typedef __gnu_cxx::hash_multiset<Key_, CRCHash<Key_> > Type;
-
-#elif defined(PALUDIS_HASH_IS_STD_HASH)
- /// Our set type.
- typedef std::hash_multiset<Key_, CRCHash<Key_> > Type;
-
-#else
- /// Our set type.
- typedef std::multiset<Key_> Type;
-#endif
- };
-
-#if defined(PALUDIS_HASH_IS_STD_TR1_UNORDERED) || defined(PALUDIS_HASH_IS_GNU_CXX_HASH) || defined(PALUDIS_HASH_IS_STD_HASH)
- namespace hashed_containers_internals
- {
- /**
- * Base definitions for our CRCHash.
- *
- * \ingroup g_data_structures
- */
- struct CRCHashBase
- {
- /// Shift value.
- static const std::size_t h_shift = std::numeric_limits<std::size_t>::digits - 5;
-
- /// Mask value.
- static const std::size_t h_mask = static_cast<std::size_t>(0x1f) << h_shift;
- };
- }
-
- /**
- * Hash, for QualifiedPackageName.
- *
- * \ingroup g_data_structures
- */
- template <>
- class PALUDIS_VISIBLE CRCHash<QualifiedPackageName> :
- public std::unary_function<const QualifiedPackageName, std::size_t>,
- protected hashed_containers_internals::CRCHashBase
- {
- public:
- /// Hash function.
- std::size_t operator() (const QualifiedPackageName & val) const;
-
-#if (! defined(PALUDIS_HASH_IS_STD_TR1_UNORDERED)) && (! defined(PALUDIS_HASH_IS_GNU_CXX_HASH))
- enum
- {
- min_buckets = 32,
- bucket_size = 4
- };
-
- bool operator() (const QualifiedPackageName & i1, const QualifiedPackageName & i2) const
- {
- return i1 < i2;
- }
-#endif
- };
-
- /**
- * Hash, for PackageID.
- *
- * \ingroup g_data_structures
- */
- template <>
- class PALUDIS_VISIBLE CRCHash<PackageID> :
- public std::unary_function<const PackageID, std::size_t>,
- protected hashed_containers_internals::CRCHashBase
- {
- public:
- /// Hash function.
- std::size_t operator() (const PackageID & val) const;
-
-#if (! defined(PALUDIS_HASH_IS_STD_TR1_UNORDERED)) && (! defined(PALUDIS_HASH_IS_GNU_CXX_HASH))
- enum
- {
- min_buckets = 32,
- bucket_size = 4
- };
-
- bool operator() (const PackageID & i1, const PackageID & i2) const;
-#endif
- };
-
- /**
- * Hash, for a validated string type.
- *
- * \ingroup g_data_structures
- */
- template <typename Validated_, bool b_>
- class CRCHash<Validated<std::string, Validated_, b_> > :
- public std::unary_function<const Validated<std::string, Validated_, b_>, std::size_t>,
- protected hashed_containers_internals::CRCHashBase
- {
- public:
- /// Hash function.
- std::size_t operator() (const Validated<std::string, Validated_, b_> & val) const;
-
-#if (! defined(PALUDIS_HASH_IS_STD_TR1_UNORDERED)) && (! defined(PALUDIS_HASH_IS_GNU_CXX_HASH))
- enum
- {
- min_buckets = 32,
- bucket_size = 4
- };
-
- bool operator() (const Validated<std::string, Validated_, b_> i1,
- const Validated<std::string, Validated_> & i2, b_) const
- {
- return i1.data() < i2.data();
- }
-#endif
- };
-
-
- /**
- * Hash, for a string.
- *
- * \ingroup g_data_structures
- */
- template<>
- class PALUDIS_VISIBLE CRCHash<std::string> :
- public std::unary_function<const std::string, std::size_t>,
- protected hashed_containers_internals::CRCHashBase
- {
- public:
- /// Hash function.
- std::size_t operator() (const std::string & val) const;
-
-#if (! defined(PALUDIS_HASH_IS_STD_TR1_UNORDERED)) && (! defined(PALUDIS_HASH_IS_GNU_CXX_HASH))
- enum
- {
- min_buckets = 32,
- bucket_size = 4
- };
-
- bool operator() (const std::string & i1, const std::string & i2) const
- {
- return i1 < i2;
- }
-#endif
- };
-
- /**
- * Hash, for a QualifiedPackageName + VersionSpec pair.
- *
- * \ingroup g_data_structures
- */
- template <>
- class PALUDIS_VISIBLE CRCHash<std::pair<QualifiedPackageName, VersionSpec> > :
- public std::unary_function<const std::pair<const QualifiedPackageName, VersionSpec>, std::size_t>,
- protected hashed_containers_internals::CRCHashBase
- {
- public:
- /// Hash function.
- std::size_t operator() (const std::pair<QualifiedPackageName, VersionSpec> & val) const;
-
-#if (! defined(PALUDIS_HASH_IS_STD_TR1_UNORDERED)) && (! defined(PALUDIS_HASH_IS_GNU_CXX_HASH))
- enum
- {
- min_buckets = 32,
- bucket_size = 4
- };
-
- bool operator() (const std::pair<QualifiedPackageName, VersionSpec> & i1,
- const std::pair<QualifiedPackageName, VersionSpec> & i2) const
- {
- return i1 < i2;
- }
-#endif
- };
-
- /**
- * Hash, for a dev_t + ino_t pair.
- *
- * \ingroup g_data_structures
- */
- template <>
- class PALUDIS_VISIBLE CRCHash<std::pair<dev_t, ino_t> > :
- public std::unary_function<const std::pair<dev_t, ino_t>, std::size_t>,
- protected hashed_containers_internals::CRCHashBase
- {
- public:
- /// Hash function
- std::size_t operator() (const std::pair<dev_t, ino_t> & val) const;
-
-#if (! defined(PALUDIS_HASH_IS_STD_TR1_UNORDERED)) && (! defined(PALUDIS_HASH_IS_GNU_CXX_HASH))
- enum
- {
- min_buckets = 32,
- bucket_size = 4
- };
-
- bool operator() (const std::pair<dev_t, ino_t> & i1, const std::pair<dev_t, ino_t> & i2) const
- {
- return i1 < i2;
- }
-#endif
- };
-
- /**
- * Hash, for a shared pointer.
- *
- * \ingroup g_data_structures
- */
- template <typename T_>
- class PALUDIS_VISIBLE CRCHash<tr1::shared_ptr<T_> > :
- public std::unary_function<tr1::shared_ptr<T_>, std::size_t>,
- protected hashed_containers_internals::CRCHashBase
- {
- public:
- /// Hash function.
- std::size_t operator() (const tr1::shared_ptr<T_> & val) const
- {
- return CRCHash<typename tr1::remove_const<T_>::type>()(*val);
- }
-
-#if (! defined(PALUDIS_HASH_IS_STD_TR1_UNORDERED)) && (! defined(PALUDIS_HASH_IS_GNU_CXX_HASH))
- enum
- {
- min_buckets = 32,
- bucket_size = 4
- };
-
- bool operator() (const tr1::shared_ptr<T_> & i1, const tr1::shared_ptr<T_> & i2) const
- {
- return CRCHash<typename tr1::remove_const<T_>::type>()(*i1, *i2);
- }
-#endif
- };
-
- template <typename Validated_, bool b_>
- std::size_t
- CRCHash<Validated<std::string, Validated_, b_> >::operator() (const Validated<std::string, Validated_, b_> & val) const
- {
- const std::string & s1(val.data());
- std::size_t h(0);
-
- for (std::string::size_type t(0) ; t < s1.length() ; ++t)
- {
- std::size_t hh(h & h_mask);
- h <<= 5;
- h ^= (hh >> h_shift);
- h ^= s1[t];
- }
-
- return h;
- }
-
-#endif
-
-}
-
-#endif
diff --git a/paludis/hashed_containers_TEST.cc b/paludis/hashed_containers_TEST.cc
deleted file mode 100644
index d09b443..0000000
--- a/paludis/hashed_containers_TEST.cc
+++ /dev/null
@@ -1,63 +0,0 @@
-/* vim: set sw=4 sts=4 et foldmethod=syntax : */
-
-/*
- * Copyright (c) 2006, 2007 Ciaran McCreesh
- *
- * This file is part of the Paludis package manager. Paludis is free software;
- * you can redistribute it and/or modify it under the terms of the GNU General
- * Public License version 2, as published by the Free Software Foundation.
- *
- * Paludis is distributed in the hope that it will be useful, but WITHOUT ANY
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
- * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
- * details.
- *
- * You should have received a copy of the GNU General Public License along with
- * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
- * Place, Suite 330, Boston, MA 02111-1307 USA
- */
-
-#include "hashed_containers.hh"
-#include <test/test_framework.hh>
-#include <test/test_runner.hh>
-#include <paludis/name.hh>
-
-using namespace paludis;
-using namespace test;
-
-namespace test_cases
-{
- /**
- * \test Test CRCHash
- */
- struct CRCHashTest : TestCase
- {
- CRCHashTest() : TestCase("crc hash") { }
-
- void run()
- {
- TEST_CHECK_EQUAL(std::size_t(47503), (CRCHash<std::string>()("moo") & 0xffff));
- }
- } test_crc_hash;
-
- /**
- * \test Test HashSet.
- *
- */
- struct HashSetTestQPN : TestCase
- {
- HashSetTestQPN() : TestCase("hash set qpn") { }
-
- void run()
- {
- MakeHashedSet<QualifiedPackageName>::Type s;
- TEST_CHECK(s.empty());
- TEST_CHECK(s.end() == s.find(QualifiedPackageName("foo/bar")));
- TEST_CHECK(s.insert(QualifiedPackageName("foo/bar")).second);
- TEST_CHECK(s.end() != s.find(QualifiedPackageName("foo/bar")));
- TEST_CHECK(! s.empty());
- TEST_CHECK(! s.insert(QualifiedPackageName("foo/bar")).second);
- }
- } test_hash_set_qpn;
-}
-
diff --git a/paludis/hook.hh b/paludis/hook.hh
index 365dc77..f09a4b1 100644
--- a/paludis/hook.hh
+++ b/paludis/hook.hh
@@ -28,9 +28,8 @@
#include <paludis/util/private_implementation_pattern.hh>
#include <paludis/util/operators.hh>
#include <paludis/util/wrapped_forward_iterator-fwd.hh>
-#include <paludis/util/tr1_memory.hh>
#include <paludis/util/sequence-fwd.hh>
-
+#include <tr1/memory>
#include <string>
/** \file
@@ -142,7 +141,7 @@ extern "C" paludis::HookResult PALUDIS_VISIBLE paludis_hook_run(
extern "C" void PALUDIS_VISIBLE paludis_hook_add_dependencies(
const paludis::Environment *, const paludis::Hook &, paludis::DirectedGraph<std::string, int> &);
-extern "C" const paludis::tr1::shared_ptr<const paludis::Sequence<std::string> > PALUDIS_VISIBLE paludis_hook_auto_phases(
+extern "C" const std::tr1::shared_ptr<const paludis::Sequence<std::string> > PALUDIS_VISIBLE paludis_hook_auto_phases(
const paludis::Environment *);
#endif
diff --git a/paludis/hooker.cc b/paludis/hooker.cc
index 28bf9e9..e63d3a6 100644
--- a/paludis/hooker.cc
+++ b/paludis/hooker.cc
@@ -22,7 +22,6 @@
#include "config.h"
#include <paludis/environment.hh>
#include <paludis/hook.hh>
-#include <paludis/hashed_containers.hh>
#include <paludis/package_database.hh>
#include <paludis/util/log.hh>
#include <paludis/util/dir_iterator.hh>
@@ -44,7 +43,7 @@
using namespace paludis;
-template class Sequence<tr1::shared_ptr<HookFile> >;
+template class Sequence<std::tr1::shared_ptr<HookFile> >;
HookFile::~HookFile()
{
@@ -81,7 +80,7 @@ namespace
{
}
- virtual const tr1::shared_ptr<const Sequence<std::string> > auto_hook_names() const
+ virtual const std::tr1::shared_ptr<const Sequence<std::string> > auto_hook_names() const
{
return make_shared_ptr(new Sequence<std::string>);
}
@@ -114,7 +113,7 @@ namespace
virtual void add_dependencies(const Hook &, DirectedGraph<std::string, int> &);
- virtual const tr1::shared_ptr<const Sequence<std::string> > auto_hook_names() const;
+ virtual const std::tr1::shared_ptr<const Sequence<std::string> > auto_hook_names() const;
};
class SoHookFile :
@@ -127,7 +126,7 @@ namespace
void * _dl;
HookResult (*_run)(const Environment *, const Hook &);
void (*_add_dependencies)(const Environment *, const Hook &, DirectedGraph<std::string, int> &);
- const tr1::shared_ptr<const Sequence<std::string > > (*_auto_hook_names)(const Environment *);
+ const std::tr1::shared_ptr<const Sequence<std::string > > (*_auto_hook_names)(const Environment *);
public:
SoHookFile(const FSEntry &, const bool, const Environment * const);
@@ -141,7 +140,7 @@ namespace
virtual void add_dependencies(const Hook &, DirectedGraph<std::string, int> &);
- virtual const tr1::shared_ptr<const Sequence<std::string> > auto_hook_names() const;
+ virtual const std::tr1::shared_ptr<const Sequence<std::string> > auto_hook_names() const;
};
}
@@ -245,7 +244,7 @@ FancyHookFile::run(const Hook & hook) const
return HookResult(exit_status, output);
}
-const tr1::shared_ptr<const Sequence<std::string > >
+const std::tr1::shared_ptr<const Sequence<std::string > >
FancyHookFile::auto_hook_names() const
{
Context c("When querying auto hook names for fancy hook '" + stringify(file_name()) + "':");
@@ -276,7 +275,7 @@ FancyHookFile::auto_hook_names() const
if (0 == exit_status)
{
- tr1::shared_ptr<Sequence<std::string> > result(new Sequence<std::string>);
+ std::tr1::shared_ptr<Sequence<std::string> > result(new Sequence<std::string>);
tokenise_whitespace(output, result->back_inserter());
Log::get_instance()->message("hook.fancy.success", ll_debug, lc_no_context) << "Hook '" << file_name()
<< "' returned success '" << exit_status << "' for auto hook names, result ("
@@ -386,7 +385,7 @@ SoHookFile::SoHookFile(const FSEntry & f, const bool, const Environment * const
const Environment *, const Hook &, DirectedGraph<std::string, int> &)>(
reinterpret_cast<uintptr_t>(dlsym(_dl, "paludis_hook_add_dependencies")));
- _auto_hook_names = reinterpret_cast<const tr1::shared_ptr<const Sequence<std::string> > (*)(
+ _auto_hook_names = reinterpret_cast<const std::tr1::shared_ptr<const Sequence<std::string> > (*)(
const Environment *)>(
reinterpret_cast<uintptr_t>(dlsym(_dl, "paludis_hook_auto_phases")));
}
@@ -416,7 +415,7 @@ SoHookFile::add_dependencies(const Hook & hook, DirectedGraph<std::string, int>
_add_dependencies(_env, hook, g);
}
-const tr1::shared_ptr<const Sequence<std::string > >
+const std::tr1::shared_ptr<const Sequence<std::string > >
SoHookFile::auto_hook_names() const
{
Context c("When querying auto hook names for .so hook '" + stringify(file_name()) + "':");
@@ -436,8 +435,8 @@ namespace paludis
std::list<std::pair<FSEntry, bool> > dirs;
mutable Mutex hook_files_mutex;
- mutable std::map<std::string, tr1::shared_ptr<Sequence<tr1::shared_ptr<HookFile> > > > hook_files;
- mutable std::map<std::string, std::map<std::string, tr1::shared_ptr<HookFile> > > auto_hook_files;
+ mutable std::map<std::string, std::tr1::shared_ptr<Sequence<std::tr1::shared_ptr<HookFile> > > > hook_files;
+ mutable std::map<std::string, std::map<std::string, std::tr1::shared_ptr<HookFile> > > auto_hook_files;
mutable bool has_auto_hook_files;
Implementation(const Environment * const e) :
@@ -465,7 +464,7 @@ namespace paludis
for (DirIterator e(d_a), e_end ; e != e_end ; ++e)
{
- tr1::shared_ptr<HookFile> hook_file;
+ std::tr1::shared_ptr<HookFile> hook_file;
std::string name;
if (is_file_with_extension(*e, ".hook", IsFileWithOptions()))
@@ -482,7 +481,7 @@ namespace paludis
if (! hook_file)
continue;
- const tr1::shared_ptr<const Sequence<std::string> > names(hook_file->auto_hook_names());
+ const std::tr1::shared_ptr<const Sequence<std::string> > names(hook_file->auto_hook_names());
for (Sequence<std::string>::ConstIterator n(names->begin()), n_end(names->end()) ;
n != n_end ; ++n)
{
@@ -521,7 +520,7 @@ namespace
{
Mutex mutex;
void * handle;
- tr1::shared_ptr<HookFile> (* create_py_hook_file_handle)(const FSEntry &,
+ std::tr1::shared_ptr<HookFile> (* create_py_hook_file_handle)(const FSEntry &,
const bool, const Environment * const);
@@ -540,14 +539,14 @@ namespace
} pyhookfilehandle;
}
-tr1::shared_ptr<Sequence<tr1::shared_ptr<HookFile> > >
+std::tr1::shared_ptr<Sequence<std::tr1::shared_ptr<HookFile> > >
Hooker::_find_hooks(const Hook & hook) const
{
- std::map<std::string, tr1::shared_ptr<HookFile> > hook_files;
+ std::map<std::string, std::tr1::shared_ptr<HookFile> > hook_files;
{
_imp->need_auto_hook_files();
- std::map<std::string, std::map<std::string, tr1::shared_ptr<HookFile> > >::const_iterator h(
+ std::map<std::string, std::map<std::string, std::tr1::shared_ptr<HookFile> > >::const_iterator h(
_imp->auto_hook_files.find(hook.name()));
if (_imp->auto_hook_files.end() != h)
hook_files = h->second;
@@ -564,21 +563,21 @@ Hooker::_find_hooks(const Hook & hook) const
{
if (is_file_with_extension(*e, ".bash", IsFileWithOptions()))
if (! hook_files.insert(std::make_pair(strip_trailing_string(e->basename(), ".bash"),
- tr1::shared_ptr<HookFile>(new BashHookFile(*e, d->second, _imp->env)))).second)
+ std::tr1::shared_ptr<HookFile>(new BashHookFile(*e, d->second, _imp->env)))).second)
Log::get_instance()->message("hook.discarding", ll_warning, lc_context) << "Discarding hook file '" << *e
<< "' because of naming conflict with '" <<
hook_files.find(stringify(strip_trailing_string(e->basename(), ".bash")))->second->file_name() << "'";
if (is_file_with_extension(*e, ".hook", IsFileWithOptions()))
if (! hook_files.insert(std::make_pair(strip_trailing_string(e->basename(), ".hook"),
- tr1::shared_ptr<HookFile>(new FancyHookFile(*e, d->second, _imp->env)))).second)
+ std::tr1::shared_ptr<HookFile>(new FancyHookFile(*e, d->second, _imp->env)))).second)
Log::get_instance()->message("hook.discarding", ll_warning, lc_context) << "Discarding hook file '" << *e
<< "' because of naming conflict with '" <<
hook_files.find(stringify(strip_trailing_string(e->basename(), ".hook")))->second->file_name() << "'";
if (is_file_with_extension(*e, so_suffix, IsFileWithOptions()))
if (! hook_files.insert(std::make_pair(strip_trailing_string(e->basename(), so_suffix),
- tr1::shared_ptr<HookFile>(new SoHookFile(*e, d->second, _imp->env)))).second)
+ std::tr1::shared_ptr<HookFile>(new SoHookFile(*e, d->second, _imp->env)))).second)
Log::get_instance()->message("hook.discarding", ll_warning, lc_context) << "Discarding hook file '" << *e
<< "' because of naming conflict with '" <<
hook_files.find(stringify(strip_trailing_string(e->basename(), so_suffix)))->second->file_name() << "'";
@@ -600,7 +599,7 @@ Hooker::_find_hooks(const Hook & hook) const
if (pyhookfilehandle.handle)
{
pyhookfilehandle.create_py_hook_file_handle =
- reinterpret_cast<tr1::shared_ptr<HookFile> (*)(
+ reinterpret_cast<std::tr1::shared_ptr<HookFile> (*)(
const FSEntry &, const bool, const Environment * const)>(
reinterpret_cast<uintptr_t>(dlsym(
pyhookfilehandle.handle, "create_py_hook_file")));
@@ -625,7 +624,7 @@ Hooker::_find_hooks(const Hook & hook) const
if (load_ok)
{
if (! hook_files.insert(std::make_pair(strip_trailing_string(e->basename(), ".py"),
- tr1::shared_ptr<HookFile>(pyhookfilehandle.create_py_hook_file_handle(
+ std::tr1::shared_ptr<HookFile>(pyhookfilehandle.create_py_hook_file_handle(
*e, d->second, _imp->env)))).second)
Log::get_instance()->message("hook.discarding", ll_warning, lc_context) <<
"Discarding hook file '" << *e
@@ -653,11 +652,11 @@ Hooker::_find_hooks(const Hook & hook) const
DirectedGraph<std::string, int> hook_deps;
{
Context context_local("When determining hook dependencies for '" + hook.name() + "':");
- for (std::map<std::string, tr1::shared_ptr<HookFile> >::const_iterator f(hook_files.begin()), f_end(hook_files.end()) ;
+ for (std::map<std::string, std::tr1::shared_ptr<HookFile> >::const_iterator f(hook_files.begin()), f_end(hook_files.end()) ;
f != f_end ; ++f)
hook_deps.add_node(f->first);
- for (std::map<std::string, tr1::shared_ptr<HookFile> >::const_iterator f(hook_files.begin()), f_end(hook_files.end()) ;
+ for (std::map<std::string, std::tr1::shared_ptr<HookFile> >::const_iterator f(hook_files.begin()), f_end(hook_files.end()) ;
f != f_end ; ++f)
f->second->add_dependencies(hook, hook_deps);
}
@@ -678,7 +677,7 @@ Hooker::_find_hooks(const Hook & hook) const
}
}
- tr1::shared_ptr<Sequence<tr1::shared_ptr<HookFile> > > result(new Sequence<tr1::shared_ptr<HookFile> >);
+ std::tr1::shared_ptr<Sequence<std::tr1::shared_ptr<HookFile> > > result(new Sequence<std::tr1::shared_ptr<HookFile> >);
for (std::list<std::string>::const_iterator o(ordered.begin()), o_end(ordered.end()) ;
o != o_end ; ++o)
result->push_back(hook_files.find(*o)->second);
@@ -740,7 +739,7 @@ Hooker::perform_hook(const Hook & hook) const
/* file hooks, but only if necessary */
Lock l(_imp->hook_files_mutex);
- std::map<std::string, tr1::shared_ptr<Sequence<tr1::shared_ptr<HookFile> > > >::iterator h(_imp->hook_files.find(hook.name()));
+ std::map<std::string, std::tr1::shared_ptr<Sequence<std::tr1::shared_ptr<HookFile> > > >::iterator h(_imp->hook_files.find(hook.name()));
if (h == _imp->hook_files.end())
h = _imp->hook_files.insert(std::make_pair(hook.name(), _find_hooks(hook))).first;
@@ -752,7 +751,7 @@ Hooker::perform_hook(const Hook & hook) const
switch (hook.output_dest)
{
case hod_stdout:
- for (Sequence<tr1::shared_ptr<HookFile> >::ConstIterator f(h->second->begin()),
+ for (Sequence<std::tr1::shared_ptr<HookFile> >::ConstIterator f(h->second->begin()),
f_end(h->second->end()) ; f != f_end ; ++f)
if ((*f)->file_name().is_regular_file_or_symlink_to_regular_file())
result.max_exit_status = std::max(result.max_exit_status, (*f)->run(hook).max_exit_status);
@@ -762,7 +761,7 @@ Hooker::perform_hook(const Hook & hook) const
continue;
case hod_grab:
- for (Sequence<tr1::shared_ptr<HookFile> >::ConstIterator f(h->second->begin()),
+ for (Sequence<std::tr1::shared_ptr<HookFile> >::ConstIterator f(h->second->begin()),
f_end(h->second->end()) ; f != f_end ; ++f)
{
if (! (*f)->file_name().is_regular_file_or_symlink_to_regular_file())
diff --git a/paludis/hooker.hh b/paludis/hooker.hh
index 06e9111..b72fdbc 100644
--- a/paludis/hooker.hh
+++ b/paludis/hooker.hh
@@ -24,7 +24,7 @@
#include <paludis/util/private_implementation_pattern.hh>
#include <paludis/util/graph-fwd.hh>
#include <paludis/util/sequence-fwd.hh>
-#include <paludis/util/tr1_memory.hh>
+#include <tr1/memory>
#include <string>
/** \file
@@ -64,7 +64,7 @@ namespace paludis
virtual HookResult run(const Hook &) const PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
virtual const FSEntry file_name() const = 0;
virtual void add_dependencies(const Hook &, DirectedGraph<std::string, int> &) = 0;
- virtual const tr1::shared_ptr<const Sequence<std::string> > auto_hook_names() const = 0;
+ virtual const std::tr1::shared_ptr<const Sequence<std::string> > auto_hook_names() const = 0;
};
/**
@@ -78,7 +78,7 @@ namespace paludis
private InstantiationPolicy<Hooker, instantiation_method::NonCopyableTag>
{
private:
- tr1::shared_ptr<Sequence<tr1::shared_ptr<HookFile> > > _find_hooks(const Hook &) const;
+ std::tr1::shared_ptr<Sequence<std::tr1::shared_ptr<HookFile> > > _find_hooks(const Hook &) const;
public:
///\name Basic operations
diff --git a/paludis/install_task.cc b/paludis/install_task.cc
index 5e27d2b..8dfa0f8 100644
--- a/paludis/install_task.cc
+++ b/paludis/install_task.cc
@@ -24,7 +24,6 @@
#include <paludis/metadata_key.hh>
#include <paludis/util/exception.hh>
#include <paludis/util/private_implementation_pattern-impl.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/query.hh>
#include <paludis/hook.hh>
#include <paludis/repository.hh>
@@ -41,10 +40,10 @@
#include <paludis/util/wrapped_forward_iterator-impl.hh>
#include <paludis/util/make_shared_ptr.hh>
#include <paludis/util/kc.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/destringify.hh>
#include <paludis/util/make_shared_ptr.hh>
#include <paludis/handled_information.hh>
+#include <tr1/functional>
#include <sstream>
#include <functional>
#include <algorithm>
@@ -70,9 +69,9 @@ namespace paludis
UninstallActionOptions uninstall_options;
std::list<std::string> raw_targets;
- tr1::shared_ptr<ConstTreeSequence<SetSpecTree, AllDepSpec> > targets;
- tr1::shared_ptr<std::string> add_to_world_spec;
- tr1::shared_ptr<const DestinationsSet> destinations;
+ std::tr1::shared_ptr<ConstTreeSequence<SetSpecTree, AllDepSpec> > targets;
+ std::tr1::shared_ptr<std::string> add_to_world_spec;
+ std::tr1::shared_ptr<const DestinationsSet> destinations;
bool pretend;
bool fetch_only;
@@ -87,7 +86,7 @@ namespace paludis
bool had_resolution_failures;
Implementation<InstallTask>(Environment * const e, const DepListOptions & o,
- tr1::shared_ptr<const DestinationsSet> d) :
+ std::tr1::shared_ptr<const DestinationsSet> d) :
env(e),
dep_list(e, o),
fetch_options(
@@ -100,10 +99,10 @@ namespace paludis
(k::no_config_protect(), false)
(k::debug_build(), iado_none)
(k::checks(), iaco_default)
- (k::destination(), tr1::shared_ptr<Repository>())
+ (k::destination(), std::tr1::shared_ptr<Repository>())
),
uninstall_options(false),
- targets(new ConstTreeSequence<SetSpecTree, AllDepSpec>(tr1::shared_ptr<AllDepSpec>(new AllDepSpec))),
+ targets(new ConstTreeSequence<SetSpecTree, AllDepSpec>(std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec))),
destinations(d),
pretend(false),
fetch_only(false),
@@ -119,7 +118,7 @@ namespace paludis
}
InstallTask::InstallTask(Environment * const env, const DepListOptions & options,
- const tr1::shared_ptr<const DestinationsSet> d) :
+ const std::tr1::shared_ptr<const DestinationsSet> d) :
PrivateImplementationPattern<InstallTask>(new Implementation<InstallTask>(env, options, d))
{
}
@@ -131,7 +130,7 @@ InstallTask::~InstallTask()
void
InstallTask::clear()
{
- _imp->targets.reset(new ConstTreeSequence<SetSpecTree, AllDepSpec>(tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
+ _imp->targets.reset(new ConstTreeSequence<SetSpecTree, AllDepSpec>(std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
_imp->had_set_targets = false;
_imp->had_package_targets = false;
_imp->dep_list.clear();
@@ -140,22 +139,22 @@ InstallTask::clear()
}
void
-InstallTask::set_targets_from_user_specs(const tr1::shared_ptr<const Sequence<std::string> > & s)
+InstallTask::set_targets_from_user_specs(const std::tr1::shared_ptr<const Sequence<std::string> > & s)
{
- using namespace tr1::placeholders;
- std::for_each(s->begin(), s->end(), tr1::bind(&InstallTask::_add_target, this, _1));
+ using namespace std::tr1::placeholders;
+ std::for_each(s->begin(), s->end(), std::tr1::bind(&InstallTask::_add_target, this, _1));
}
void
-InstallTask::set_targets_from_exact_packages(const tr1::shared_ptr<const PackageIDSequence> & s)
+InstallTask::set_targets_from_exact_packages(const std::tr1::shared_ptr<const PackageIDSequence> & s)
{
- using namespace tr1::placeholders;
- std::for_each(s->begin(), s->end(), tr1::bind(&InstallTask::_add_package_id, this, _1));
+ using namespace std::tr1::placeholders;
+ std::for_each(s->begin(), s->end(), std::tr1::bind(&InstallTask::_add_package_id, this, _1));
}
namespace
{
- tr1::shared_ptr<DepListEntryHandled> handled_from_string(const std::string & s,
+ std::tr1::shared_ptr<DepListEntryHandled> handled_from_string(const std::string & s,
const Environment * const env)
{
Context context("When decoding DepListEntryHandled value '" + s + "':");
@@ -202,7 +201,7 @@ namespace
}
void
-InstallTask::set_targets_from_serialisation(const std::string & format, const tr1::shared_ptr<const Sequence<std::string> > & ss)
+InstallTask::set_targets_from_serialisation(const std::string & format, const std::tr1::shared_ptr<const Sequence<std::string> > & ss)
{
if (format != "0.25")
throw InternalError(PALUDIS_HERE, "Serialisation format '" + format + "' not supported by this version of Paludis");
@@ -222,13 +221,13 @@ InstallTask::set_targets_from_serialisation(const std::string & format, const tr
if (tokens.empty())
throw InternalError(PALUDIS_HERE, "Serialised value '" + *s + "' too short: no package_id");
- const tr1::shared_ptr<const PackageID> package_id(*_imp->env->package_database()->query(
+ const std::tr1::shared_ptr<const PackageID> package_id(*_imp->env->package_database()->query(
query::Matches(parse_user_package_dep_spec(*tokens.begin(), UserPackageDepSpecOptions())), qo_require_exactly_one)->begin());
tokens.pop_front();
if (tokens.empty())
throw InternalError(PALUDIS_HERE, "Serialised value '" + *s + "' too short: no destination");
- tr1::shared_ptr<Repository> destination;
+ std::tr1::shared_ptr<Repository> destination;
if ("0" != *tokens.begin())
destination = _imp->env->package_database()->fetch_repository(RepositoryName(*tokens.begin()));
tokens.pop_front();
@@ -240,7 +239,7 @@ InstallTask::set_targets_from_serialisation(const std::string & format, const tr
if (tokens.empty())
throw InternalError(PALUDIS_HERE, "Serialised value '" + *s + "' too short: no handled");
- tr1::shared_ptr<DepListEntryHandled> handled(handled_from_string(*tokens.begin(), _imp->env));
+ std::tr1::shared_ptr<DepListEntryHandled> handled(handled_from_string(*tokens.begin(), _imp->env));
tokens.pop_front();
if (! tokens.empty())
@@ -376,7 +375,7 @@ InstallTask::_add_target(const std::string & target)
{
Context context("When adding install target '" + target + "':");
- tr1::shared_ptr<SetSpecTree::ConstItem> s;
+ std::tr1::shared_ptr<SetSpecTree::ConstItem> s;
std::string modified_target(target);
bool done(false);
@@ -423,9 +422,9 @@ InstallTask::_add_target(const std::string & target)
if (std::string::npos != target.find('/'))
{
- tr1::shared_ptr<PackageDepSpec> spec(new PackageDepSpec(parse_user_package_dep_spec(target, UserPackageDepSpecOptions())));
- spec->set_tag(tr1::shared_ptr<const DepTag>(new TargetDepTag));
- _imp->targets->add(tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(
+ std::tr1::shared_ptr<PackageDepSpec> spec(new PackageDepSpec(parse_user_package_dep_spec(target, UserPackageDepSpecOptions())));
+ spec->set_tag(std::tr1::shared_ptr<const DepTag>(new TargetDepTag));
+ _imp->targets->add(std::tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(
new TreeLeaf<SetSpecTree, PackageDepSpec>(spec)));
}
else
@@ -435,9 +434,9 @@ InstallTask::_add_target(const std::string & target)
QualifiedPackageName q(_imp->env->package_database()->fetch_unique_qualified_package_name(
PackageNamePart(target), query::MaybeSupportsAction<InstallAction>()));
modified_target = stringify(q);
- tr1::shared_ptr<PackageDepSpec> spec(new PackageDepSpec(make_package_dep_spec().package(q)));
- spec->set_tag(tr1::shared_ptr<const DepTag>(new TargetDepTag));
- _imp->targets->add(tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(
+ std::tr1::shared_ptr<PackageDepSpec> spec(new PackageDepSpec(make_package_dep_spec().package(q)));
+ spec->set_tag(std::tr1::shared_ptr<const DepTag>(new TargetDepTag));
+ _imp->targets->add(std::tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(
new TreeLeaf<SetSpecTree, PackageDepSpec>(spec)));
}
catch (const NoSuchPackageError &)
@@ -452,7 +451,7 @@ InstallTask::_add_target(const std::string & target)
}
void
-InstallTask::_add_package_id(const tr1::shared_ptr<const PackageID> & target)
+InstallTask::_add_package_id(const std::tr1::shared_ptr<const PackageID> & target)
{
Context context("When adding install target '" + stringify(*target) + "' from ID:");
@@ -466,14 +465,14 @@ InstallTask::_add_package_id(const tr1::shared_ptr<const PackageID> & target)
if (! _imp->override_target_type)
_imp->dep_list.options()->target_type = dl_target_package;
- tr1::shared_ptr<PackageDepSpec> spec(new PackageDepSpec(make_package_dep_spec()
+ std::tr1::shared_ptr<PackageDepSpec> spec(new PackageDepSpec(make_package_dep_spec()
.package(target->name())
.version_requirement(VersionRequirement(vo_equal, target->version()))
.slot_requirement(make_shared_ptr(new UserSlotExactRequirement(target->slot())))
.repository(target->repository()->name())));
- spec->set_tag(tr1::shared_ptr<const DepTag>(new TargetDepTag));
- _imp->targets->add(tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(
+ spec->set_tag(std::tr1::shared_ptr<const DepTag>(new TargetDepTag));
+ _imp->targets->add(std::tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(
new TreeLeaf<SetSpecTree, PackageDepSpec>(spec)));
_imp->raw_targets.push_back(stringify(*spec));
@@ -739,7 +738,7 @@ InstallTask::_one(const DepList::Iterator dep, const int x, const int y, const i
(*r)->invalidate();
// look for packages with the same name in the same slot in the destination repos
- tr1::shared_ptr<const PackageIDSequence> collision_list;
+ std::tr1::shared_ptr<const PackageIDSequence> collision_list;
if (dep->destination)
collision_list = _imp->env->package_database()->query(
@@ -829,7 +828,7 @@ InstallTask::_one(const DepList::Iterator dep, const int x, const int y, const i
void
InstallTask::_main_actions()
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
/* we're about to fetch / install the entire list */
if (_imp->fetch_only)
@@ -857,7 +856,7 @@ InstallTask::_main_actions()
/* fetch / install our entire list */
int x(0), y(std::count_if(_imp->dep_list.begin(), _imp->dep_list.end(),
- tr1::bind(std::equal_to<DepListEntryKind>(), dlk_package, tr1::bind<DepListEntryKind>(tr1::mem_fn(&DepListEntry::kind), _1)))),
+ std::tr1::bind(std::equal_to<DepListEntryKind>(), dlk_package, std::tr1::bind<DepListEntryKind>(std::tr1::mem_fn(&DepListEntry::kind), _1)))),
s(0), f(0);
for (DepList::Iterator dep(_imp->dep_list.begin()), dep_end(_imp->dep_list.end()) ;
@@ -884,7 +883,7 @@ InstallTask::_main_actions()
case itcof_if_satisfied:
{
- tr1::shared_ptr<const PackageDepSpec> d(_unsatisfied(*dep));
+ std::tr1::shared_ptr<const PackageDepSpec> d(_unsatisfied(*dep));
if (! d)
break;
dep->handled.reset(new DepListEntryHandledSkippedUnsatisfied(*d));
@@ -895,7 +894,7 @@ InstallTask::_main_actions()
case itcof_if_independent:
{
- tr1::shared_ptr<const PackageID> d(_dependent(*dep));
+ std::tr1::shared_ptr<const PackageID> d(_dependent(*dep));
if (! d)
break;
dep->handled.reset(new DepListEntryHandledSkippedDependent(d));
@@ -954,8 +953,8 @@ InstallTask::_main_actions()
"() \t\r\n"));
}
- tr1::shared_ptr<ConstTreeSequence<SetSpecTree, AllDepSpec> > all(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
- tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
+ std::tr1::shared_ptr<ConstTreeSequence<SetSpecTree, AllDepSpec> > all(new ConstTreeSequence<SetSpecTree, AllDepSpec>(
+ std::tr1::shared_ptr<AllDepSpec>(new AllDepSpec)));
std::list<std::string> tokens;
tokenise_whitespace(*_imp->add_to_world_spec, std::back_inserter(tokens));
if ((! tokens.empty()) && ("(" == *tokens.begin()) && (")" == *previous(tokens.end())))
@@ -968,12 +967,12 @@ InstallTask::_main_actions()
t != t_end ; ++t)
{
if (s_had_package_targets)
- all->add(tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(
- new TreeLeaf<SetSpecTree, PackageDepSpec>(tr1::shared_ptr<PackageDepSpec>(
+ all->add(std::tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(
+ new TreeLeaf<SetSpecTree, PackageDepSpec>(std::tr1::shared_ptr<PackageDepSpec>(
new PackageDepSpec(parse_user_package_dep_spec(*t, UserPackageDepSpecOptions()))))));
else
- all->add(tr1::shared_ptr<TreeLeaf<SetSpecTree, NamedSetDepSpec> >(
- new TreeLeaf<SetSpecTree, NamedSetDepSpec>(tr1::shared_ptr<NamedSetDepSpec>(
+ all->add(std::tr1::shared_ptr<TreeLeaf<SetSpecTree, NamedSetDepSpec> >(
+ new TreeLeaf<SetSpecTree, NamedSetDepSpec>(std::tr1::shared_ptr<NamedSetDepSpec>(
new NamedSetDepSpec(SetName(*t))))));
}
@@ -1253,7 +1252,7 @@ namespace
}
void
-InstallTask::world_update_packages(tr1::shared_ptr<const SetSpecTree::ConstItem> a)
+InstallTask::world_update_packages(std::tr1::shared_ptr<const SetSpecTree::ConstItem> a)
{
WorldTargetFinder w(_imp->env, this);
a->accept(w);
@@ -1281,7 +1280,7 @@ namespace
const Environment * const env;
const PackageID & id;
- tr1::shared_ptr<const PackageDepSpec> failure;
+ std::tr1::shared_ptr<const PackageDepSpec> failure;
std::set<SetName> recursing_sets;
CheckSatisfiedVisitor(const Environment * const e,
@@ -1333,7 +1332,7 @@ namespace
void visit_leaf(const NamedSetDepSpec & s)
{
- tr1::shared_ptr<const SetSpecTree::ConstItem> set(env->set(s.name()));
+ std::tr1::shared_ptr<const SetSpecTree::ConstItem> set(env->set(s.name()));
if (! set)
{
@@ -1355,7 +1354,7 @@ namespace
};
}
-tr1::shared_ptr<const PackageDepSpec>
+std::tr1::shared_ptr<const PackageDepSpec>
InstallTask::_unsatisfied(const DepListEntry & e) const
{
Context context("When checking whether dependencies for '" + stringify(*e.package_id) + "' are satisfied:");
@@ -1441,17 +1440,17 @@ namespace
const Environment * const env;
const DepList & dep_list;
- const tr1::shared_ptr<const PackageID> id;
- tr1::shared_ptr<PackageIDSet> already_checked;
+ const std::tr1::shared_ptr<const PackageID> id;
+ std::tr1::shared_ptr<PackageIDSet> already_checked;
- tr1::shared_ptr<const PackageID> failure;
+ std::tr1::shared_ptr<const PackageID> failure;
std::set<SetName> recursing_sets;
CheckIndependentVisitor(
const Environment * const e,
const DepList & d,
- const tr1::shared_ptr<const PackageID> & i,
- const tr1::shared_ptr<PackageIDSet> & a) :
+ const std::tr1::shared_ptr<const PackageID> & i,
+ const std::tr1::shared_ptr<PackageIDSet> & a) :
env(e),
dep_list(d),
id(i),
@@ -1492,7 +1491,7 @@ namespace
/* no match on the dep list, fall back to installed packages. if
* there are no matches here it's not a problem because of or-deps. */
- tr1::shared_ptr<const PackageIDSequence> installed(env->package_database()->query(
+ std::tr1::shared_ptr<const PackageIDSequence> installed(env->package_database()->query(
query::Matches(a) &
query::SupportsAction<InstalledAction>(),
qo_whatever));
@@ -1545,7 +1544,7 @@ namespace
void visit_leaf(const NamedSetDepSpec & s)
{
- tr1::shared_ptr<const SetSpecTree::ConstItem> set(env->set(s.name()));
+ std::tr1::shared_ptr<const SetSpecTree::ConstItem> set(env->set(s.name()));
if (! set)
{
@@ -1582,12 +1581,12 @@ InstallTask::had_action_failures() const
}
-tr1::shared_ptr<const PackageID>
+std::tr1::shared_ptr<const PackageID>
InstallTask::_dependent(const DepListEntry & e) const
{
Context context("When checking whether dependencies for '" + stringify(*e.package_id) + "' are independent of failed packages:");
- tr1::shared_ptr<PackageIDSet> already_checked(new PackageIDSet);
+ std::tr1::shared_ptr<PackageIDSet> already_checked(new PackageIDSet);
CheckIndependentVisitor v(environment(), _imp->dep_list, e.package_id, already_checked);
already_checked->insert(e.package_id);
diff --git a/paludis/install_task.hh b/paludis/install_task.hh
index ac53716..cc5ef28 100644
--- a/paludis/install_task.hh
+++ b/paludis/install_task.hh
@@ -66,17 +66,17 @@ namespace paludis
void _display_failure_summary();
void _add_target(const std::string &);
- void _add_package_id(const tr1::shared_ptr<const PackageID> &);
+ void _add_package_id(const std::tr1::shared_ptr<const PackageID> &);
- tr1::shared_ptr<const PackageDepSpec> _unsatisfied(const DepListEntry &) const;
- tr1::shared_ptr<const PackageID> _dependent(const DepListEntry &) const;
+ std::tr1::shared_ptr<const PackageDepSpec> _unsatisfied(const DepListEntry &) const;
+ std::tr1::shared_ptr<const PackageID> _dependent(const DepListEntry &) const;
protected:
///\name Basic operations
///\{
InstallTask(Environment * const env, const DepListOptions & options,
- tr1::shared_ptr<const DestinationsSet> destinations);
+ std::tr1::shared_ptr<const DestinationsSet> destinations);
///\}
@@ -109,9 +109,9 @@ namespace paludis
///\name Targets
///\{
- void set_targets_from_user_specs(const tr1::shared_ptr<const Sequence<std::string> > &);
- void set_targets_from_exact_packages(const tr1::shared_ptr<const PackageIDSequence> &);
- void set_targets_from_serialisation(const std::string &, const tr1::shared_ptr<const Sequence<std::string> > &);
+ void set_targets_from_user_specs(const std::tr1::shared_ptr<const Sequence<std::string> > &);
+ void set_targets_from_exact_packages(const std::tr1::shared_ptr<const PackageIDSequence> &);
+ void set_targets_from_serialisation(const std::string &, const std::tr1::shared_ptr<const Sequence<std::string> > &);
void clear();
void override_target_type(const DepListTargetType);
@@ -140,7 +140,7 @@ namespace paludis
virtual void on_display_failure_summary_success(const DepListEntry &) = 0;
virtual void on_display_failure_summary_failure(const DepListEntry &) = 0;
virtual void on_display_failure_summary_skipped_unsatisfied(const DepListEntry &, const PackageDepSpec &) = 0;
- virtual void on_display_failure_summary_skipped_dependent(const DepListEntry &, const tr1::shared_ptr<const PackageID> &) = 0;
+ virtual void on_display_failure_summary_skipped_dependent(const DepListEntry &, const std::tr1::shared_ptr<const PackageID> &) = 0;
virtual void on_display_failure_summary_totals(const int, const int, const int, const int, const int) = 0;
virtual void on_display_failure_summary_post() = 0;
@@ -164,7 +164,7 @@ namespace paludis
virtual void on_skip_unsatisfied(const DepListEntry &, const PackageDepSpec &,
const int x, const int y, const int s, const int f) = 0;
- virtual void on_skip_dependent(const DepListEntry &, const tr1::shared_ptr<const PackageID> &,
+ virtual void on_skip_dependent(const DepListEntry &, const std::tr1::shared_ptr<const PackageID> &,
const int x, const int y, const int s, const int f) = 0;
virtual void on_skip_already_done(const DepListEntry &, const int, const int, const int, const int) = 0;
@@ -210,7 +210,7 @@ namespace paludis
///\{
virtual void world_update_set(const SetName &);
- virtual void world_update_packages(tr1::shared_ptr<const SetSpecTree::ConstItem>);
+ virtual void world_update_packages(std::tr1::shared_ptr<const SetSpecTree::ConstItem>);
///\}
diff --git a/paludis/literal_metadata_key.cc b/paludis/literal_metadata_key.cc
index 694c517..8eb9a36 100644
--- a/paludis/literal_metadata_key.cc
+++ b/paludis/literal_metadata_key.cc
@@ -23,11 +23,11 @@
#include <paludis/util/sequence.hh>
#include <paludis/util/wrapped_forward_iterator.hh>
#include <paludis/util/join.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/visitor-impl.hh>
#include <paludis/formatter.hh>
#include <paludis/package_id.hh>
#include <paludis/action.hh>
+#include <tr1/functional>
using namespace paludis;
@@ -36,9 +36,9 @@ namespace paludis
template <>
struct Implementation<LiteralMetadataFSEntrySequenceKey>
{
- const tr1::shared_ptr<const FSEntrySequence> value;
+ const std::tr1::shared_ptr<const FSEntrySequence> value;
- Implementation(const tr1::shared_ptr<const FSEntrySequence> & v) :
+ Implementation(const std::tr1::shared_ptr<const FSEntrySequence> & v) :
value(v)
{
}
@@ -47,9 +47,9 @@ namespace paludis
template <>
struct Implementation<LiteralMetadataStringSetKey>
{
- const tr1::shared_ptr<const Set<std::string> > value;
+ const std::tr1::shared_ptr<const Set<std::string> > value;
- Implementation(const tr1::shared_ptr<const Set<std::string> > & v) :
+ Implementation(const std::tr1::shared_ptr<const Set<std::string> > & v) :
value(v)
{
}
@@ -71,7 +71,7 @@ namespace paludis
}
LiteralMetadataFSEntrySequenceKey::LiteralMetadataFSEntrySequenceKey(const std::string & h, const std::string & r,
- const MetadataKeyType t, const tr1::shared_ptr<const FSEntrySequence> & v) :
+ const MetadataKeyType t, const std::tr1::shared_ptr<const FSEntrySequence> & v) :
MetadataCollectionKey<FSEntrySequence>(h, r, t),
PrivateImplementationPattern<LiteralMetadataFSEntrySequenceKey>(new Implementation<LiteralMetadataFSEntrySequenceKey>(v)),
_imp(PrivateImplementationPattern<LiteralMetadataFSEntrySequenceKey>::_imp)
@@ -82,7 +82,7 @@ LiteralMetadataFSEntrySequenceKey::~LiteralMetadataFSEntrySequenceKey()
{
}
-const tr1::shared_ptr<const FSEntrySequence>
+const std::tr1::shared_ptr<const FSEntrySequence>
LiteralMetadataFSEntrySequenceKey::value() const
{
return _imp->value;
@@ -99,12 +99,12 @@ namespace
std::string
LiteralMetadataFSEntrySequenceKey::pretty_print_flat(const Formatter<FSEntry> & f) const
{
- using namespace tr1::placeholders;
- return join(value()->begin(), value()->end(), " ", tr1::bind(&format_fsentry, _1, f));
+ using namespace std::tr1::placeholders;
+ return join(value()->begin(), value()->end(), " ", std::tr1::bind(&format_fsentry, _1, f));
}
LiteralMetadataStringSetKey::LiteralMetadataStringSetKey(const std::string & h, const std::string & r,
- const MetadataKeyType t, const tr1::shared_ptr<const Set<std::string> > & v) :
+ const MetadataKeyType t, const std::tr1::shared_ptr<const Set<std::string> > & v) :
MetadataCollectionKey<Set<std::string> >(h, r, t),
PrivateImplementationPattern<LiteralMetadataStringSetKey>(new Implementation<LiteralMetadataStringSetKey>(v)),
_imp(PrivateImplementationPattern<LiteralMetadataStringSetKey>::_imp)
@@ -115,7 +115,7 @@ LiteralMetadataStringSetKey::~LiteralMetadataStringSetKey()
{
}
-const tr1::shared_ptr<const Set<std::string> >
+const std::tr1::shared_ptr<const Set<std::string> >
LiteralMetadataStringSetKey::value() const
{
return _imp->value;
@@ -132,18 +132,18 @@ namespace
std::string
LiteralMetadataStringSetKey::pretty_print_flat(const Formatter<std::string> & f) const
{
- using namespace tr1::placeholders;
- return join(value()->begin(), value()->end(), " ", tr1::bind(&format_string, _1, f));
+ using namespace std::tr1::placeholders;
+ return join(value()->begin(), value()->end(), " ", std::tr1::bind(&format_string, _1, f));
}
-ExtraLiteralMetadataValueKeyMethods<tr1::shared_ptr<const PackageID> >::~ExtraLiteralMetadataValueKeyMethods()
+ExtraLiteralMetadataValueKeyMethods<std::tr1::shared_ptr<const PackageID> >::~ExtraLiteralMetadataValueKeyMethods()
{
}
std::string
-ExtraLiteralMetadataValueKeyMethods<tr1::shared_ptr<const PackageID> >::pretty_print(const Formatter<PackageID> & f) const
+ExtraLiteralMetadataValueKeyMethods<std::tr1::shared_ptr<const PackageID> >::pretty_print(const Formatter<PackageID> & f) const
{
- tr1::shared_ptr<const PackageID> v(static_cast<const LiteralMetadataValueKey<tr1::shared_ptr<const PackageID> > *>(this)->value());
+ std::tr1::shared_ptr<const PackageID> v(static_cast<const LiteralMetadataValueKey<std::tr1::shared_ptr<const PackageID> > *>(this)->value());
if (v->supports_action(SupportsActionTest<InstalledAction>()))
return f.format(*v, format::Installed());
else if (v->supports_action(SupportsActionTest<InstallAction>()))
@@ -181,5 +181,5 @@ LiteralMetadataValueKey<T_>::value() const
template class LiteralMetadataValueKey<FSEntry>;
template class LiteralMetadataValueKey<std::string>;
template class LiteralMetadataValueKey<bool>;
-template class LiteralMetadataValueKey<tr1::shared_ptr<const PackageID> >;
+template class LiteralMetadataValueKey<std::tr1::shared_ptr<const PackageID> >;
diff --git a/paludis/literal_metadata_key.hh b/paludis/literal_metadata_key.hh
index ef63878..0d4821a 100644
--- a/paludis/literal_metadata_key.hh
+++ b/paludis/literal_metadata_key.hh
@@ -57,8 +57,8 @@ namespace paludis
* \since 0.26
*/
template <>
- class ExtraLiteralMetadataValueKeyMethods<tr1::shared_ptr<const PackageID> > :
- public virtual ExtraMetadataValueKeyMethods<tr1::shared_ptr<const PackageID> >
+ class ExtraLiteralMetadataValueKeyMethods<std::tr1::shared_ptr<const PackageID> > :
+ public virtual ExtraMetadataValueKeyMethods<std::tr1::shared_ptr<const PackageID> >
{
public:
virtual ~ExtraLiteralMetadataValueKeyMethods() = 0;
@@ -115,12 +115,12 @@ namespace paludis
///\{
LiteralMetadataFSEntrySequenceKey(const std::string &, const std::string &, const MetadataKeyType,
- const tr1::shared_ptr<const FSEntrySequence> &);
+ const std::tr1::shared_ptr<const FSEntrySequence> &);
~LiteralMetadataFSEntrySequenceKey();
///\}
- virtual const tr1::shared_ptr<const FSEntrySequence> value() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ virtual const std::tr1::shared_ptr<const FSEntrySequence> value() const PALUDIS_ATTRIBUTE((warn_unused_result));
virtual std::string pretty_print_flat(const Formatter<FSEntry> &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
@@ -145,12 +145,12 @@ namespace paludis
///\{
LiteralMetadataStringSetKey(const std::string &, const std::string &, const MetadataKeyType,
- const tr1::shared_ptr<const Set<std::string> > &);
+ const std::tr1::shared_ptr<const Set<std::string> > &);
~LiteralMetadataStringSetKey();
///\}
- virtual const tr1::shared_ptr<const Set<std::string> > value() const PALUDIS_ATTRIBUTE((warn_unused_result));
+ virtual const std::tr1::shared_ptr<const Set<std::string> > value() const PALUDIS_ATTRIBUTE((warn_unused_result));
virtual std::string pretty_print_flat(const Formatter<std::string> &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
diff --git a/paludis/mask-fwd.hh b/paludis/mask-fwd.hh
index 294eeb2..ce9a054 100644
--- a/paludis/mask-fwd.hh
+++ b/paludis/mask-fwd.hh
@@ -24,7 +24,7 @@
#include <paludis/util/kc-fwd.hh>
#include <paludis/util/keys.hh>
#include <paludis/util/fs_entry-fwd.hh>
-#include <paludis/util/tr1_memory.hh>
+#include <tr1/memory>
/** \file
* Forward declarations for paludis/mask.hh .
@@ -56,7 +56,7 @@ namespace paludis
*/
typedef kc::KeyedClass<
kc::Field<k::mask_file, FSEntry>,
- kc::Field<k::comment, tr1::shared_ptr<const Sequence<std::string> > >
+ kc::Field<k::comment, std::tr1::shared_ptr<const Sequence<std::string> > >
> RepositoryMaskInfo;
}
diff --git a/paludis/mask.hh b/paludis/mask.hh
index 09024e5..f84a814 100644
--- a/paludis/mask.hh
+++ b/paludis/mask.hh
@@ -131,7 +131,7 @@ namespace paludis
/**
* Fetch the metadata key that is not accepted.
*/
- virtual const tr1::shared_ptr<const MetadataKey> unaccepted_key() const = 0;
+ virtual const std::tr1::shared_ptr<const MetadataKey> unaccepted_key() const = 0;
};
/**
@@ -151,7 +151,7 @@ namespace paludis
* Fetch a metadata key explaining the mask. May return a zero
* pointer, if no more information is available.
*/
- virtual const tr1::shared_ptr<const MetadataKey> mask_key() const = 0;
+ virtual const std::tr1::shared_ptr<const MetadataKey> mask_key() const = 0;
};
/**
@@ -193,7 +193,7 @@ namespace paludis
/**
* Fetch the associated package.
*/
- virtual const tr1::shared_ptr<const PackageID> associated_package() const = 0;
+ virtual const std::tr1::shared_ptr<const PackageID> associated_package() const = 0;
};
}
diff --git a/paludis/match_package.cc b/paludis/match_package.cc
index 0852c0c..4d115d5 100644
--- a/paludis/match_package.cc
+++ b/paludis/match_package.cc
@@ -26,7 +26,7 @@
#include <paludis/package_id.hh>
#include <paludis/slot_requirement.hh>
#include <paludis/util/visitor-impl.hh>
-#include <paludis/util/tr1_functional.hh>
+#include <tr1/functional>
#include <algorithm>
using namespace paludis;
@@ -136,12 +136,12 @@ paludis::match_package_in_set(
const SetSpecTree::ConstItem & target,
const PackageID & entry)
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
DepSpecFlattener<SetSpecTree, PackageDepSpec> f(&env);
target.accept(f);
return indirect_iterator(f.end()) != std::find_if(
indirect_iterator(f.begin()), indirect_iterator(f.end()),
- tr1::bind(&match_package, tr1::cref(env), _1, tr1::cref(entry)));
+ std::tr1::bind(&match_package, std::tr1::cref(env), _1, std::tr1::cref(entry)));
}
diff --git a/paludis/match_package.hh b/paludis/match_package.hh
index ccff1cd..0fcf84d 100644
--- a/paludis/match_package.hh
+++ b/paludis/match_package.hh
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -31,11 +31,11 @@
*/
#include <paludis/util/attributes.hh>
-#include <paludis/util/tr1_memory.hh>
#include <paludis/dep_spec-fwd.hh>
#include <paludis/dep_tree.hh>
#include <paludis/environment-fwd.hh>
#include <paludis/package_id-fwd.hh>
+#include <tr1/memory>
namespace paludis
{
diff --git a/paludis/merger.cc b/paludis/merger.cc
index cf4a7cd..7279992 100644
--- a/paludis/merger.cc
+++ b/paludis/merger.cc
@@ -24,6 +24,8 @@
#include <paludis/util/fd_holder.hh>
#include <paludis/util/log.hh>
#include <paludis/util/options.hh>
+#include <paludis/util/hashes.hh>
+#include <paludis/util/private_implementation_pattern-impl.hh>
#include <paludis/selinux/security_context.hh>
#include <paludis/environment.hh>
#include <paludis/hook.hh>
@@ -34,6 +36,7 @@
#include <errno.h>
#include <cstring>
#include <list>
+#include <tr1/unordered_map>
#include "config.h"
#ifdef HAVE_XATTRS
@@ -44,15 +47,34 @@ using namespace paludis;
#include <paludis/merger-se.cc>
+typedef std::tr1::unordered_map<std::pair<dev_t, ino_t>, std::string, Hash<std::pair<dev_t, ino_t> > > MergedMap;
+
+namespace paludis
+{
+ template <>
+ struct Implementation<Merger>
+ {
+ MergedMap merged_ids;
+ MergerParams params;
+ bool result;
+ bool skip_dir;
+
+ Implementation(const MergerParams & p) :
+ params(p),
+ result(true),
+ skip_dir(false)
+ {
+ }
+ };
+}
+
MergerError::MergerError(const std::string & s) throw () :
Exception(s)
{
}
Merger::Merger(const MergerParams & p) :
- _params(p),
- _result(true),
- _skip_dir(false)
+ PrivateImplementationPattern<Merger>(new Implementation<Merger>(p))
{
}
@@ -63,37 +85,37 @@ Merger::~Merger()
bool
Merger::check()
{
- Context context("When checking merge from '" + stringify(_params[k::image()]) + "' to '"
- + stringify(_params[k::root()]) + "':");
+ Context context("When checking merge from '" + stringify(_imp->params[k::image()]) + "' to '"
+ + stringify(_imp->params[k::root()]) + "':");
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_check_pre")
- ("INSTALL_SOURCE", stringify(_params[k::image()]))
- ("INSTALL_DESTINATION", stringify(_params[k::root()])))).max_exit_status)
+ ("INSTALL_SOURCE", stringify(_imp->params[k::image()]))
+ ("INSTALL_DESTINATION", stringify(_imp->params[k::root()])))).max_exit_status)
make_check_fail();
- do_dir_recursive(true, _params[k::image()], _params[k::root()] / _params[k::install_under()]);
+ do_dir_recursive(true, _imp->params[k::image()], _imp->params[k::root()] / _imp->params[k::install_under()]);
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_check_post")
- ("INSTALL_SOURCE", stringify(_params[k::image()]))
- ("INSTALL_DESTINATION", stringify(_params[k::root()])))).max_exit_status)
+ ("INSTALL_SOURCE", stringify(_imp->params[k::image()]))
+ ("INSTALL_DESTINATION", stringify(_imp->params[k::root()])))).max_exit_status)
make_check_fail();
- return _result;
+ return _imp->result;
}
void
Merger::make_check_fail()
{
- _result = false;
+ _imp->result = false;
}
void
Merger::merge()
{
- Context context("When performing merge from '" + stringify(_params[k::image()]) + "' to '"
- + stringify(_params[k::root()]) + "':");
+ Context context("When performing merge from '" + stringify(_imp->params[k::image()]) + "' to '"
+ + stringify(_imp->params[k::root()]) + "':");
struct SaveUmask
{
@@ -110,20 +132,20 @@ Merger::merge()
}
} old_umask(::umask(0000));
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_install_pre")
- ("INSTALL_SOURCE", stringify(_params[k::image()]))
- ("INSTALL_DESTINATION", stringify(_params[k::root()])))).max_exit_status)
+ ("INSTALL_SOURCE", stringify(_imp->params[k::image()]))
+ ("INSTALL_DESTINATION", stringify(_imp->params[k::root()])))).max_exit_status)
Log::get_instance()->message("merger.pre_hooks.failure", ll_warning, lc_context) <<
- "Merge of '" << _params[k::image()] << "' to '" << _params[k::root()] << "' pre hooks returned non-zero";
+ "Merge of '" << _imp->params[k::image()] << "' to '" << _imp->params[k::root()] << "' pre hooks returned non-zero";
/* special handling for install_under */
{
- Context local_context("When preparing install_under directory '" + stringify(_params[k::install_under()]) + "' under root '"
- + stringify(_params[k::root()]) + "':");
+ Context local_context("When preparing install_under directory '" + stringify(_imp->params[k::install_under()]) + "' under root '"
+ + stringify(_imp->params[k::root()]) + "':");
std::list<FSEntry> dd;
- for (FSEntry d(_params[k::root()].realpath() / _params[k::install_under()]), d_end(_params[k::root()].realpath()) ;
+ for (FSEntry d(_imp->params[k::root()].realpath() / _imp->params[k::install_under()]), d_end(_imp->params[k::root()].realpath()) ;
d != d_end ; d = d.dirname())
dd.push_front(d);
for (std::list<FSEntry>::iterator d(dd.begin()), d_end(dd.end()) ; d != d_end ; ++d)
@@ -136,14 +158,14 @@ Merger::merge()
record_install_under_dir(*d, MergeStatusFlags() + msi_used_existing);
}
- do_dir_recursive(false, _params[k::image()], (_params[k::root()] / _params[k::install_under()]).realpath());
+ do_dir_recursive(false, _imp->params[k::image()], (_imp->params[k::root()] / _imp->params[k::install_under()]).realpath());
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_install_post")
- ("INSTALL_SOURCE", stringify(_params[k::image()]))
- ("INSTALL_DESTINATION", stringify(_params[k::root()])))).max_exit_status)
+ ("INSTALL_SOURCE", stringify(_imp->params[k::image()]))
+ ("INSTALL_DESTINATION", stringify(_imp->params[k::root()])))).max_exit_status)
Log::get_instance()->message("merger.post_hooks.failure", ll_warning, lc_context) <<
- "Merge of '" << _params[k::image()] << "' to '" << _params[k::root()] << "' post hooks returned non-zero";
+ "Merge of '" << _imp->params[k::image()] << "' to '" << _imp->params[k::root()] << "' post hooks returned non-zero";
}
EntryType
@@ -181,9 +203,9 @@ Merger::do_dir_recursive(bool is_check, const FSEntry & src, const FSEntry & dst
DirIterator d(src, DirIteratorOptions() + dio_include_dotfiles + dio_inode_sort), d_end;
- if (is_check && d == d_end && dst != _params[k::root()].realpath())
+ if (is_check && d == d_end && dst != _imp->params[k::root()].realpath())
{
- if (_params[k::options()][mo_allow_empty_dirs])
+ if (_imp->params[k::options()][mo_allow_empty_dirs])
Log::get_instance()->message("merger.empty_directory", ll_warning, lc_context) << "Installing empty directory '"
<< stringify(dst) << "'";
else
@@ -205,13 +227,13 @@ Merger::do_dir_recursive(bool is_check, const FSEntry & src, const FSEntry & dst
case et_dir:
on_dir(is_check, *d, dst);
- if (_result)
+ if (_imp->result)
{
- if (! _skip_dir)
+ if (! _imp->skip_dir)
do_dir_recursive(is_check, *d,
is_check ? (dst / d->basename()) : (dst / d->basename()).realpath());
else
- _skip_dir = false;
+ _imp->skip_dir = false;
}
continue;
@@ -238,7 +260,7 @@ Merger::on_file(bool is_check, const FSEntry & src, const FSEntry & dst)
EntryType m(entry_type(dst / src.basename()));
if (is_check &&
- 0 != _params[k::environment()]->perform_hook(extend_hook(
+ 0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_check_file_pre")
("INSTALL_SOURCE", stringify(src))
("INSTALL_DESTINATION", stringify(dst / src.basename())))).max_exit_status)
@@ -246,7 +268,7 @@ Merger::on_file(bool is_check, const FSEntry & src, const FSEntry & dst)
if (! is_check)
{
- HookResult hr(_params[k::environment()]->perform_hook(extend_hook(
+ HookResult hr(_imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_install_file_override")
("INSTALL_SOURCE", stringify(src))
("INSTALL_DESTINATION", stringify(dst / src.basename()))
@@ -257,7 +279,7 @@ Merger::on_file(bool is_check, const FSEntry & src, const FSEntry & dst)
<< stringify(src) << "' to '" << stringify(dst) << "' skip hooks returned non-zero";
else if (hr.output == "skip")
{
- std::string tidy(stringify((dst / src.basename()).strip_leading(_params[k::root()].realpath())));
+ std::string tidy(stringify((dst / src.basename()).strip_leading(_imp->params[k::root()].realpath())));
display_override("--- [skp] " + tidy);
return;
}
@@ -295,7 +317,7 @@ Merger::on_file(bool is_check, const FSEntry & src, const FSEntry & dst)
} while (false);
if (is_check &&
- 0 != _params[k::environment()]->perform_hook(extend_hook(
+ 0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_check_file_post")
("INSTALL_SOURCE", stringify(src))
("INSTALL_DESTINATION", stringify(dst / src.basename())))).max_exit_status)
@@ -310,7 +332,7 @@ Merger::on_dir(bool is_check, const FSEntry & src, const FSEntry & dst)
EntryType m(entry_type(dst / src.basename()));
if (is_check &&
- 0 != _params[k::environment()]->perform_hook(extend_hook(
+ 0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_check_dir_pre")
("INSTALL_SOURCE", stringify(src))
("INSTALL_DESTINATION", stringify(dst / src.basename())))).max_exit_status)
@@ -318,7 +340,7 @@ Merger::on_dir(bool is_check, const FSEntry & src, const FSEntry & dst)
if (! is_check)
{
- HookResult hr(_params[k::environment()]->perform_hook(extend_hook(
+ HookResult hr(_imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_install_dir_override")
("INSTALL_SOURCE", stringify(src))
("INSTALL_DESTINATION", stringify(dst / src.basename()))
@@ -329,9 +351,9 @@ Merger::on_dir(bool is_check, const FSEntry & src, const FSEntry & dst)
<< stringify(src) << "' to '" << stringify(dst) << "' skip hooks returned non-zero";
else if (hr.output == "skip")
{
- std::string tidy(stringify((dst / src.basename()).strip_leading(_params[k::root()].realpath())));
+ std::string tidy(stringify((dst / src.basename()).strip_leading(_imp->params[k::root()].realpath())));
display_override("--- [skp] " + tidy);
- _skip_dir = true;
+ _imp->skip_dir = true;
return;
}
}
@@ -369,7 +391,7 @@ Merger::on_dir(bool is_check, const FSEntry & src, const FSEntry & dst)
} while (false);
if (is_check &&
- 0 != _params[k::environment()]->perform_hook(extend_hook(
+ 0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_check_dir_post")
("INSTALL_SOURCE", stringify(src))
("INSTALL_DESTINATION", stringify(dst / src.basename())))).max_exit_status)
@@ -384,7 +406,7 @@ Merger::on_sym(bool is_check, const FSEntry & src, const FSEntry & dst)
EntryType m(entry_type(dst / src.basename()));
if (is_check &&
- 0 != _params[k::environment()]->perform_hook(extend_hook(
+ 0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_check_sym_post")
("INSTALL_SOURCE", stringify(src))
("INSTALL_DESTINATION", stringify(dst / src.basename())))).max_exit_status)
@@ -392,7 +414,7 @@ Merger::on_sym(bool is_check, const FSEntry & src, const FSEntry & dst)
if (! is_check)
{
- HookResult hr(_params[k::environment()]->perform_hook(extend_hook(
+ HookResult hr(_imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_install_sym_override")
("INSTALL_SOURCE", stringify(src))
("INSTALL_DESTINATION", stringify(dst / src.basename()))
@@ -403,14 +425,14 @@ Merger::on_sym(bool is_check, const FSEntry & src, const FSEntry & dst)
<< stringify(src) << "' to '" << stringify(dst) << "' skip hooks returned non-zero";
else if (hr.output == "skip")
{
- std::string tidy(stringify((dst / src.basename()).strip_leading(_params[k::root()].realpath())));
+ std::string tidy(stringify((dst / src.basename()).strip_leading(_imp->params[k::root()].realpath())));
display_override("--- [skp] " + tidy);
return;
}
}
else
{
- if (symlink_needs_rewriting(src) && ! _params[k::options()][mo_rewrite_symlinks])
+ if (symlink_needs_rewriting(src) && ! _imp->params[k::options()][mo_rewrite_symlinks])
on_error(is_check, "Symlink to image detected at: " + stringify(src) + " (" + src.readlink() + ")");
}
@@ -446,7 +468,7 @@ Merger::on_sym(bool is_check, const FSEntry & src, const FSEntry & dst)
} while (false);
if (is_check &&
- 0 != _params[k::environment()]->perform_hook(extend_hook(
+ 0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_check_sym_post")
("INSTALL_SOURCE", stringify(src))
("INSTALL_DESTINATION", stringify(dst / src.basename())))).max_exit_status)
@@ -639,7 +661,7 @@ Merger::install_file(const FSEntry & src, const FSEntry & dst_dir, const std::st
+ stringify(dst_name) + "':");
MergeStatusFlags result;
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_install_file_pre")
("INSTALL_SOURCE", stringify(src))
("INSTALL_DESTINATION", stringify(dst_dir / src.basename())))).max_exit_status)
@@ -649,7 +671,7 @@ Merger::install_file(const FSEntry & src, const FSEntry & dst_dir, const std::st
FSEntry dst(dst_dir / (stringify(dst_name) + "|paludis-midmerge"));
FSEntry dst_real(dst_dir / dst_name);
- tr1::shared_ptr<const SecurityContext> secctx(MatchPathCon::get_instance()->match(stringify(dst_real), src.permissions()));
+ std::tr1::shared_ptr<const SecurityContext> secctx(MatchPathCon::get_instance()->match(stringify(dst_real), src.permissions()));
FSCreateCon createcon(secctx);
if (0 != paludis::setfilecon(src, secctx))
throw MergerError("Could not set SELinux context on '"
@@ -662,10 +684,10 @@ Merger::install_file(const FSEntry & src, const FSEntry & dst_dir, const std::st
uid_t dest_uid(src.owner());
gid_t dest_gid(src.group());
- if (! _params[k::no_chown()])
+ if (! _imp->params[k::no_chown()])
{
- uid_t new_uid(dest_uid == _params[k::environment()]->reduced_uid() ? 0 : -1);
- gid_t new_gid(dest_gid == _params[k::environment()]->reduced_gid() ? 0 : -1);
+ uid_t new_uid(dest_uid == _imp->params[k::environment()]->reduced_uid() ? 0 : -1);
+ gid_t new_gid(dest_gid == _imp->params[k::environment()]->reduced_gid() ? 0 : -1);
if (uid_t(-1) != new_uid || gid_t(-1) != new_gid)
{
FSEntry(src).chown(new_uid, new_gid);
@@ -686,13 +708,13 @@ Merger::install_file(const FSEntry & src, const FSEntry & dst_dir, const std::st
/* set*id bits get partially clobbered on a rename on linux */
dst_real.chmod(src_perms);
- _merged_ids.insert(make_pair(src.lowlevel_id(), stringify(dst_real)));
+ _imp->merged_ids.insert(make_pair(src.lowlevel_id(), stringify(dst_real)));
}
else
{
do_copy = true;
std::pair<MergedMap::const_iterator, MergedMap::const_iterator> ii(
- _merged_ids.equal_range(src.lowlevel_id()));
+ _imp->merged_ids.equal_range(src.lowlevel_id()));
for (MergedMap::const_iterator i = ii.first ; i != ii.second ; ++i)
{
if (0 == ::link(i->second.c_str(), stringify(dst_real).c_str()))
@@ -719,7 +741,7 @@ Merger::install_file(const FSEntry & src, const FSEntry & dst_dir, const std::st
if (-1 == output_fd)
throw MergerError("Cannot write '" + stringify(dst) + "': " + stringify(::strerror(errno)));
- if (! _params[k::no_chown()])
+ if (! _imp->params[k::no_chown()])
if (0 != ::fchown(output_fd, dest_uid, dest_gid))
throw MergerError("Cannot fchown '" + stringify(dst) + "': " + stringify(::strerror(errno)));
@@ -740,10 +762,10 @@ Merger::install_file(const FSEntry & src, const FSEntry & dst_dir, const std::st
throw MergerError(
"rename(" + stringify(dst) + ", " + stringify(dst_real) + ") failed: " + stringify(::strerror(errno)));
- _merged_ids.insert(make_pair(src.lowlevel_id(), stringify(dst_real)));
+ _imp->merged_ids.insert(make_pair(src.lowlevel_id(), stringify(dst_real)));
}
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_install_file_post")
("INSTALL_SOURCE", stringify(src))
("INSTALL_DESTINATION", stringify(dst_dir / src.basename())))).max_exit_status)
@@ -757,7 +779,7 @@ bool
Merger::symlink_needs_rewriting(const FSEntry & sym)
{
std::string target(sym.readlink());
- std::string real_image(stringify(_params[k::image()].realpath()));
+ std::string real_image(stringify(_imp->params[k::image()].realpath()));
return (0 == target.compare(0, real_image.length(), real_image));
}
@@ -770,7 +792,7 @@ Merger::rewrite_symlink_as_needed(const FSEntry & src, const FSEntry & dst_dir)
FSCreateCon createcon(MatchPathCon::get_instance()->match(stringify(dst_dir / src.basename()), S_IFLNK));
- FSEntry real_image(_params[k::image()].realpath());
+ FSEntry real_image(_imp->params[k::image()].realpath());
FSEntry dst(src.readlink());
std::string fixed_dst(stringify(dst.strip_leading(real_image)));
@@ -787,10 +809,10 @@ Merger::record_renamed_dir_recursive(const FSEntry & dst)
{
for (DirIterator d(dst, DirIteratorOptions() + dio_include_dotfiles + dio_inode_sort), d_end ; d != d_end ; ++d)
{
- if (! _params[k::no_chown()])
+ if (! _imp->params[k::no_chown()])
{
- uid_t new_uid(d->owner() == _params[k::environment()]->reduced_uid() ? 0 : -1);
- gid_t new_gid(d->group() == _params[k::environment()]->reduced_gid() ? 0 : -1);
+ uid_t new_uid(d->owner() == _imp->params[k::environment()]->reduced_uid() ? 0 : -1);
+ gid_t new_gid(d->group() == _imp->params[k::environment()]->reduced_gid() ? 0 : -1);
if (uid_t(-1) != new_uid || gid_t(-1) != new_gid)
{
FSEntry f(*d);
@@ -814,12 +836,12 @@ Merger::record_renamed_dir_recursive(const FSEntry & dst)
case et_sym:
rewrite_symlink_as_needed(*d, dst);
record_install_sym(*d, dst, MergeStatusFlags() + msi_parent_rename);
- _merged_ids.insert(make_pair(d->lowlevel_id(), stringify(*d)));
+ _imp->merged_ids.insert(make_pair(d->lowlevel_id(), stringify(*d)));
continue;
case et_file:
record_install_file(*d, dst, stringify(d->basename()), MergeStatusFlags() + msi_parent_rename);
- _merged_ids.insert(make_pair(d->lowlevel_id(), stringify(*d)));
+ _imp->merged_ids.insert(make_pair(d->lowlevel_id(), stringify(*d)));
continue;
case et_dir:
@@ -846,7 +868,7 @@ Merger::relabel_dir_recursive(const FSEntry & src, const FSEntry & dst)
for (DirIterator d(src, DirIteratorOptions() + dio_include_dotfiles + dio_inode_sort), d_end ; d != d_end ; ++d)
{
mode_t mode(d->permissions());
- tr1::shared_ptr<const SecurityContext> secctx(
+ std::tr1::shared_ptr<const SecurityContext> secctx(
MatchPathCon::get_instance()->match(stringify(dst / d->basename()), mode));
if (0 != paludis::setfilecon(*d, secctx))
throw MergerError("Could not set SELinux context on '"
@@ -863,7 +885,7 @@ Merger::install_dir(const FSEntry & src, const FSEntry & dst_dir)
MergeStatusFlags result;
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_install_dir_pre")
("INSTALL_SOURCE", stringify(src))
("INSTALL_DESTINATION", stringify(dst_dir / src.basename())))).max_exit_status)
@@ -877,10 +899,10 @@ Merger::install_dir(const FSEntry & src, const FSEntry & dst_dir)
if (0 != (mode & (S_ISVTX | S_ISUID | S_ISGID)))
result += msi_setid_bits;
- if (! _params[k::no_chown()])
+ if (! _imp->params[k::no_chown()])
{
- uid_t new_uid(dest_uid == _params[k::environment()]->reduced_uid() ? 0 : -1);
- gid_t new_gid(dest_gid == _params[k::environment()]->reduced_gid() ? 0 : -1);
+ uid_t new_uid(dest_uid == _imp->params[k::environment()]->reduced_uid() ? 0 : -1);
+ gid_t new_gid(dest_gid == _imp->params[k::environment()]->reduced_gid() ? 0 : -1);
if (uid_t(-1) != new_uid)
mode &= ~S_ISUID;
if (gid_t(-1) != new_gid)
@@ -897,7 +919,7 @@ Merger::install_dir(const FSEntry & src, const FSEntry & dst_dir)
}
FSEntry dst(dst_dir / src.basename());
- tr1::shared_ptr<const SecurityContext> secctx(MatchPathCon::get_instance()->match(stringify(dst), mode));
+ std::tr1::shared_ptr<const SecurityContext> secctx(MatchPathCon::get_instance()->match(stringify(dst), mode));
FSCreateCon createcon(secctx);
if (0 != paludis::setfilecon(src, secctx))
throw MergerError("Could not set SELinux context on '"
@@ -910,7 +932,7 @@ Merger::install_dir(const FSEntry & src, const FSEntry & dst_dir)
{
result += msi_rename;
record_renamed_dir_recursive(dst);
- _skip_dir = true;
+ _imp->skip_dir = true;
}
else
{
@@ -922,14 +944,14 @@ Merger::install_dir(const FSEntry & src, const FSEntry & dst_dir)
if (-1 == dst_fd)
throw MergerError("Could not get an FD for the directory '"
+ stringify(dst) + "' that we just created: " + stringify(::strerror(errno)));
- if (! _params[k::no_chown()])
+ if (! _imp->params[k::no_chown()])
::fchown(dst_fd, dest_uid, dest_gid);
/* pick up set*id bits */
::fchmod(dst_fd, mode);
try_to_copy_xattrs(src, dst_fd, result);
}
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_install_dir_post")
("INSTALL_SOURCE", stringify(src))
("INSTALL_DESTINATION", stringify(dst_dir / src.basename())))).max_exit_status)
@@ -948,15 +970,15 @@ Merger::install_sym(const FSEntry & src, const FSEntry & dst_dir)
FSEntry dst(dst_dir / src.basename());
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_install_sym_pre")
("INSTALL_SOURCE", stringify(src))
("INSTALL_DESTINATION", stringify(dst)))).max_exit_status)
Log::get_instance()->message("merger.sym.pre_hooks.failure", ll_warning, lc_context)
<< "Merge of '" << src << "' to '" << dst_dir << "' pre hooks returned non-zero";
- uid_t dest_uid(src.owner() == _params[k::environment()]->reduced_uid() ? 0 : src.owner());
- gid_t dest_gid(src.group() == _params[k::environment()]->reduced_gid() ? 0 : src.group());
+ uid_t dest_uid(src.owner() == _imp->params[k::environment()]->reduced_uid() ? 0 : src.owner());
+ gid_t dest_gid(src.group() == _imp->params[k::environment()]->reduced_gid() ? 0 : src.group());
if (0 != (src.permissions() & (S_ISVTX | S_ISUID | S_ISGID)))
result += msi_setid_bits;
@@ -970,7 +992,7 @@ Merger::install_sym(const FSEntry & src, const FSEntry & dst_dir)
do_sym = true;
FSCreateCon createcon(MatchPathCon::get_instance()->match(stringify(dst), S_IFLNK));
std::pair<MergedMap::const_iterator, MergedMap::const_iterator> ii(
- _merged_ids.equal_range(src.lowlevel_id()));
+ _imp->merged_ids.equal_range(src.lowlevel_id()));
for (MergedMap::const_iterator i = ii.first ; i != ii.second ; ++i)
{
if (0 == ::link(i->second.c_str(), stringify(dst).c_str()))
@@ -991,17 +1013,17 @@ Merger::install_sym(const FSEntry & src, const FSEntry & dst_dir)
if (0 != ::symlink(stringify(src.readlink()).c_str(), stringify(dst).c_str()))
throw MergerError("Couldn't create symlink at '" + stringify(dst) + "': "
+ stringify(::strerror(errno)));
- _merged_ids.insert(make_pair(src.lowlevel_id(), stringify(dst)));
+ _imp->merged_ids.insert(make_pair(src.lowlevel_id(), stringify(dst)));
}
- if (! _params[k::no_chown()])
+ if (! _imp->params[k::no_chown()])
{
if (src.owner() != dest_uid || src.group() != dest_gid)
result += msi_fixed_ownership;
dst.lchown(dest_uid, dest_gid);
}
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_install_sym_post")
("INSTALL_SOURCE", stringify(src))
("INSTALL_DESTINATION", stringify(dst)))).max_exit_status)
@@ -1014,7 +1036,7 @@ Merger::install_sym(const FSEntry & src, const FSEntry & dst_dir)
void
Merger::unlink_file(FSEntry d)
{
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_unlink_file_pre")
("UNLINK_TARGET", stringify(d)))).max_exit_status)
Log::get_instance()->message("merger.unlink_file.pre_hooks.failure", ll_warning, lc_context) <<
@@ -1032,7 +1054,7 @@ Merger::unlink_file(FSEntry d)
d.unlink();
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_unlink_file_post")
("UNLINK_TARGET", stringify(d)))).max_exit_status)
Log::get_instance()->message("merger.unlink_file.post_hooks.failure", ll_warning, lc_context) <<
@@ -1042,7 +1064,7 @@ Merger::unlink_file(FSEntry d)
void
Merger::unlink_sym(FSEntry d)
{
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_unlink_sym_pre")
("UNLINK_TARGET", stringify(d)))).max_exit_status)
Log::get_instance()->message("merger.unlink_sym.pre_hooks.failure", ll_warning, lc_context) <<
@@ -1050,7 +1072,7 @@ Merger::unlink_sym(FSEntry d)
d.unlink();
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_unlink_sym_post")
("UNLINK_TARGET", stringify(d)))).max_exit_status)
Log::get_instance()->message("merger.unlink_sym.post_hooks.failure", ll_warning, lc_context) <<
@@ -1060,7 +1082,7 @@ Merger::unlink_sym(FSEntry d)
void
Merger::unlink_dir(FSEntry d)
{
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_unlink_dir_pre")
("UNLINK_TARGET", stringify(d)))).max_exit_status)
Log::get_instance()->message("merger.unlink_dir.pre_hooks.failure", ll_warning, lc_context) <<
@@ -1068,7 +1090,7 @@ Merger::unlink_dir(FSEntry d)
d.rmdir();
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_unlink_dir_post")
("UNLINK_TARGET", stringify(d)))).max_exit_status)
Log::get_instance()->message("merger.unlink_dir.post_hooks.failure", ll_warning, lc_context) <<
@@ -1078,7 +1100,7 @@ Merger::unlink_dir(FSEntry d)
void
Merger::unlink_misc(FSEntry d)
{
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_unlink_misc_pre")
("UNLINK_TARGET", stringify(d)))).max_exit_status)
Log::get_instance()->message("merger.unlink_misc.pre_hooks.failure", ll_warning, lc_context) <<
@@ -1086,7 +1108,7 @@ Merger::unlink_misc(FSEntry d)
d.unlink();
- if (0 != _params[k::environment()]->perform_hook(extend_hook(
+ if (0 != _imp->params[k::environment()]->perform_hook(extend_hook(
Hook("merger_unlink_misc_post")
("UNLINK_TARGET", stringify(d)))).max_exit_status)
Log::get_instance()->message("merger.unlink_misc.post_hooks.failure", ll_warning, lc_context) <<
@@ -1097,8 +1119,8 @@ Hook
Merger::extend_hook(const Hook & h)
{
return h
- ("ROOT", stringify(_params[k::root()]))
- ("IMAGE", stringify(_params[k::image()]));
+ ("ROOT", stringify(_imp->params[k::root()]))
+ ("IMAGE", stringify(_imp->params[k::image()]));
}
#ifdef HAVE_XATTRS
@@ -1117,7 +1139,7 @@ Merger::try_to_copy_xattrs(const FSEntry & src, int dst_fd, MergeStatusFlags & f
return;
}
- tr1::shared_ptr<char> list_holder(static_cast<char *>(::operator new(list_sz)));
+ std::tr1::shared_ptr<char> list_holder(static_cast<char *>(::operator new(list_sz)));
list_sz = flistxattr(src_fd, list_holder.get(), list_sz);
if (-1 == list_sz)
{
@@ -1140,7 +1162,7 @@ Merger::try_to_copy_xattrs(const FSEntry & src, int dst_fd, MergeStatusFlags & f
break;
}
- tr1::shared_ptr<char> value_holder(static_cast<char *>(::operator new(value_sz)));
+ std::tr1::shared_ptr<char> value_holder(static_cast<char *>(::operator new(value_sz)));
value_sz = fgetxattr(src_fd, key.c_str(), value_holder.get(), value_sz);
if (-1 == value_sz)
{
diff --git a/paludis/merger.hh b/paludis/merger.hh
index 808b189..79c7a03 100644
--- a/paludis/merger.hh
+++ b/paludis/merger.hh
@@ -29,7 +29,6 @@
#include <iosfwd>
#include <sys/stat.h>
#include <sys/types.h>
-#include <paludis/hashed_containers.hh>
/** \file
* Declarations for the Merger class, which can be used by Repository
@@ -73,14 +72,10 @@ namespace paludis
* \ingroup g_repository
* \nosubgrouping
*/
- class PALUDIS_VISIBLE Merger
+ class PALUDIS_VISIBLE Merger :
+ private PrivateImplementationPattern<Merger>
{
private:
- typedef MakeHashedMultiMap<std::pair<dev_t, ino_t>, std::string>::Type MergedMap;
- MergedMap _merged_ids;
- MergerParams _params;
- bool _result;
- bool _skip_dir;
void record_renamed_dir_recursive(const FSEntry &);
void relabel_dir_recursive(const FSEntry &, const FSEntry &);
void rewrite_symlink_as_needed(const FSEntry &, const FSEntry &);
diff --git a/paludis/merger_TEST.cc b/paludis/merger_TEST.cc
index 8ca6b68..e1d1c64 100644
--- a/paludis/merger_TEST.cc
+++ b/paludis/merger_TEST.cc
@@ -38,7 +38,7 @@ namespace paludis
public TestEnvironment
{
private:
- mutable tr1::shared_ptr<Hooker> hooker;
+ mutable std::tr1::shared_ptr<Hooker> hooker;
mutable std::list<std::pair<FSEntry, bool> > hook_dirs;
public:
diff --git a/paludis/metadata_key.cc b/paludis/metadata_key.cc
index 92f7be1..b114609 100644
--- a/paludis/metadata_key.cc
+++ b/paludis/metadata_key.cc
@@ -24,9 +24,9 @@
#include <paludis/util/stringify.hh>
#include <paludis/util/set.hh>
#include <paludis/util/sequence.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/indirect_iterator-impl.hh>
#include <paludis/name.hh>
+#include <tr1/functional>
#include <list>
#include <algorithm>
@@ -113,7 +113,7 @@ ExtraMetadataValueKeyMethods<bool>::~ExtraMetadataValueKeyMethods()
{
}
-ExtraMetadataValueKeyMethods<tr1::shared_ptr<const PackageID> >::~ExtraMetadataValueKeyMethods()
+ExtraMetadataValueKeyMethods<std::tr1::shared_ptr<const PackageID> >::~ExtraMetadataValueKeyMethods()
{
}
@@ -160,7 +160,7 @@ template class MetadataValueKey<std::string>;
template class MetadataValueKey<long>;
template class MetadataValueKey<bool>;
template class MetadataValueKey<FSEntry>;
-template class MetadataValueKey<tr1::shared_ptr<const PackageID> >;
-template class MetadataValueKey<tr1::shared_ptr<const Contents> >;
-template class MetadataValueKey<tr1::shared_ptr<const RepositoryMaskInfo> >;
+template class MetadataValueKey<std::tr1::shared_ptr<const PackageID> >;
+template class MetadataValueKey<std::tr1::shared_ptr<const Contents> >;
+template class MetadataValueKey<std::tr1::shared_ptr<const RepositoryMaskInfo> >;
diff --git a/paludis/metadata_key.hh b/paludis/metadata_key.hh
index 724d228..67df1a6 100644
--- a/paludis/metadata_key.hh
+++ b/paludis/metadata_key.hh
@@ -36,7 +36,7 @@
#include <paludis/util/private_implementation_pattern.hh>
#include <paludis/util/visitor.hh>
#include <paludis/util/remove_shared_ptr.hh>
-#include <paludis/util/tr1_type_traits.hh>
+#include <tr1/type_traits>
#include <string>
/** \file
@@ -78,9 +78,9 @@ namespace paludis
MetadataValueKey<long>,
MetadataValueKey<bool>,
MetadataValueKey<FSEntry>,
- MetadataValueKey<tr1::shared_ptr<const PackageID> >,
- MetadataValueKey<tr1::shared_ptr<const Contents> >,
- MetadataValueKey<tr1::shared_ptr<const RepositoryMaskInfo> >,
+ MetadataValueKey<std::tr1::shared_ptr<const PackageID> >,
+ MetadataValueKey<std::tr1::shared_ptr<const Contents> >,
+ MetadataValueKey<std::tr1::shared_ptr<const RepositoryMaskInfo> >,
MetadataTimeKey,
MetadataSectionKey
>
@@ -235,7 +235,7 @@ namespace paludis
* \since 0.26
*/
template <>
- class PALUDIS_VISIBLE ExtraMetadataValueKeyMethods<tr1::shared_ptr<const PackageID> >
+ class PALUDIS_VISIBLE ExtraMetadataValueKeyMethods<std::tr1::shared_ptr<const PackageID> >
{
public:
virtual ~ExtraMetadataValueKeyMethods() = 0;
@@ -330,7 +330,7 @@ namespace paludis
/**
* Fetch our value.
*/
- virtual const tr1::shared_ptr<const C_> value() const
+ virtual const std::tr1::shared_ptr<const C_> value() const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
/**
@@ -338,7 +338,7 @@ namespace paludis
* supplied Formatter to format individual items.
*/
virtual std::string pretty_print_flat(const Formatter<
- typename tr1::remove_const<typename RemoveSharedPtr<typename C_::value_type>::Type>::type> &) const
+ typename std::tr1::remove_const<typename RemoveSharedPtr<typename C_::value_type>::Type>::type> &) const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
};
@@ -370,7 +370,7 @@ namespace paludis
/**
* Fetch our value.
*/
- virtual const tr1::shared_ptr<const IUseFlagSet> value() const
+ virtual const std::tr1::shared_ptr<const IUseFlagSet> value() const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
/**
@@ -388,7 +388,7 @@ namespace paludis
*/
virtual std::string pretty_print_flat_with_comparison(
const Environment * const,
- const tr1::shared_ptr<const PackageID> &,
+ const std::tr1::shared_ptr<const PackageID> &,
const Formatter<IUseFlag> &
) const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
@@ -419,7 +419,7 @@ namespace paludis
/**
* Fetch our value.
*/
- virtual const tr1::shared_ptr<const typename C_::ConstItem> value() const
+ virtual const std::tr1::shared_ptr<const typename C_::ConstItem> value() const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
/**
@@ -465,7 +465,7 @@ namespace paludis
/**
* Fetch our value.
*/
- virtual const tr1::shared_ptr<const FetchableURISpecTree::ConstItem> value() const
+ virtual const std::tr1::shared_ptr<const FetchableURISpecTree::ConstItem> value() const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
/**
@@ -486,7 +486,7 @@ namespace paludis
* Return a URILabel that represents the initial label to use when
* deciding the behaviour of individual items in the heirarchy.
*/
- virtual const tr1::shared_ptr<const URILabel> initial_label() const
+ virtual const std::tr1::shared_ptr<const URILabel> initial_label() const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
};
@@ -518,7 +518,7 @@ namespace paludis
/**
* Fetch our value.
*/
- virtual const tr1::shared_ptr<const DependencySpecTree::ConstItem> value() const
+ virtual const std::tr1::shared_ptr<const DependencySpecTree::ConstItem> value() const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
/**
@@ -539,7 +539,7 @@ namespace paludis
* Return a DependencyLabelSequence that represents the initial labels to use when
* deciding the behaviour of individual items in the heirarchy.
*/
- virtual const tr1::shared_ptr<const DependencyLabelSequence> initial_labels() const
+ virtual const std::tr1::shared_ptr<const DependencyLabelSequence> initial_labels() const
PALUDIS_ATTRIBUTE((warn_unused_result)) = 0;
};
}
diff --git a/paludis/metadata_key_holder.cc b/paludis/metadata_key_holder.cc
index 77086c0..fd72c40 100644
--- a/paludis/metadata_key_holder.cc
+++ b/paludis/metadata_key_holder.cc
@@ -19,12 +19,12 @@
#include <paludis/metadata_key_holder.hh>
#include <paludis/util/indirect_iterator-impl.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/wrapped_forward_iterator-impl.hh>
#include <paludis/util/stringify.hh>
#include <paludis/util/exception.hh>
#include <paludis/util/private_implementation_pattern-impl.hh>
#include <paludis/metadata_key.hh>
+#include <tr1/functional>
#include <list>
#include <algorithm>
@@ -35,7 +35,7 @@ namespace paludis
template <>
struct Implementation<MetadataKeyHolder>
{
- mutable std::list<tr1::shared_ptr<const MetadataKey> > keys;
+ mutable std::list<std::tr1::shared_ptr<const MetadataKey> > keys;
};
}
@@ -49,12 +49,12 @@ MetadataKeyHolder::~MetadataKeyHolder()
}
void
-MetadataKeyHolder::add_metadata_key(const tr1::shared_ptr<const MetadataKey> & k) const
+MetadataKeyHolder::add_metadata_key(const std::tr1::shared_ptr<const MetadataKey> & k) const
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
if (indirect_iterator(_imp->keys.end()) != std::find_if(indirect_iterator(_imp->keys.begin()), indirect_iterator(_imp->keys.end()),
- tr1::bind(std::equal_to<std::string>(), k->raw_name(), tr1::bind(tr1::mem_fn(&MetadataKey::raw_name), _1))))
+ std::tr1::bind(std::equal_to<std::string>(), k->raw_name(), std::tr1::bind(std::tr1::mem_fn(&MetadataKey::raw_name), _1))))
throw ConfigurationError("Tried to add duplicate key '" + k->raw_name() + "'");
_imp->keys.push_back(k);
@@ -77,13 +77,13 @@ MetadataKeyHolder::end_metadata() const
MetadataKeyHolder::MetadataConstIterator
MetadataKeyHolder::find_metadata(const std::string & s) const
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
need_keys_added();
- // tr1::mem_fn on a sptr doesn't work with boost
+ // std::tr1::mem_fn on a sptr doesn't work with boost
// return std::find_if(begin_metadata(), end_metadata(),
- // tr1::bind(std::equal_to<std::string>(), s, tr1::bind(tr1::mem_fn(&MetadataKey::raw_name), _1)));
+ // std::tr1::bind(std::equal_to<std::string>(), s, std::tr1::bind(std::tr1::mem_fn(&MetadataKey::raw_name), _1)));
for (MetadataConstIterator i(begin_metadata()), i_end(end_metadata()) ;
i != i_end ; ++i)
diff --git a/paludis/metadata_key_holder.hh b/paludis/metadata_key_holder.hh
index 2128e97..a3e6172 100644
--- a/paludis/metadata_key_holder.hh
+++ b/paludis/metadata_key_holder.hh
@@ -23,8 +23,8 @@
#include <paludis/metadata_key_holder-fwd.hh>
#include <paludis/util/private_implementation_pattern.hh>
#include <paludis/util/wrapped_forward_iterator-fwd.hh>
-#include <paludis/util/tr1_memory.hh>
#include <paludis/metadata_key-fwd.hh>
+#include <tr1/memory>
namespace paludis
{
@@ -43,7 +43,7 @@ namespace paludis
* Add a new MetadataKey, which must not use the same raw name as
* any previous MetadataKey added to this ID.
*/
- virtual void add_metadata_key(const tr1::shared_ptr<const MetadataKey> &) const;
+ virtual void add_metadata_key(const std::tr1::shared_ptr<const MetadataKey> &) const;
/**
* Clear all MetadataKey instances added using add_metadata_key.
@@ -65,7 +65,7 @@ namespace paludis
///\{
struct MetadataConstIteratorTag;
- typedef WrappedForwardIterator<MetadataConstIteratorTag, tr1::shared_ptr<const MetadataKey> > MetadataConstIterator;
+ typedef WrappedForwardIterator<MetadataConstIteratorTag, std::tr1::shared_ptr<const MetadataKey> > MetadataConstIterator;
MetadataConstIterator begin_metadata() const PALUDIS_ATTRIBUTE((warn_unused_result));
MetadataConstIterator end_metadata() const PALUDIS_ATTRIBUTE((warn_unused_result));
diff --git a/paludis/name.cc b/paludis/name.cc
index 1aaa50e..3ae62f3 100644
--- a/paludis/name.cc
+++ b/paludis/name.cc
@@ -26,6 +26,7 @@
#include <paludis/util/wrapped_forward_iterator-impl.hh>
#include <paludis/util/wrapped_output_iterator-impl.hh>
#include <paludis/util/options.hh>
+#include <paludis/util/hashes.hh>
#include <ostream>
#include <utility>
@@ -492,3 +493,9 @@ paludis::operator<< (std::ostream & s, const IUseFlag & i)
return s;
}
+std::size_t
+QualifiedPackageName::hash() const
+{
+ return Hash<std::string>()(stringify(*this));
+}
+
diff --git a/paludis/name.sr b/paludis/name.sr
index b1dea93..88604ef 100644
--- a/paludis/name.sr
+++ b/paludis/name.sr
@@ -14,6 +14,10 @@ make_class_QualifiedPackageName()
explicit QualifiedPackageName(const std::string &);
END
+ extra_methods <<END
+ std::size_t hash() const PALUDIS_ATTRIBUTE((warn_unused_result));
+END
+
doxygen_comment << "END"
/**
* Represents a category plus package name.
diff --git a/paludis/ndbam-fwd.hh b/paludis/ndbam-fwd.hh
index c31accc..1fe2435 100644
--- a/paludis/ndbam-fwd.hh
+++ b/paludis/ndbam-fwd.hh
@@ -39,11 +39,11 @@ namespace paludis
kc::Field<k::slot, SlotName>,
kc::Field<k::fs_location, FSEntry>,
kc::Field<k::magic, std::string>,
- kc::Field<k::package_id, tr1::shared_ptr<PackageID> >,
- kc::Field<k::mutex, tr1::shared_ptr<Mutex> >
+ kc::Field<k::package_id, std::tr1::shared_ptr<PackageID> >,
+ kc::Field<k::mutex, std::tr1::shared_ptr<Mutex> >
> NDBAMEntry;
- typedef Sequence<tr1::shared_ptr<NDBAMEntry> > NDBAMEntrySequence;
+ typedef Sequence<std::tr1::shared_ptr<NDBAMEntry> > NDBAMEntrySequence;
}
#endif
diff --git a/paludis/ndbam.cc b/paludis/ndbam.cc
index f801b24..5578b3e 100644
--- a/paludis/ndbam.cc
+++ b/paludis/ndbam.cc
@@ -26,14 +26,15 @@
#include <paludis/util/options.hh>
#include <paludis/util/log.hh>
#include <paludis/util/make_shared_ptr.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/config_file.hh>
#include <paludis/util/kc.hh>
+#include <paludis/util/hashes.hh>
#include <paludis/ndbam.hh>
-#include <paludis/hashed_containers.hh>
#include <paludis/package_id.hh>
#include <paludis/metadata_key.hh>
#include <paludis/name.hh>
+#include <tr1/functional>
+#include <tr1/unordered_map>
#include <functional>
#include <vector>
#include <map>
@@ -41,7 +42,7 @@
using namespace paludis;
-template class Sequence<tr1::shared_ptr<NDBAMEntry> >;
+template class Sequence<std::tr1::shared_ptr<NDBAMEntry> >;
namespace
{
@@ -50,29 +51,29 @@ namespace
struct CategoryNamesContainingPackageEntry;
}
-typedef MakeHashedMap<CategoryNamePart, tr1::shared_ptr<CategoryContents> >::Type CategoryContentsMap;
-typedef MakeHashedMap<QualifiedPackageName, tr1::shared_ptr<PackageContents> >::Type PackageContentsMap;
-typedef MakeHashedMap<PackageNamePart, tr1::shared_ptr<CategoryNamesContainingPackageEntry> >::Type CategoryNamesContainingPackage;
+typedef std::tr1::unordered_map<CategoryNamePart, std::tr1::shared_ptr<CategoryContents>, Hash<CategoryNamePart> > CategoryContentsMap;
+typedef std::tr1::unordered_map<QualifiedPackageName, std::tr1::shared_ptr<PackageContents>, Hash<QualifiedPackageName> > PackageContentsMap;
+typedef std::tr1::unordered_map<PackageNamePart, std::tr1::shared_ptr<CategoryNamesContainingPackageEntry>, Hash<PackageNamePart> > CategoryNamesContainingPackage;
namespace
{
struct CategoryContents
{
Mutex mutex;
- tr1::shared_ptr<QualifiedPackageNameSet> package_names;
+ std::tr1::shared_ptr<QualifiedPackageNameSet> package_names;
PackageContentsMap package_contents_map;
};
struct PackageContents
{
Mutex mutex;
- tr1::shared_ptr<NDBAMEntrySequence> entries;
+ std::tr1::shared_ptr<NDBAMEntrySequence> entries;
};
struct CategoryNamesContainingPackageEntry
{
Mutex mutex;
- tr1::shared_ptr<CategoryNamePartSet> category_names_containing_package;
+ std::tr1::shared_ptr<CategoryNamePartSet> category_names_containing_package;
};
}
@@ -85,7 +86,7 @@ namespace paludis
const FSEntry location;
mutable Mutex category_names_mutex;
- mutable tr1::shared_ptr<CategoryNamePartSet> category_names;
+ mutable std::tr1::shared_ptr<CategoryNamePartSet> category_names;
mutable CategoryContentsMap category_contents_map;
mutable Mutex category_names_containing_package_mutex;
@@ -99,7 +100,7 @@ namespace paludis
}
NDBAM::NDBAM(const FSEntry & l,
- const tr1::function<bool (const std::string &)> & check_format,
+ const std::tr1::function<bool (const std::string &)> & check_format,
const std::string & preferred_format) :
PrivateImplementationPattern<NDBAM>(new Implementation<NDBAM>(l))
{
@@ -135,7 +136,7 @@ NDBAM::~NDBAM()
{
}
-tr1::shared_ptr<const CategoryNamePartSet>
+std::tr1::shared_ptr<const CategoryNamePartSet>
NDBAM::category_names()
{
Lock l(_imp->category_names_mutex);
@@ -170,7 +171,7 @@ NDBAM::category_names()
return _imp->category_names;
}
-tr1::shared_ptr<const QualifiedPackageNameSet>
+std::tr1::shared_ptr<const QualifiedPackageNameSet>
NDBAM::package_names(const CategoryNamePart & c)
{
if (! has_category_named(c))
@@ -229,7 +230,7 @@ NDBAM::has_category_named(const CategoryNamePart & c)
_imp->category_contents_map.insert(std::make_pair(c, new CategoryContents));
return true;
}
- _imp->category_contents_map.insert(std::make_pair(c, tr1::shared_ptr<CategoryContents>()));
+ _imp->category_contents_map.insert(std::make_pair(c, std::tr1::shared_ptr<CategoryContents>()));
}
return false;
@@ -260,7 +261,7 @@ NDBAM::has_package_named(const QualifiedPackageName & q)
cc.package_contents_map.insert(std::make_pair(q, new PackageContents));
return true;
}
- cc.package_contents_map.insert(std::make_pair(q, tr1::shared_ptr<PackageContents>()));
+ cc.package_contents_map.insert(std::make_pair(q, std::tr1::shared_ptr<PackageContents>()));
}
return false;
@@ -270,14 +271,14 @@ namespace
{
struct NDBAMEntryVersionComparator
{
- bool operator() (const tr1::shared_ptr<const NDBAMEntry> & a, const tr1::shared_ptr<const NDBAMEntry> & b) const
+ bool operator() (const std::tr1::shared_ptr<const NDBAMEntry> & a, const std::tr1::shared_ptr<const NDBAMEntry> & b) const
{
return (*a)[k::version()] < (*b)[k::version()];
}
};
}
-tr1::shared_ptr<NDBAMEntrySequence>
+std::tr1::shared_ptr<NDBAMEntrySequence>
NDBAM::entries(const QualifiedPackageName & q)
{
if (! has_package_named(q))
@@ -328,7 +329,7 @@ NDBAM::entries(const QualifiedPackageName & q)
(k::version(), v)
(k::slot(), s)
(k::fs_location(), d->realpath())
- (k::package_id(), tr1::shared_ptr<PackageID>())
+ (k::package_id(), std::tr1::shared_ptr<PackageID>())
(k::magic(), m)
(k::mutex(), make_shared_ptr(new Mutex)))));
}
@@ -343,7 +344,7 @@ NDBAM::entries(const QualifiedPackageName & q)
}
}
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
pc.entries->sort(NDBAMEntryVersionComparator());
}
@@ -352,9 +353,9 @@ NDBAM::entries(const QualifiedPackageName & q)
void
NDBAM::parse_contents(const PackageID & id,
- const tr1::function<void (const FSEntry &, const std::string & md5, const time_t mtime)> & on_file,
- const tr1::function<void (const FSEntry &)> & on_dir,
- const tr1::function<void (const FSEntry &, const std::string & target, const time_t mtime)> & on_sym
+ const std::tr1::function<void (const FSEntry &, const std::string & md5, const time_t mtime)> & on_file,
+ const std::tr1::function<void (const FSEntry &)> & on_dir,
+ const std::tr1::function<void (const FSEntry &, const std::string & target, const time_t mtime)> & on_sym
) const
{
Context c("When fetching contents for '" + stringify(id) + "':");
@@ -502,7 +503,7 @@ NDBAM::parse_contents(const PackageID & id,
}
}
-tr1::shared_ptr<const CategoryNamePartSet>
+std::tr1::shared_ptr<const CategoryNamePartSet>
NDBAM::category_names_containing_package(const PackageNamePart & p) const
{
Lock l(_imp->category_names_containing_package_mutex);
diff --git a/paludis/ndbam.hh b/paludis/ndbam.hh
index 775e927..05b73e8 100644
--- a/paludis/ndbam.hh
+++ b/paludis/ndbam.hh
@@ -26,11 +26,11 @@
#include <paludis/util/fs_entry.hh>
#include <paludis/util/sequence-fwd.hh>
#include <paludis/util/mutex.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/name.hh>
#include <paludis/version_spec.hh>
#include <paludis/package_id-fwd.hh>
#include <paludis/contents-fwd.hh>
+#include <tr1/functional>
namespace paludis
{
@@ -51,7 +51,7 @@ namespace paludis
///\{
NDBAM(const FSEntry &,
- const tr1::function<bool (const std::string &)> & check_format,
+ const std::tr1::function<bool (const std::string &)> & check_format,
const std::string & preferred_format);
~NDBAM();
@@ -60,14 +60,14 @@ namespace paludis
///\name Repository method implementations
///\{
- tr1::shared_ptr<const CategoryNamePartSet> category_names()
+ std::tr1::shared_ptr<const CategoryNamePartSet> category_names()
PALUDIS_ATTRIBUTE((warn_unused_result));
- tr1::shared_ptr<const QualifiedPackageNameSet> package_names(
+ std::tr1::shared_ptr<const QualifiedPackageNameSet> package_names(
const CategoryNamePart & c)
PALUDIS_ATTRIBUTE((warn_unused_result));
- tr1::shared_ptr<const CategoryNamePartSet> category_names_containing_package(
+ std::tr1::shared_ptr<const CategoryNamePartSet> category_names_containing_package(
const PackageNamePart &) const
PALUDIS_ATTRIBUTE((warn_unused_result));
@@ -77,7 +77,7 @@ namespace paludis
bool has_category_named(const CategoryNamePart &)
PALUDIS_ATTRIBUTE((warn_unused_result));
- tr1::shared_ptr<NDBAMEntrySequence> entries(const QualifiedPackageName &)
+ std::tr1::shared_ptr<NDBAMEntrySequence> entries(const QualifiedPackageName &)
PALUDIS_ATTRIBUTE((warn_unused_result));
///\}
@@ -86,9 +86,9 @@ namespace paludis
* Parse the contents file for a given ID, using the provided callbacks.
*/
void parse_contents(const PackageID &,
- const tr1::function<void (const FSEntry &, const std::string & md5, const time_t mtime)> & on_file,
- const tr1::function<void (const FSEntry &)> & on_dir,
- const tr1::function<void (const FSEntry &, const std::string & target, const time_t mtime)> & on_sym
+ const std::tr1::function<void (const FSEntry &, const std::string & md5, const time_t mtime)> & on_file,
+ const std::tr1::function<void (const FSEntry &)> & on_dir,
+ const std::tr1::function<void (const FSEntry &, const std::string & target, const time_t mtime)> & on_sym
) const;
/**
diff --git a/paludis/ndbam_merger.cc b/paludis/ndbam_merger.cc
index b3b59f0..cf2b23f 100644
--- a/paludis/ndbam_merger.cc
+++ b/paludis/ndbam_merger.cc
@@ -47,7 +47,7 @@ namespace paludis
{
NDBAMMergerParams params;
FSEntry realroot;
- tr1::shared_ptr<std::ofstream> contents_file;
+ std::tr1::shared_ptr<std::ofstream> contents_file;
std::list<std::string> config_protect;
std::list<std::string> config_protect_mask;
@@ -70,7 +70,8 @@ NDBAMMerger::NDBAMMerger(const NDBAMMergerParams & p) :
(k::no_chown(), ! getenv_with_default("PALUDIS_NO_CHOWN", "").empty())
(k::install_under(), p[k::install_under()])
(k::options(), p[k::options()])),
- PrivateImplementationPattern<NDBAMMerger>(new Implementation<NDBAMMerger>(p))
+ PrivateImplementationPattern<NDBAMMerger>(new Implementation<NDBAMMerger>(p)),
+ _imp(PrivateImplementationPattern<NDBAMMerger>::_imp)
{
}
@@ -81,7 +82,7 @@ NDBAMMerger::~NDBAMMerger()
Hook
NDBAMMerger::extend_hook(const Hook & h)
{
- tr1::shared_ptr<const FSEntrySequence> bashrc_files(_imp->params[k::environment()]->bashrc_files());
+ std::tr1::shared_ptr<const FSEntrySequence> bashrc_files(_imp->params[k::environment()]->bashrc_files());
if (_imp->params[k::package_id()])
{
diff --git a/paludis/ndbam_merger.hh b/paludis/ndbam_merger.hh
index 5f8e3d0..911267c 100644
--- a/paludis/ndbam_merger.hh
+++ b/paludis/ndbam_merger.hh
@@ -35,7 +35,7 @@ namespace paludis
kc::Field<k::contents_file, FSEntry>,
kc::Field<k::config_protect, std::string>,
kc::Field<k::config_protect_mask, std::string>,
- kc::Field<k::package_id, tr1::shared_ptr<const PackageID> >,
+ kc::Field<k::package_id, std::tr1::shared_ptr<const PackageID> >,
kc::Field<k::options, MergerOptions>
> NDBAMMergerParams;
@@ -53,6 +53,8 @@ namespace paludis
void display_override(const std::string &) const;
std::string make_arrows(const MergeStatusFlags &) const;
+ PrivateImplementationPattern<NDBAMMerger>::ImpPtr & _imp;
+
public:
NDBAMMerger(const NDBAMMergerParams &);
~NDBAMMerger();
diff --git a/paludis/ndbam_unmerger.cc b/paludis/ndbam_unmerger.cc
index dbaa00e..9eac2fa 100644
--- a/paludis/ndbam_unmerger.cc
+++ b/paludis/ndbam_unmerger.cc
@@ -33,11 +33,10 @@
#include <paludis/util/private_implementation_pattern-impl.hh>
#include <paludis/util/sequence.hh>
#include <paludis/util/tokeniser.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/make_shared_ptr.hh>
#include <paludis/util/strip.hh>
#include <paludis/util/wrapped_forward_iterator.hh>
-
+#include <tr1/functional>
#include <list>
#include <map>
#include <vector>
@@ -117,7 +116,7 @@ NDBAMUnmerger::~NDBAMUnmerger()
Hook
NDBAMUnmerger::extend_hook(const Hook & h) const
{
- tr1::shared_ptr<const FSEntrySequence> bashrc_files(_imp->options[k::environment()]->bashrc_files());
+ std::tr1::shared_ptr<const FSEntrySequence> bashrc_files(_imp->options[k::environment()]->bashrc_files());
Hook result(Unmerger::extend_hook(h)
("CONFIG_PROTECT", _imp->options[k::config_protect()])
@@ -190,7 +189,7 @@ NDBAMUnmerger::_add_file(const FSEntry & f, const std::string & md5, const time_
void
NDBAMUnmerger::_add_dir(const FSEntry & f)
{
- add_unmerge_entry(stringify(f), et_dir, tr1::shared_ptr<ExtraInfo>());
+ add_unmerge_entry(stringify(f), et_dir, std::tr1::shared_ptr<ExtraInfo>());
}
void
@@ -202,18 +201,18 @@ NDBAMUnmerger::_add_sym(const FSEntry & f, const std::string & target, const tim
void
NDBAMUnmerger::populate_unmerge_set()
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
_imp->options[k::ndbam()]->parse_contents(*_imp->options[k::package_id()],
- tr1::bind(&NDBAMUnmerger::_add_file, this, _1, _2, _3),
- tr1::bind(&NDBAMUnmerger::_add_dir, this, _1),
- tr1::bind(&NDBAMUnmerger::_add_sym, this, _1, _2, _3)
+ std::tr1::bind(&NDBAMUnmerger::_add_file, this, _1, _2, _3),
+ std::tr1::bind(&NDBAMUnmerger::_add_dir, this, _1),
+ std::tr1::bind(&NDBAMUnmerger::_add_sym, this, _1, _2, _3)
);
}
bool
-NDBAMUnmerger::check_file(const FSEntry & f, tr1::shared_ptr<ExtraInfo> ei) const
+NDBAMUnmerger::check_file(const FSEntry & f, std::tr1::shared_ptr<ExtraInfo> ei) const
{
- tr1::shared_ptr<FileExtraInfo> fie(tr1::static_pointer_cast<FileExtraInfo>(ei));
+ std::tr1::shared_ptr<FileExtraInfo> fie(std::tr1::static_pointer_cast<FileExtraInfo>(ei));
if (! (_imp->options[k::root()] / f).is_regular_file())
display("--- [!type] " + stringify(f));
@@ -240,9 +239,9 @@ NDBAMUnmerger::check_file(const FSEntry & f, tr1::shared_ptr<ExtraInfo> ei) cons
}
bool
-NDBAMUnmerger::check_sym(const FSEntry & f, tr1::shared_ptr<ExtraInfo> ei) const
+NDBAMUnmerger::check_sym(const FSEntry & f, std::tr1::shared_ptr<ExtraInfo> ei) const
{
- tr1::shared_ptr<SymlinkExtraInfo> sie(tr1::static_pointer_cast<SymlinkExtraInfo>(ei));
+ std::tr1::shared_ptr<SymlinkExtraInfo> sie(std::tr1::static_pointer_cast<SymlinkExtraInfo>(ei));
if (! (_imp->options[k::root()] / f).is_symbolic_link())
display("--- [!type] " + stringify(f));
@@ -257,13 +256,13 @@ NDBAMUnmerger::check_sym(const FSEntry & f, tr1::shared_ptr<ExtraInfo> ei) const
}
bool
-NDBAMUnmerger::check_misc(const FSEntry &, tr1::shared_ptr<ExtraInfo>) const
+NDBAMUnmerger::check_misc(const FSEntry &, std::tr1::shared_ptr<ExtraInfo>) const
{
return false;
}
bool
-NDBAMUnmerger::check_dir(const FSEntry & f, tr1::shared_ptr<ExtraInfo>) const
+NDBAMUnmerger::check_dir(const FSEntry & f, std::tr1::shared_ptr<ExtraInfo>) const
{
if (! (_imp->options[k::root()] / f).is_directory())
display("--- [!type] " + stringify(f));
diff --git a/paludis/ndbam_unmerger.hh b/paludis/ndbam_unmerger.hh
index 486e891..f5f703c 100644
--- a/paludis/ndbam_unmerger.hh
+++ b/paludis/ndbam_unmerger.hh
@@ -39,7 +39,7 @@ namespace paludis
kc::Field<k::contents_file, FSEntry>,
kc::Field<k::config_protect, std::string>,
kc::Field<k::config_protect_mask, std::string>,
- kc::Field<k::package_id, tr1::shared_ptr<const PackageID> >,
+ kc::Field<k::package_id, std::tr1::shared_ptr<const PackageID> >,
kc::Field<k::ndbam, const NDBAM *>
> NDBAMUnmergerOptions;
@@ -77,10 +77,10 @@ namespace paludis
void display(const std::string &) const;
- bool check_file(const FSEntry &, tr1::shared_ptr<ExtraInfo>) const;
- bool check_dir(const FSEntry &, tr1::shared_ptr<ExtraInfo>) const;
- bool check_sym(const FSEntry &, tr1::shared_ptr<ExtraInfo>) const;
- bool check_misc(const FSEntry &, tr1::shared_ptr<ExtraInfo>) const;
+ bool check_file(const FSEntry &, std::tr1::shared_ptr<ExtraInfo>) const;
+ bool check_dir(const FSEntry &, std::tr1::shared_ptr<ExtraInfo>) const;
+ bool check_sym(const FSEntry &, std::tr1::shared_ptr<ExtraInfo>) const;
+ bool check_misc(const FSEntry &, std::tr1::shared_ptr<ExtraInfo>) const;
public:
///\name Basic operations
diff --git a/paludis/override_functions.cc b/paludis/override_functions.cc
index 7c78b83..bd8378b 100644
--- a/paludis/override_functions.cc
+++ b/paludis/override_functions.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007 Ciaran McCreesh
+ * Copyright (c) 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -43,7 +43,7 @@ paludis::override_tilde_keywords(const Environment * const e, const PackageID &
if (! k)
return false;
- tr1::shared_ptr<KeywordNameSet> kk(new KeywordNameSet);
+ std::tr1::shared_ptr<KeywordNameSet> kk(new KeywordNameSet);
for (KeywordNameSet::ConstIterator i(k->value()->begin()), i_end(k->value()->end()) ;
i != i_end ; ++i)
{
@@ -68,7 +68,7 @@ paludis::override_unkeyworded(const Environment * const e, const PackageID & id,
if (! k)
return false;
- tr1::shared_ptr<KeywordNameSet> kk(new KeywordNameSet);
+ std::tr1::shared_ptr<KeywordNameSet> kk(new KeywordNameSet);
for (KeywordNameSet::ConstIterator i(k->value()->begin()), i_end(k->value()->end()) ;
i != i_end ; ++i)
if ('-' == stringify(*i).at(0))
diff --git a/paludis/package_database.cc b/paludis/package_database.cc
index ae6f2dc..f7aed32 100644
--- a/paludis/package_database.cc
+++ b/paludis/package_database.cc
@@ -34,11 +34,10 @@
#include <paludis/util/map-impl.hh>
#include <paludis/util/sequence.hh>
#include <paludis/util/sequence-impl.hh>
-#include <paludis/util/tr1_functional.hh>
#include <paludis/util/wrapped_forward_iterator-impl.hh>
#include <paludis/util/member_iterator.hh>
#include <paludis/query.hh>
-
+#include <tr1/functional>
#include <algorithm>
#include <list>
#include <map>
@@ -47,7 +46,7 @@
using namespace paludis;
template class WrappedForwardIterator<AmbiguousPackageNameError::OptionsConstIteratorTag, const std::string>;
-template class WrappedForwardIterator<PackageDatabase::RepositoryConstIteratorTag, const tr1::shared_ptr<Repository> >;
+template class WrappedForwardIterator<PackageDatabase::RepositoryConstIteratorTag, const std::tr1::shared_ptr<Repository> >;
#include "package_database-se.cc"
@@ -73,7 +72,7 @@ NoSuchPackageError::NoSuchPackageError(const std::string & our_name) throw () :
}
NonUniqueQueryResultError::NonUniqueQueryResultError(const Query & q,
- const tr1::shared_ptr<const PackageIDSequence> & r) throw () :
+ const std::tr1::shared_ptr<const PackageIDSequence> & r) throw () :
PackageDatabaseLookupError("Query '" + stringify(q) + "' returned " +
(r->empty() ? "empty result set" : "'" + join(indirect_iterator(r->begin()), indirect_iterator(r->end()), " ")
+ "'") + " but qo_require_exactly_one was specified")
@@ -150,8 +149,8 @@ namespace paludis
template<>
struct Implementation<PackageDatabase>
{
- std::list<tr1::shared_ptr<Repository> > repositories;
- std::multimap<int, std::list<tr1::shared_ptr<Repository> >::iterator> repository_importances;
+ std::list<std::tr1::shared_ptr<Repository> > repositories;
+ std::multimap<int, std::list<std::tr1::shared_ptr<Repository> >::iterator> repository_importances;
const Environment * environment;
};
}
@@ -167,7 +166,7 @@ PackageDatabase::~PackageDatabase()
}
void
-PackageDatabase::add_repository(int i, const tr1::shared_ptr<Repository> r)
+PackageDatabase::add_repository(int i, const std::tr1::shared_ptr<Repository> r)
{
Context c("When adding a repository named '" + stringify(r->name()) + "':");
@@ -176,8 +175,8 @@ PackageDatabase::add_repository(int i, const tr1::shared_ptr<Repository> r)
if (r_c->name() == r->name())
throw DuplicateRepositoryError(stringify(r->name()));
- std::list<tr1::shared_ptr<Repository> >::iterator q(_imp->repositories.end());
- for (std::multimap<int, std::list<tr1::shared_ptr<Repository> >::iterator>::iterator
+ std::list<std::tr1::shared_ptr<Repository> >::iterator q(_imp->repositories.end());
+ for (std::multimap<int, std::list<std::tr1::shared_ptr<Repository> >::iterator>::iterator
p(_imp->repository_importances.begin()), p_end(_imp->repository_importances.end()) ;
p != p_end ; ++p)
if (p->first > i)
@@ -205,7 +204,7 @@ namespace
struct IsInstalled
{
const FSEntry _root;
- const tr1::shared_ptr<const PackageDatabase> _db;
+ const std::tr1::shared_ptr<const PackageDatabase> _db;
IsInstalled(const Environment * e) :
_root(e->root()),
@@ -228,9 +227,9 @@ namespace
typedef bool result_type;
typedef Map<const QualifiedPackageName, bool> QPNIMap;
- const tr1::shared_ptr<QPNIMap> _map;
+ const std::tr1::shared_ptr<QPNIMap> _map;
- IsImportant(const tr1::shared_ptr<QPNIMap> & m) :
+ IsImportant(const std::tr1::shared_ptr<QPNIMap> & m) :
_map(m)
{
}
@@ -254,10 +253,10 @@ PackageDatabase::fetch_unique_qualified_package_name(
// at least one repository containing the package things the
// category is important
typedef Map<const QualifiedPackageName, bool> QPNIMap;
- tr1::shared_ptr<QPNIMap> result(new QPNIMap);
+ std::tr1::shared_ptr<QPNIMap> result(new QPNIMap);
std::set<std::pair<CategoryNamePart, RepositoryName>, CategoryRepositoryNamePairComparator> checked;
- tr1::shared_ptr<const PackageIDSequence> pkgs(query(real_q, qo_whatever));
+ std::tr1::shared_ptr<const PackageIDSequence> pkgs(query(real_q, qo_whatever));
for (IndirectIterator<PackageIDSequence::ConstIterator> it(pkgs->begin()),
it_end(pkgs->end()); it_end != it; ++it)
{
@@ -266,7 +265,7 @@ PackageDatabase::fetch_unique_qualified_package_name(
if (! checked.insert(std::make_pair(it->name().category, it->repository()->name())).second)
continue;
- tr1::shared_ptr<const CategoryNamePartSet> unimportant_cats(it->repository()->unimportant_category_names());
+ std::tr1::shared_ptr<const CategoryNamePartSet> unimportant_cats(it->repository()->unimportant_category_names());
bool is_important(unimportant_cats->end() == unimportant_cats->find(it->name().category));
if (is_important)
result->erase(it->name());
@@ -277,7 +276,7 @@ PackageDatabase::fetch_unique_qualified_package_name(
throw NoSuchPackageError(stringify(p));
if (result->size() > 1)
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
std::list<QualifiedPackageName> qpns;
@@ -288,23 +287,23 @@ PackageDatabase::fetch_unique_qualified_package_name(
std::remove_copy_if(first_iterator(result->begin()), first_iterator(result->end()),
std::front_inserter(qpns),
- tr1::bind(std::logical_and<bool>(),
- tr1::bind(std::not1(is_important), _1),
- tr1::bind(std::not1(is_installed), _1)));
+ std::tr1::bind(std::logical_and<bool>(),
+ std::tr1::bind(std::not1(is_important), _1),
+ std::tr1::bind(std::not1(is_installed), _1)));
if (! qpns.empty() && next(qpns.begin()) == qpns.end())
break;
- qpns.remove_if(tr1::bind(std::logical_and<bool>(),
- tr1::bind(is_important, _1),
- tr1::bind(std::not1(is_installed), _1)));
+ qpns.remove_if(std::tr1::bind(std::logical_and<bool>(),
+ std::tr1::bind(is_important, _1),
+ std::tr1::bind(std::not1(is_installed), _1)));
if (! qpns.empty() && next(qpns.begin()) == qpns.end())
break;
- qpns.remove_if(tr1::bind(std::logical_and<bool>(),
- tr1::bind(std::not1(is_important), _1),
- tr1::bind(is_installed, _1)));
+ qpns.remove_if(std::tr1::bind(std::logical_and<bool>(),
+ std::tr1::bind(std::not1(is_important), _1),
+ std::tr1::bind(is_installed, _1)));
if (! qpns.empty() && next(qpns.begin()) == qpns.end())
break;
@@ -324,14 +323,14 @@ PackageDatabase::fetch_unique_qualified_package_name(
return result->begin()->first;
}
-const tr1::shared_ptr<const PackageIDSequence>
+const std::tr1::shared_ptr<const PackageIDSequence>
PackageDatabase::query(const Query & q, const QueryOrder query_order) const
{
- using namespace tr1::placeholders;
+ using namespace std::tr1::placeholders;
- tr1::shared_ptr<PackageIDSequence> result(new PackageIDSequence);
+ std::tr1::shared_ptr<PackageIDSequence> result(new PackageIDSequence);
- tr1::shared_ptr<RepositoryNameSequence> repos(q.repositories(*_imp->environment));
+ std::tr1::shared_ptr<RepositoryNameSequence> repos(q.repositories(*_imp->environment));
if (! repos)
{
repos.reset(new RepositoryNameSequence);
@@ -347,14 +346,14 @@ PackageDatabase::query(const Query & q, const QueryOrder query_order) const
return result;
}
- tr1::shared_ptr<CategoryNamePartSet> cats(q.categories(*_imp->environment, repos));
+ std::tr1::shared_ptr<CategoryNamePartSet> cats(q.categories(*_imp->environment, repos));
if (! cats)
{
cats.reset(new CategoryNamePartSet);
for (RepositoryNameSequence::ConstIterator r(repos->begin()), r_end(repos->end()) ;
r != r_end ; ++r)
{
- tr1::shared_ptr<const CategoryNamePartSet> local_cats(fetch_repository(*r)->category_names());
+ std::tr1::shared_ptr<const CategoryNamePartSet> local_cats(fetch_repository(*r)->category_names());
std::copy(local_cats->begin(), local_cats->end(), cats->inserter());
}
}
@@ -366,7 +365,7 @@ PackageDatabase::query(const Query & q, const QueryOrder query_order) const
return result;
}
- tr1::shared_ptr<QualifiedPackageNameSet> pkgs(q.packages(*_imp->environment, repos, cats));
+ std::tr1::shared_ptr<QualifiedPackageNameSet> pkgs(q.packages(*_imp->environment, repos, cats));
if (! pkgs)
{
pkgs.reset(new QualifiedPackageNameSet);
@@ -375,7 +374,7 @@ PackageDatabase::query(const Query & q, const QueryOrder query_order) const
for (CategoryNamePartSet::ConstIterator c(cats->begin()), c_end(cats->end()) ;
c != c_end ; ++c)
{
- tr1::shared_ptr<const QualifiedPackageNameSet> local_pkgs(fetch_