ports/153597: chrooted make always returns the status 0
HIROSHI OOTA
xalaxy at gmail.com
Sat Jan 1 12:10:11 UTC 2011
>Number: 153597
>Category: ports
>Synopsis: chrooted make always returns the status 0
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Sat Jan 01 12:10:10 UTC 2011
>Closed-Date:
>Last-Modified:
>Originator: HIROSHI OOTA
>Release: 9-current
>Organization:
>Environment:
FreeBSD aries 9.0-CURRENT FreeBSD 9.0-CURRENT #114 r216689M: Fri Dec 24 21:41:56 JST 2010 root@ amd64
>Description:
chrooted make always returns the status 0.
>How-To-Repeat:
cd /usr/ports/archivers/zip; make DESTDIR=/tmp unknown-target; echo "exit status=$?"
===> Creating some important subdirectories
===> /tmp subdirectory has been successfully created
===> /dev subdirectory has been successfully created
===> Starting chrooted make in /tmp...
chroot: /bin/sh: No such file or directory
===> Chrooted make in /tmp failed
===> Cleaning up...
exit status=0
>Fix:
--- bsd.destdir.mk.orig 2011-01-01 20:50:41.964186373 +0900
+++ bsd.destdir.mk 2011-01-01 20:53:15.239188075 +0900
@@ -208,8 +210,8 @@
${CHROOT} $${_destdir} ${SH} -c "\
cd $${PORTSDIR}${.CURDIR:S|^${PORTSDIR}||}; \
${SETENV} -i ${DESTDIR_ENV} $${_var_path_list} ${MAKE} ${.TARGETS}" &\
& \
- ${ECHO_MSG} "===> Chrooted make in ${DESTDIR} succeeded" || \
- ${ECHO_MSG} "===> Chrooted make in ${DESTDIR} failed"; \
+ { status=$$?; ${ECHO_MSG} "===> Chrooted make in ${DESTDIR} succeeded"; } || \
+ { status=$$?; ${ECHO_MSG} "===> Chrooted make in ${DESTDIR} failed"; }; \
${ECHO_MSG} "===> Cleaning up..."; \
for _entry in $${_mounted_entries_list}; do \
${UMOUNT} -f $${_entry} || ${TRUE}; \
@@ -217,6 +219,6 @@
for _entry in $${_created_mountpoints_list}; do \
${RMDIR} $${_entry} || ${TRUE}; \
done; \
- exit 0
+ exit $$status
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list