Page MenuHomeFreeBSD

D10987.id28996.diff
No OneTemporary

D10987.id28996.diff

Index: Makefile.inc1
===================================================================
--- Makefile.inc1
+++ Makefile.inc1
@@ -975,6 +975,22 @@
fi
.endfor
.endif
+#
+# If installing over the running system (DESTDIR is / or unset) and the install
+# includes rescue, try running rescue from the objdir as a sanity check. If
+# rescue is not functional (e.g., because it depends on a system call not
+# supported by the currently running kernel), abort the installation.
+#
+.if !make(distributeworld) && ${MK_RESCUE} != "no" && \
+ (empty(DESTDIR) || ${DESTDIR} == "/")
+_installcheck_world: __installcheck_sh_check
+__installcheck_sh_check: .PHONY
+ @if [ "`${OBJTREE}${.CURDIR}/rescue/rescue/rescue sh -c 'echo OK'`" != \
+ OK ]; then \
+ echo "rescue/sh check failed, installation aborted" >&2; \
+ false; \
+ fi
+.endif
#
# Required install tools to be saved in a scratch dir for safety.

File Metadata

Mime Type
text/plain
Expires
Mon, Apr 20, 8:41 PM (3 h, 51 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
31863434
Default Alt Text
D10987.id28996.diff (911 B)

Event Timeline