From 58b6812de1ecbad84ccbd914b87c84a7e94abbb9 Mon Sep 17 00:00:00 2001 From: John Baldwin Date: Tue, 30 Oct 2018 18:20:34 +0000 Subject: [PATCH] Only invoke 'ls' if the local modules directory exists. This avoids a spurious make warning if /usr/local/sys/modules doesn't exist. Submitted by: rgrimes Reported by: markj --- sys/conf/kern.post.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/conf/kern.post.mk b/sys/conf/kern.post.mk index bb85e919026c..98d179446905 100644 --- a/sys/conf/kern.post.mk +++ b/sys/conf/kern.post.mk @@ -43,7 +43,7 @@ LOCAL_MODULES_DIR?= ${LOCALBASE}/sys/modules # Default to installing all modules installed by ports unless overridden # by the user. -.if !defined(LOCAL_MODULES) +.if !defined(LOCAL_MODULES) && exists($LOCAL_MODULES_DIR) LOCAL_MODULES!= ls ${LOCAL_MODULES_DIR} .endif .endif