summaryrefslogtreecommitdiffstats
path: root/lib/cmd
diff options
context:
space:
mode:
Diffstat (limited to 'lib/cmd')
-rw-r--r--lib/cmd/install.sh16
1 files changed, 15 insertions, 1 deletions
diff --git a/lib/cmd/install.sh b/lib/cmd/install.sh
index 9b90fff..1f1aeb7 100644
--- a/lib/cmd/install.sh
+++ b/lib/cmd/install.sh
@@ -23,7 +23,7 @@ use profile
use fd
use pkg
-cmd_install_optstring='a:P:m:'
+cmd_install_optstring='a:P:m:F'
cmd_install_deps=
cmd_install_fnames=
cmd_install_feed_url=
@@ -36,6 +36,7 @@ cmd_install_main()
local plat=
local profile=
local mirror=
+ local foreign=
get_options "${@}"
shift $(($OPTIND - 1))
@@ -81,6 +82,12 @@ cmd_install_main()
fi
info "$(get_msg 'cmd_install_selected_mirror')" "${mirror}"
+ if [ "x${cmd_install_opt_F+set}" = 'xset' ]; then
+ foreign=true
+ else
+ foreign=false
+ fi
+
info "$(get_msg 'cmd_install_setting_up_chroot')"
if [ -d "${chroot}" ]; then
error 2 "$(get_msg 'cmd_install_chroot_dir_exists')" "${chroot}"
@@ -93,6 +100,13 @@ cmd_install_main()
cmd_install_find_pkgs "${mirror}" "${suite}" "${arch}" "${plat}" \
"${chroot}"
cmd_install_get_pkgs "${chroot}"
+
+ info "$(get_msg 'cmd_install_configuring')"
+ if ! ${foreign}; then
+ profile_configure_system_native "${chroot}"
+ else
+ profile_configure_system_foreign "${chroot}"
+ fi
}
cmd_install_find_pkgs()