diff --git a/sys/conf/kern.post.mk b/sys/conf/kern.post.mk index 010aef20919b..ff10daf1a0a5 100644 --- a/sys/conf/kern.post.mk +++ b/sys/conf/kern.post.mk @@ -61,7 +61,7 @@ LOCAL_MODULES_DIR?= ${LOCALBASE}/sys/modules # Default to installing all modules installed by ports unless overridden # by the user. -.if !defined(LOCAL_MODULES) && exists($LOCAL_MODULES_DIR) +.if !defined(LOCAL_MODULES) && exists(${LOCAL_MODULES_DIR}) LOCAL_MODULES!= ls ${LOCAL_MODULES_DIR} .endif .endif @@ -77,7 +77,9 @@ modules-${target}: ${target:S/^reinstall$/install/:S/^clobber$/cleandir/} .endif .for module in ${LOCAL_MODULES} - cd ${LOCAL_MODULES_DIR}/${module}; ${MKMODULESENV} ${MAKE} \ + @${ECHODIR} "===> ${module} (${target:S/^reinstall$/install/:S/^clobber$/cleandir/})" + @cd ${LOCAL_MODULES_DIR}/${module}; ${MKMODULESENV} ${MAKE} \ + DIRPRFX="${module}/" \ ${target:S/^reinstall$/install/:S/^clobber$/cleandir/} .endfor .endif