]> xenbits.xensource.com Git - people/pauldu/xen.git/commitdiff
tools: fix build dependency upon generated header(s)
authorJan Beulich <jbeulich@suse.com>
Thu, 31 Jan 2019 10:37:56 +0000 (11:37 +0100)
committerJan Beulich <jbeulich@suse.com>
Thu, 31 Jan 2019 10:37:56 +0000 (11:37 +0100)
Commit fd35f32b4b ("tools/x86emul: Use struct cpuid_policy in the
userspace test harnesses") didn't account for the dependencies of
cpuid-autogen.h to potentially change between incremental builds.
Putting the make invocation to produce the header together with the
directory tree creation therefore does not work. Introduce a separate
goal.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Wei Liu <wei.liu2@citrix.com>
Release-acked-by: Juergen Gross <jgross@suse.com>
tools/include/Makefile

index 22df221daa74ebd342a573b77f7420a1f9f76e86..d69381005362a30fd47f913b2e8a63281c4e9785 100644 (file)
@@ -4,8 +4,9 @@ include $(XEN_ROOT)/tools/Rules.mk
 # Relative to $(XEN_ROOT)/xen/xsm/flask
 FLASK_H_DEPEND := policy/initial_sids
 
-.PHONY: all build
-all build: xen-foreign xen/.dir xen-xsm/.dir
+.PHONY: all all-y build
+all build: all-y xen-foreign xen/.dir xen-xsm/.dir
+all-y:
 
 .PHONY: xen-foreign
 xen-foreign:
@@ -27,10 +28,12 @@ ifeq ($(CONFIG_X86),y)
        for f in $(filter-out %autogen.h,$(patsubst $(XEN_ROOT)/xen/include/xen/lib/x86/%,%,Makefile $(wildcard $(XEN_ROOT)/xen/include/xen/lib/x86/*.h))); do \
                ln -sf $(XEN_ROOT)/xen/include/xen/lib/x86/$$f xen/lib/x86/$$f; \
        done
-       $(MAKE) -C xen/lib/x86 all XEN_ROOT=$(XEN_ROOT)
 endif
        touch $@
 
+all-$(CONFIG_X86): xen/.dir
+       $(MAKE) -C xen/lib/x86 all XEN_ROOT=$(XEN_ROOT)
+
 # Not xen/xsm as that clashes with link to
 # $(XEN_ROOT)/xen/include/public/xsm above.
 xen-xsm/.dir: $(XEN_ROOT)/xen/xsm/flask/policy/mkflask.sh \