From fb26038e26edfc57e5408cd39446da293d837692 Mon Sep 17 00:00:00 2001 From: P. J. McDermott Date: Thu, 21 Aug 2014 12:00:01 -0400 Subject: profile_configure_system_native(): New function --- diff --git a/lib/profile.sh b/lib/profile.sh index a8beedd..846b22d 100644 --- a/lib/profile.sh +++ b/lib/profile.sh @@ -122,3 +122,10 @@ profile_get_fstab() "prof_${profile}_get_fstab" "${arch}" "${plat}" } + +profile_configure_system_native() +{ + local root="${1}" + + "prof_${profile}_configure_system_native" "${root}" +} diff --git a/lib/profiles/proteanos.sh b/lib/profiles/proteanos.sh index 4f52611..cddef89 100644 --- a/lib/profiles/proteanos.sh +++ b/lib/profiles/proteanos.sh @@ -17,6 +17,8 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . +use opkg + # TODO: This should be replaced with a prof_proteanos_validate_archplat() # function that gets valid architectures and platforms from the package archive # (which pro-archman needs to list in the distribution). @@ -161,3 +163,16 @@ prof_proteanos_get_fstab() ;; esac } + +prof_proteanos_configure_system_native() +{ + local root="${1}" + + printf 'disabled\n' >"${root}/etc/rc.policy" + opkg_install_all + printf 'enabled\n' >"${root}/etc/rc.policy" + [ -r /etc/resolv.conf ] && cp /etc/resolv.conf "${root}/etc" + [ -r /etc/hostname ] && cp /etc/hostname "${root}/etc" + [ -e "${root}/etc/passwd" ] || printf \ + 'root::0:0:root:/root:/bin/sh\n' >"${root}/etc/passwd" +} -- cgit v0.9.1