diff mbox series

[v2,1/4] configure: Use discovered make for in-source build

Message ID 20200825202755.50626-2-r.bolshakov@yadro.com (mailing list archive)
State New, archived
Headers show
Series Compatibility make fixes for meson | expand

Commit Message

Roman Bolshakov Aug. 25, 2020, 8:27 p.m. UTC
A recursive make is invoked if in-source build is used but $(MAKE) is
the same as the one used in the original make invocation.

Some platforms have preference to use gmake, or a make passed as an
option to "configure". Honor the choice.

Signed-off-by: Roman Bolshakov <r.bolshakov@yadro.com>
---
 configure | 6 ++++++
 1 file changed, 6 insertions(+)
diff mbox series

Patch

diff --git a/configure b/configure
index b1e11397a8..07732bf011 100755
--- a/configure
+++ b/configure
@@ -38,6 +38,11 @@  then
 # This file is auto-generated by configure to support in-source tree
 # 'make' command invocation
 
+ifeq ($(wildcard build/config-host.mak),)
+$(error Incomplete configuration. Please run `configure`)
+endif
+include build/config-host.mak
+
 ifeq ($(MAKECMDGOALS),)
 recurse: all
 endif
@@ -54,6 +59,7 @@  endif
 force: ;
 .PHONY: force
 GNUmakefile: ;
+build/config-host.mak: ;
 
 EOF
     cd build