mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-25 16:13:17 +00:00
Only copy /etc/resolv.conf to ${CHROOTDIR} if /etc/resolv.conf does
not already exist within ${CHROOTDIR}. This allows re-using a build chroot with CHROOTBUILD_SKIP set to a non-empty value and CHROOTDIR set to '/' in release.conf. MFC after: 3 days Sponsored by: The FreeBSD Foundation
This commit is contained in:
parent
cac201b866
commit
d294a5246f
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=325863
@ -252,8 +252,8 @@ chroot_setup() {
|
||||
extra_chroot_setup() {
|
||||
mkdir -p ${CHROOTDIR}/dev
|
||||
mount -t devfs devfs ${CHROOTDIR}/dev
|
||||
[ -e /etc/resolv.conf ] && cp /etc/resolv.conf \
|
||||
${CHROOTDIR}/etc/resolv.conf
|
||||
[ -e /etc/resolv.conf -a ! -e ${CHROOTDIR}/etc/resolv.conf ] && \
|
||||
cp /etc/resolv.conf ${CHROOTDIR}/etc/resolv.conf
|
||||
# Run ldconfig(8) in the chroot directory so /var/run/ld-elf*.so.hints
|
||||
# is created. This is needed by ports-mgmt/pkg.
|
||||
eval chroot ${CHROOTDIR} /etc/rc.d/ldconfig forcerestart
|
||||
|
Loading…
Reference in New Issue
Block a user