[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[XEN PATCH v3 17/25] libs/libs.mk: Rework target headers.chk dependencies
- To: <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- From: Anthony PERARD <anthony.perard@xxxxxxxxxx>
- Date: Fri, 24 Jun 2022 17:04:14 +0100
- Authentication-results: esa1.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none
- Cc: Anthony PERARD <anthony.perard@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, "Juergen Gross" <jgross@xxxxxxxx>
- Delivery-date: Fri, 24 Jun 2022 16:05:06 +0000
- Ironport-data: A9a23:Pekj9qzCshs3SyY3t+x6t+dvxirEfRIJ4+MujC+fZmUNrF6WrkVRn WoWDWGGOfnbYGrwf9Ena4i18U0HucPRnNAwGQRo+CAxQypGp/SeCIXCJC8cHc8zwu4v7q5Dx 59DAjUVBJlsFhcwnj/0bv656yMUOZigHtIQMsadUsxKbVIiGX1JZS5LwbZj2NY224ThWWthh PupyyHhEA79s9JLGjp8B5Kr8HuDa9yr5Vv0FnRnDRx6lAe2e0s9VfrzFonoR5fMeaFGH/bSe gr25OrRElU1XfsaIojNfr7TKiXmS1NJVOSEoiI+t6OK2nCuqsGuu0qS2TV1hUp/0l20c95NJ NplhbKpQwITIpLwg8MCSD5hShpUEIQc5+qSSZS/mZT7I0zudnLtx7NlDV0sPJ1e8eFyaY1M3 aVGcnZXNEnF3r/ohuLgIgVvrp1LwM3DNYUDunZm3HfBAOwvW5zrSKTW/95Imjw3g6iiGN6BO 5VJNmU2PHwsZTVEE2YlBq46u9uJi0ftXxlfqHufqek4tj27IAtZj+G2bYu9lsaxbcdahEGDv Urd4n/0RBodMbS31j6t4n+qwOjVkkvTSI8UUbG16PNuqFmS3XAITg0bU0Ohpvu0gVL4XMhQQ 3H44QJ38/J0rhbyCICgAVvo+xZooyLwRfJgPfQw7TuR9ZbPxBmCIVFddRRsQYY54ZpeqSMR6 rOZoz/4LWUx7ePNEi/Fqef8QSCaYnZMczJbDcMQZU5cuoS4/tlu5v7aZow7eJNZmOEZDt0ZL 9qiiCElz4segscQv0lQ1QCW2mn8znQlo+Nc2+k2Yo5GxlkgDGJdT9b0gWU3FN4ZRGpjcnGPv WIfh++V5/0UAJeGmUSlGbtQQunxtq/abGWE3jaD+qXNERz3oxZPmqgAiAyS2W8zappUEdMXS BW7VfxtCG97YyLxMP4fj3OZAMU216nwfenYugTvRoMWOPBZLVbflAk3PBL49z29wSAEzPBkU b/GIJnEMJrvIfk+pNZAb7xGiuFDK+FX7T67eK0XODz9gOTHOiLKGOxbWLZMB8hghJ65TMzu2 443H6O3J993C4USvgG/HVYvEG03
- Ironport-hdrordr: A9a23:lsjL9q4JE9CmtxjY7QPXwPDXdLJyesId70hD6qhwISY6TiX+rb HJoB17726NtN9/YhEdcLy7VJVoBEmskKKdgrNhWotKPjOW21dARbsKheCJrgEIWReOktK1vZ 0QCpSWY+eQMbEVt6nHCXGDYrQd/OU=
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
There is no need to call the "headers.chk" target when it isn't
wanted, so it never need to be .PHONY.
Also, there is no more reason to separate the prerequisites from the
recipe.
Signed-off-by: Anthony PERARD <anthony.perard@xxxxxxxxxx>
---
tools/libs/libs.mk | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/tools/libs/libs.mk b/tools/libs/libs.mk
index 7aee449370..f778a7df82 100644
--- a/tools/libs/libs.mk
+++ b/tools/libs/libs.mk
@@ -55,22 +55,20 @@ $(PKG_CONFIG_LOCAL): PKG_CONFIG_INCDIR = $(XEN_INCLUDE)
$(PKG_CONFIG_LOCAL): PKG_CONFIG_LIBDIR = $(CURDIR)
.PHONY: all
-all: headers.chk $(TARGETS) $(PKG_CONFIG_LOCAL) libxen$(LIBNAME).map
$(LIBHEADERS)
+all: $(TARGETS) $(PKG_CONFIG_LOCAL) libxen$(LIBNAME).map $(LIBHEADERS)
ifneq ($(NO_HEADERS_CHK),y)
-headers.chk:
+all: headers.chk
+
+headers.chk: $(LIBHEADERS) $(AUTOINCS)
for i in $(filter %.h,$^); do \
$(CC) -x c -ansi -Wall -Werror $(CFLAGS_xeninclude) \
-S -o /dev/null $$i || exit 1; \
echo $$i; \
done >$@.new
mv $@.new $@
-else
-.PHONY: headers.chk
endif
-headers.chk: $(LIBHEADERS) $(AUTOINCS)
-
headers.lst: FORCE
@{ set -e; $(foreach h,$(LIBHEADERS),echo $(h);) } > $@.tmp
@$(call move-if-changed,$@.tmp,$@)
--
Anthony PERARD
|