# print notification about required overlays when building Gentoo packages
# USAGE: information_required_gentoo_overlays $overlays
information_required_gentoo_overlays() {
	local overlays_file
	overlays_file=$(dependency_gentoo_overlays_file)

	local messages_language message
	messages_language=$(messages_language)
	case "$messages_language" in
		('fr')
			message='Vous pourriez avoir besoin des overlays suivants pour installer ces paquets :'
		;;
		('en'|*)
			message='You may need the following overlays to install these packages:'
		;;
	esac
	print_message 'info' '\n%s\n' \
		"$message"
	print_message 'info' '\t%s\n' \
		"$(cat "$overlays_file")"
}

# Error - An unknown architecture string is used
# USAGE: error_unknown_gentoo_architecture_string $arch_string $caller
error_unknown_gentoo_architecture_string() {
	local arch_string caller
	arch_string="$1"
	caller="$2"

	local messages_language message
	messages_language=$(messages_language)
	case "$messages_language" in
		('fr')
			message='Lʼarchitecture « %s », utilisée dans %s, est inconnue sous Gentoo.\n'
			;;
		('en'|*)
			message='“%s” architecture, used in %s, is unknown on Gentoo.\n'
			;;
	esac
	print_message 'error' "$message" \
		"$arch_string" \
		"$caller"
}

