Page MenuHomeFreeBSD

D10987.id29018.diff
No OneTemporary

D10987.id29018.diff

Index: head/Makefile.inc1
===================================================================
--- head/Makefile.inc1
+++ head/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} == "/") && empty(BYPASS_INSTALLCHECK_SH)
+_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
Thu, Mar 26, 8:57 AM (15 h, 16 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
30375410
Default Alt Text
D10987.id29018.diff (959 B)

Event Timeline