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
This commit is contained in:
John Baldwin 2018-10-30 18:20:34 +00:00
parent 920239efde
commit 58b6812de1
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=339926

View File

@ -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