summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--release/Makefile4
-rw-r--r--sys/conf/kern.post.mk6
-rw-r--r--sys/conf/kmod.mk11
3 files changed, 7 insertions, 14 deletions
diff --git a/release/Makefile b/release/Makefile
index 93e97ec..9fc3761 100644
--- a/release/Makefile
+++ b/release/Makefile
@@ -583,10 +583,6 @@ release.3:
cd ${.CURDIR}/..; \
${CROSSMAKE} ${KERNEL_FLAGS} \
kernel \
- DESTDIR=${RD}/trees/base; \
- cd ${.CURDIR}/..; \
- ${CROSSMAKE} ${KERNEL_FLAGS} -DNO_MODULES \
- reinstallkernel -DINSTALL_DEBUG \
DESTDIR=${RD}/trees/base
touch ${.TARGET}
diff --git a/sys/conf/kern.post.mk b/sys/conf/kern.post.mk
index 452d1f1..40cd967 100644
--- a/sys/conf/kern.post.mk
+++ b/sys/conf/kern.post.mk
@@ -69,6 +69,8 @@ FULLKERNEL= ${KERNEL_KO}
FULLKERNEL= ${KERNEL_KO}.debug
${KERNEL_KO}: ${FULLKERNEL}
${OBJCOPY} --strip-debug ${FULLKERNEL} ${KERNEL_KO}
+install.debug reinstall.debug: gdbinit
+ cd ${.CURDIR}; ${MAKE} ${.TARGET:R}
# Install gdbinit files for kernel debugging.
gdbinit:
@@ -204,7 +206,7 @@ kernel-install:
.endif
mkdir -p ${DESTDIR}${KODIR}
.if defined(DEBUG) && !defined(INSTALL_NODEBUG)
- ${INSTALL} -p -m 555 -o root -g wheel ${FULLKERNEL} ${DESTDIR}${KODIR}
+ ${INSTALL} -p -m 555 -o root -g wheel ${FULLKERNEL} ${DESTDIR}${KODIR}/${KERNEL_KO}
.else
${INSTALL} -p -m 555 -o root -g wheel ${KERNEL_KO} ${DESTDIR}${KODIR}
.endif
@@ -212,7 +214,7 @@ kernel-install:
kernel-reinstall:
@-chflags -R noschg ${DESTDIR}${KODIR}
.if defined(DEBUG) && !defined(INSTALL_NODEBUG)
- ${INSTALL} -p -m 555 -o root -g wheel ${FULLKERNEL} ${DESTDIR}${KODIR}
+ ${INSTALL} -p -m 555 -o root -g wheel ${FULLKERNEL} ${DESTDIR}${KODIR}/${KERNEL_KO}
.else
${INSTALL} -p -m 555 -o root -g wheel ${KERNEL_KO} ${DESTDIR}${KODIR}
.endif
diff --git a/sys/conf/kmod.mk b/sys/conf/kmod.mk
index a1c48d2..0f010e8 100644
--- a/sys/conf/kmod.mk
+++ b/sys/conf/kmod.mk
@@ -236,21 +236,17 @@ _INSTALLFLAGS:= ${INSTALLFLAGS}
_INSTALLFLAGS:= ${_INSTALLFLAGS${ie}}
.endfor
-.if !target(install.debug) && defined(DEBUG_FLAGS)
-install.debug:
- cd ${.CURDIR}; ${MAKE} -DINSTALL_DEBUG install
-.endif
-
.if !target(realinstall)
realinstall: _kmodinstall
.ORDER: beforeinstall _kmodinstall
_kmodinstall:
-.if defined(DEBUG_FLAGS) && defined(INSTALL_DEBUG)
+.if defined(DEBUG_FLAGS) && !defined(INSTALL_NODEBUG)
${INSTALL} -o ${KMODOWN} -g ${KMODGRP} -m ${KMODMODE} \
- ${_INSTALLFLAGS} ${FULLPROG} ${DESTDIR}${KMODDIR}
+ ${_INSTALLFLAGS} ${FULLPROG} ${DESTDIR}${KMODDIR}/${PROG}
.else
${INSTALL} -o ${KMODOWN} -g ${KMODGRP} -m ${KMODMODE} \
${_INSTALLFLAGS} ${PROG} ${DESTDIR}${KMODDIR}
+.endif
.include <bsd.links.mk>
@@ -264,7 +260,6 @@ _kldxref:
kldxref ${DESTDIR}${KMODDIR}; \
fi
.endif
-.endif
.endif # !target(realinstall)
.endif # !target(install)
OpenPOWER on IntegriCloud