Commit a19e674b authored by Seth Howell's avatar Seth Howell Committed by Jim Harris
Browse files

make: always fail if mk/config.mk doesn't exist.



We previously were failing for all make targets except for clean if the
mk/config.mk file didn't exist, but we should also be failing to
perform make clean if we don't have this file. It turns out you end up
erroring out in the next line anyways. Also, if you make that include
optional, make still fails because we don't have any kind of environment
specified and spdk.common.mk depends on that variable being defined.

There may be some benefit to being able to run make clean if we don't
have a valid configuration file, but right now, there are a lot of
things that depend on the configuration file, such as which environment
file to make or clean and which directories need cleaned.

Change-Id: I2a9c1e982c01ba76b67b153ee7336402300b76b0
Signed-off-by: default avatarSeth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/466346


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarPaul Luse <paul.e.luse@intel.com>
Reviewed-by: default avatarBen Walker <benjamin.walker@intel.com>
Reviewed-by: default avatarJim Harris <james.r.harris@intel.com>
parent 390542a3
Loading
Loading
Loading
Loading
+1 −3
Original line number Diff line number Diff line
@@ -33,10 +33,8 @@
#  OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#

ifneq ($(MAKECMDGOALS),clean)
ifeq ($(wildcard $(SPDK_ROOT_DIR)/mk/config.mk),)
$(error mk/config.mk: file not found. Please run configure before 'make $(filter-out clean,$(MAKECMDGOALS))')
endif
$(error mk/config.mk: file not found. Please run configure before make)
endif

include $(SPDK_ROOT_DIR)/mk/config.mk