Skip to contentSkip to conversation

tools/build: Fix installation of public headers

PATCH In review Andrew Cooper 3 participants 3 messages May 22, 2017 – May 24, 2017 Kbuild

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 tools/build: Fix installation of public headers

The recent build fixes have left the install-tools rule no longer installing the Xen public headers into /usr/include/xen/

Use pattern rules to generalise the %-tools-public-headers targets, and switch install-tools to depend on install-tools-public-headers rather than build-tools-public-headers.

---
CC: Ian Jackson <[email protected]>
CC: Wei Liu <[email protected]>
CC: Julien Grall <[email protected]>

---
 Makefile | 12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)
Makefile +4 -8
index fc30b3c..7e40ad6 100644
@@ -38,13 +38,9 @@ mini-os-dir-force-update: mini-os-dir
 export XEN_TARGET_ARCH
 export DESTDIR
 
-.PHONY: build-tools-public-headers
-build-tools-public-headers:
-	$(MAKE) -C tools/include
-
-.PHONY: dist-tools-public-headers
-dist-tools-public-headers: build-tools-public-headers
-	$(MAKE) -C tools/include dist
+$(foreach i,build install dist,$(eval PHONY: $(i)-tools-public-headers))
+%-tools-public-headers:
+	$(MAKE) -C tools/include $*
 
 # build and install everything into the standard system directories
 .PHONY: install
@@ -109,7 +105,7 @@ install-xen:
 	$(MAKE) -C xen install
 
 .PHONY: install-tools
-install-tools: build-tools-public-headers
+install-tools: install-tools-public-headers
 	$(MAKE) -C tools install
 
 .PHONY: install-stubdom
Signature · 7 lines
2.1.4


_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel
Reviewed-by on v1 1/1
#1 lore raw
Quoted 8 lines · Andrew Cooper

The recent build fixes have left the install-tools rule no longer installing the Xen public headers into /usr/include/xen/

Use pattern rules to generalise the %-tools-public-headers targets, and switch install-tools to depend on install-tools-public-headers rather than build-tools-public-headers.

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel