From owner-svn-src-all@freebsd.org Thu Dec 24 01:48:42 2015 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2A6DEA4E4CB; Thu, 24 Dec 2015 01:48:42 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D607A1D6D; Thu, 24 Dec 2015 01:48:41 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id tBO1mf8m057673; Thu, 24 Dec 2015 01:48:41 GMT (envelope-from imp@FreeBSD.org) Received: (from imp@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id tBO1meQY057672; Thu, 24 Dec 2015 01:48:40 GMT (envelope-from imp@FreeBSD.org) Message-Id: <201512240148.tBO1meQY057672@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: imp set sender to imp@FreeBSD.org using -f From: Warner Losh Date: Thu, 24 Dec 2015 01:48:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r292677 - head/tools/tools/nanobsd/embedded X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Dec 2015 01:48:42 -0000 Author: imp Date: Thu Dec 24 01:48:40 2015 New Revision: 292677 URL: https://svnweb.freebsd.org/changeset/base/292677 Log: Move creation of rc.conf to earlier so it winds up in /conf/boot/etc With this change we mostly boot w/o errors on RPi-B for an image cross built w/o privs. Other systems to follow. Release Notes: Yes Modified: head/tools/tools/nanobsd/embedded/common Modified: head/tools/tools/nanobsd/embedded/common ============================================================================== --- head/tools/tools/nanobsd/embedded/common Thu Dec 24 00:58:11 2015 (r292676) +++ head/tools/tools/nanobsd/embedded/common Thu Dec 24 01:48:40 2015 (r292677) @@ -431,6 +431,24 @@ $var=$val" fi done +typical_embedded ( ) ( + # Need to create rc.conf before we copy over /etc to /conf/base/etc + # so now's a good time. + + local rc=${NANO_WORLDDIR}/etc/rc.conf + + echo "hostname=nanobsd-${NANO_NAME}" > $rc + echo "growfs_enable=YES" >> $rc + echo "growfs_type=nanobsd-pingpong" >> $rc + echo "ntpdate_enable=YES" >> $rc + echo "ifconfig_DEFAULT=DHCP" >> $rc + echo "ntpdate_hosts=0.freebsd.pool.ntp.org 1.freebsd.pool.ntp.org" >> $rc + # Make sure that firstboot scripts run so growfs works. + # Note: still some issues remvoing this XXX + touch ${NANO_WORLDDIR}/firstboot +) +customize_cmd typical_embedded + save_build ( ) ( VERSION_FILE=${NANO_WORLDDIR}/etc/version if [ "${SVNREVISION}" = "${REVISION}" ]; then @@ -502,14 +520,6 @@ product_custom ( ) ( chown root:wheel ${NANO_WORLDDIR}/ chown root:wheel ${NANO_WORLDDIR}/usr fi - local rc=${NANO_WORLDDIR}/etc/rc.conf - echo "hostname=nanobsd-${NANO_NAME}" > $rc - echo "growfs_enable=YES" >> $rc - echo "growfs_type=nanobsd-pingpong" >> $rc - echo "ntpdate_enable=YES" >> $rc - echo "ntpdate_hosts=0.freebsd.pool.ntp.org 1.freebsd.pool.ntp.org" >> $rc - # Make sure that firstboot scripts run so growfs works. - touch ${NANO_WORLDDIR}/firstboot ) late_customize_cmd product_custom