/* vim: set sw=4 sts=4 et foldmethod=syntax : */ /* * Copyright (c) 2007, 2008, 2009, 2010, 2011 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_EAPI_HH #define PALUDIS_GUARD_PALUDIS_EAPI_HH 1 #include #include #include #include #include #include #include #include #include #include #include #include #include namespace paludis { namespace n { typedef Name allow_tokens_in_mask_files; typedef Name annotations; typedef Name best_has_version_host_root; typedef Name binary_from_env_variables; typedef Name blocker_resolution; typedef Name blocker_resolution_manual; typedef Name blocker_resolution_uninstall_blocked_after; typedef Name blocker_resolution_uninstall_blocked_before; typedef Name blocker_resolution_upgrade_blocked_before; typedef Name bracket_merged_variables; typedef Name bracket_merged_variables_annotatable; typedef Name bracket_merged_variables_annotation; typedef Name breaks_portage; typedef Name bugs_to; typedef Name build_depend; typedef Name can_be_pbin; typedef Name choices_options; typedef Name defined_phases; typedef Name dependencies; typedef Name dependency_labels; typedef Name dependency_spec_tree_parse_options; typedef Name description; typedef Name description_choices; typedef Name description_use; typedef Name directory_if_exists_variables; typedef Name directory_variables; typedef Name dodoc_r; typedef Name doins_symlink; typedef Name doman_lang_filenames; typedef Name doman_lang_filenames_overrides; typedef Name dosym_mkdir; typedef Name eapi; typedef Name ebuild_bad_options; typedef Name ebuild_config; typedef Name ebuild_environment_variables; typedef Name ebuild_fetch_extra; typedef Name ebuild_functions; typedef Name ebuild_info; typedef Name ebuild_install; typedef Name ebuild_metadata; typedef Name ebuild_metadata_variables; typedef Name ebuild_module_suffixes; typedef Name ebuild_must_not_set_variables; typedef Name ebuild_nofetch; typedef Name ebuild_options; typedef Name ebuild_phases; typedef Name ebuild_pretend; typedef Name ebuild_uninstall; typedef Name ebuild_variable; typedef Name ebuild_new_upgrade_phase_order; typedef Name econf_extra_options; typedef Name econf_extra_options_help_dependent; typedef Name eclass_must_not_set_variables; typedef Name env_a; typedef Name env_aa; typedef Name env_accept_license; typedef Name env_arch; typedef Name env_d; typedef Name env_distdir; typedef Name env_ebuild_phase; typedef Name env_ed; typedef Name env_eprefix; typedef Name env_eroot; typedef Name env_filesdir; typedef Name env_iuse_implicit; typedef Name env_jobs; typedef Name env_kv; typedef Name env_merge_type; typedef Name env_p; typedef Name env_pf; typedef Name env_portdir; typedef Name env_replaced_by_id; typedef Name env_replaced_by_version; typedef Name env_replacing_ids; typedef Name env_replacing_versions; typedef Name env_t; typedef Name env_use; typedef Name env_use_expand; typedef Name env_use_expand_hidden; typedef Name env_use_expand_implicit; typedef Name env_use_expand_unprefixed; typedef Name env_use_expand_values_part; typedef Name exported_name; typedef Name f_function_prefix; typedef Name failure_is_fatal; typedef Name fancy_test_flag; typedef Name fix_mtimes; typedef Name flat_list_index; typedef Name fs_location_description; typedef Name fs_location_name; typedef Name fs_merger_options; typedef Name general_author; typedef Name general_date; typedef Name general_description; typedef Name general_lang; typedef Name general_note; typedef Name general_token; typedef Name general_url; typedef Name generated_from; typedef Name generated_time; typedef Name generated_using; typedef Name has_expensive_tests; typedef Name has_optional_tests; typedef Name has_recommended_tests; typedef Name homepage; typedef Name ignore_pivot_env_functions; typedef Name ignore_pivot_env_variables; typedef Name inherited; typedef Name is_pbin; typedef Name iuse; typedef Name iuse_effective; typedef Name iuse_flag_parse_options; typedef Name keywords; typedef Name licence_last_checked; typedef Name license; typedef Name load_modules; typedef Name long_description; typedef Name merger_options; typedef Name metadata_key; typedef Name minimum_flat_list_size; typedef Name myoptions; typedef Name myoptions_number_selected; typedef Name myoptions_number_selected_at_least_one; typedef Name myoptions_number_selected_at_most_one; typedef Name myoptions_number_selected_exactly_one; typedef Name myoptions_presumed; typedef Name myoptions_requires; typedef Name must_not_change_after_source_variables; typedef Name must_not_change_variables; typedef Name must_not_set_vars_starting_with; typedef Name name; typedef Name new_stdin; typedef Name no_s_workdir_fallback; typedef Name no_slot_or_repo; typedef Name non_empty_variables; typedef Name package_dep_spec_parse_options; typedef Name pdepend; typedef Name permitted_directories; typedef Name pipe_commands; typedef Name profile_iuse_injection; typedef Name profile_options; typedef Name properties; typedef Name rdepend_defaults_to_depend; typedef Name remote_ids; typedef Name require_use_expand_in_iuse; typedef Name required_use; typedef Name restrict_fetch; typedef Name restrict_mirror; typedef Name restrict_primaryuri; typedef Name restrictions; typedef Name run_depend; typedef Name save_base_variables; typedef Name save_unmodifiable_variables; typedef Name save_variables; typedef Name scm_revision; typedef Name shell_options; typedef Name short_description; typedef Name slot; typedef Name source_merged_variables; typedef Name src_uri; typedef Name suggestions_group_name; typedef Name support_eclasses; typedef Name support_exlibs; typedef Name supported; typedef Name system_implicit; typedef Name tools_options; typedef Name unpack_fix_permissions; typedef Name unpack_suffixes; typedef Name unpack_unrecognised_is_fatal; typedef Name upstream_changelog; typedef Name upstream_documentation; typedef Name upstream_release_notes; typedef Name uri_labels; typedef Name use; typedef Name use_expand; typedef Name use_expand_hidden; typedef Name use_expand_separator; typedef Name use_stable_mask_force; typedef Name use_with_enable_empty_third_argument; typedef Name userpriv_cannot_use_root; typedef Name utility_path_suffixes; typedef Name vdb_from_env_unless_empty_variables; typedef Name vdb_from_env_variables; typedef Name version_spec_options; typedef Name want_portage_emulation_vars; } namespace erepository { class PALUDIS_VISIBLE EAPILabels { private: Pimp _imp; public: EAPILabels(const std::string &); EAPILabels(const EAPILabels &); ~EAPILabels(); const std::string class_for_label(const std::string &) const PALUDIS_ATTRIBUTE((warn_unused_result)); }; /** * Thrown if an EAPI configuration is broken. * * \see EAPI * \ingroup grpeapi * \ingroup grpexceptions * \nosubgrouping */ class PALUDIS_VISIBLE EAPIConfigurationError : public ConfigurationError { public: EAPIConfigurationError(const std::string &) throw (); }; /** * Holds information on recognised EAPIs. * * \see EAPI * \ingroup grpeapi * \nosubgrouping */ class PALUDIS_VISIBLE EAPIData : public Singleton { friend class Singleton; private: Pimp _imp; EAPIData(); ~EAPIData(); public: /** * Make an EAPI. */ std::shared_ptr eapi_from_string(const std::string &) const; /** * Make the unknown EAPI. */ std::shared_ptr unknown_eapi() const; }; struct EAPI { NamedValue exported_name; NamedValue name; NamedValue > supported; }; struct SupportedEAPI { NamedValue allow_tokens_in_mask_files; NamedValue > annotations; NamedValue breaks_portage; NamedValue can_be_pbin; NamedValue > choices_options; NamedValue > dependency_labels; NamedValue dependency_spec_tree_parse_options; NamedValue > ebuild_environment_variables; NamedValue > ebuild_metadata_variables; NamedValue > ebuild_options; NamedValue > ebuild_phases; NamedValue fs_merger_options; NamedValue is_pbin; NamedValue iuse_flag_parse_options; NamedValue merger_options; NamedValue package_dep_spec_parse_options; NamedValue permitted_directories; NamedValue > pipe_commands; NamedValue > profile_options; NamedValue > tools_options; NamedValue > uri_labels; NamedValue userpriv_cannot_use_root; NamedValue version_spec_options; }; struct EAPIChoicesOptions { NamedValue fancy_test_flag; NamedValue has_expensive_tests; NamedValue has_optional_tests; NamedValue has_recommended_tests; NamedValue profile_iuse_injection; NamedValue use_expand_separator; }; struct EAPIEbuildEnvironmentVariables { NamedValue description_choices; NamedValue description_use; NamedValue env_a; NamedValue env_aa; NamedValue env_accept_license; NamedValue env_arch; NamedValue env_d; NamedValue env_distdir; NamedValue env_ebuild_phase; NamedValue env_ed; NamedValue env_eprefix; NamedValue env_eroot; NamedValue env_filesdir; NamedValue env_iuse_implicit; NamedValue env_jobs; NamedValue env_kv; NamedValue env_merge_type; NamedValue env_p; NamedValue env_pf; NamedValue env_portdir; NamedValue env_replaced_by_id; NamedValue env_replaced_by_version; NamedValue env_replacing_ids; NamedValue env_replacing_versions; NamedValue env_t; NamedValue env_use; NamedValue env_use_expand; NamedValue env_use_expand_hidden; NamedValue env_use_expand_implicit; NamedValue env_use_expand_unprefixed; NamedValue env_use_expand_values_part; }; struct EAPIMetadataVariable { NamedValue description; NamedValue flat_list_index; NamedValue name; }; struct EAPIEbuildMetadataVariables { NamedValue > bugs_to; NamedValue > build_depend; NamedValue > defined_phases; NamedValue > dependencies; NamedValue > eapi; NamedValue > generated_from; NamedValue > generated_time; NamedValue > generated_using; NamedValue > homepage; NamedValue > inherited; NamedValue > iuse; NamedValue > iuse_effective; NamedValue > keywords; NamedValue > license; NamedValue > long_description; NamedValue minimum_flat_list_size; NamedValue > myoptions; NamedValue > pdepend; NamedValue > properties; NamedValue > remote_ids; NamedValue > required_use; NamedValue > restrictions; NamedValue > run_depend; NamedValue > scm_revision; NamedValue > short_description; NamedValue > slot; NamedValue > src_uri; NamedValue > upstream_changelog; NamedValue > upstream_documentation; NamedValue > upstream_release_notes; NamedValue > use; NamedValue > use_expand; NamedValue > use_expand_hidden; }; struct EAPIEbuildOptions { NamedValue binary_from_env_variables; NamedValue bracket_merged_variables; NamedValue bracket_merged_variables_annotatable; NamedValue bracket_merged_variables_annotation; NamedValue directory_if_exists_variables; NamedValue directory_variables; NamedValue ebuild_functions; NamedValue ebuild_module_suffixes; NamedValue ebuild_must_not_set_variables; NamedValue eclass_must_not_set_variables; NamedValue f_function_prefix; NamedValue fix_mtimes; NamedValue fs_location_description; NamedValue fs_location_name; NamedValue ignore_pivot_env_functions; NamedValue ignore_pivot_env_variables; NamedValue load_modules; NamedValue must_not_change_after_source_variables; NamedValue must_not_change_variables; NamedValue must_not_set_vars_starting_with; NamedValue no_s_workdir_fallback; NamedValue non_empty_variables; NamedValue rdepend_defaults_to_depend; NamedValue require_use_expand_in_iuse; NamedValue > > restrict_fetch; NamedValue > > restrict_mirror; NamedValue > > restrict_primaryuri; NamedValue save_base_variables; NamedValue save_unmodifiable_variables; NamedValue save_variables; NamedValue shell_options; NamedValue source_merged_variables; NamedValue support_eclasses; NamedValue support_exlibs; NamedValue utility_path_suffixes; NamedValue vdb_from_env_unless_empty_variables; NamedValue vdb_from_env_variables; NamedValue want_portage_emulation_vars; }; struct EAPIEbuildPhases { NamedValue ebuild_bad_options; NamedValue ebuild_config; NamedValue ebuild_fetch_extra; NamedValue ebuild_info; NamedValue ebuild_install; NamedValue ebuild_metadata; NamedValue ebuild_new_upgrade_phase_order; NamedValue ebuild_nofetch; NamedValue ebuild_pretend; NamedValue ebuild_uninstall; NamedValue ebuild_variable; }; struct EAPIProfileOptions { NamedValue use_stable_mask_force; }; struct EAPIToolsOptions { NamedValue best_has_version_host_root; NamedValue dodoc_r; NamedValue doins_symlink; NamedValue doman_lang_filenames; NamedValue doman_lang_filenames_overrides; NamedValue dosym_mkdir; NamedValue econf_extra_options; NamedValue econf_extra_options_help_dependent; NamedValue failure_is_fatal; NamedValue new_stdin; NamedValue unpack_fix_permissions; NamedValue unpack_suffixes; NamedValue unpack_unrecognised_is_fatal; NamedValue use_with_enable_empty_third_argument; }; struct EAPIPipeCommands { NamedValue no_slot_or_repo; }; struct EAPIAnnotations { NamedValue blocker_resolution; NamedValue blocker_resolution_manual; NamedValue blocker_resolution_uninstall_blocked_after; NamedValue blocker_resolution_uninstall_blocked_before; NamedValue blocker_resolution_upgrade_blocked_before; NamedValue general_author; NamedValue general_date; NamedValue general_description; NamedValue general_lang; NamedValue general_note; NamedValue general_token; NamedValue general_url; NamedValue licence_last_checked; NamedValue myoptions_number_selected; NamedValue myoptions_number_selected_at_least_one; NamedValue myoptions_number_selected_at_most_one; NamedValue myoptions_number_selected_exactly_one; NamedValue myoptions_presumed; NamedValue myoptions_requires; NamedValue suggestions_group_name; NamedValue system_implicit; }; } } #endif