[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[xen staging] tools/misc: rework Makefile



commit 41da0c21eea3ac5cb67d5b0ed4f52fbadab51f19
Author:     Anthony PERARD <anthony.perard@xxxxxxxxxx>
AuthorDate: Mon Dec 6 17:02:15 2021 +0000
Commit:     Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
CommitDate: Thu Dec 16 20:27:13 2021 +0000

    tools/misc: rework Makefile
    
    Add missing "xen-detect" rule. It only works without it because we
    still have make's built-ins rules and variables, but fix this to not
    have to rely on them.
    
    Rename $(TARGETS_BUILD) to $(TARGETS).
    
    Remove the unused "build" target.
    
    Also, they are no more "build-only" targets, remove the extra code.
    
    Signed-off-by: Anthony PERARD <anthony.perard@xxxxxxxxxx>
    Acked-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
---
 tools/misc/Makefile | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/tools/misc/Makefile b/tools/misc/Makefile
index 8b9558b93f..0e02401227 100644
--- a/tools/misc/Makefile
+++ b/tools/misc/Makefile
@@ -50,16 +50,13 @@ TARGETS_COPY += xencov_split
 TARGETS_COPY += xenpvnetboot
 
 # Everything which needs to be built
-TARGETS_BUILD := $(filter-out $(TARGETS_COPY),$(TARGETS_ALL))
+TARGETS := $(filter-out $(TARGETS_COPY),$(TARGETS_ALL))
 
-# ... including build-only targets
-TARGETS_BUILD += $(TARGETS_BUILD-y)
-
-.PHONY: all build
-all build: $(TARGETS_BUILD)
+.PHONY: all
+all: $(TARGETS)
 
 .PHONY: install
-install: build
+install: all
        $(INSTALL_DIR) $(DESTDIR)$(bindir)
        $(INSTALL_DIR) $(DESTDIR)$(sbindir)
        $(INSTALL_DIR) $(DESTDIR)$(LIBEXEC_BIN)
@@ -75,7 +72,7 @@ uninstall:
 
 .PHONY: clean
 clean:
-       $(RM) *.o $(TARGETS_BUILD) *~ $(DEPS_RM)
+       $(RM) *.o $(TARGETS) $(DEPS_RM)
 
 .PHONY: distclean
 distclean: clean
@@ -86,6 +83,9 @@ xen-access: xen-access.o
 xen-cpuid: xen-cpuid.o
        $(CC) $(LDFLAGS) -o $@ $< $(LDLIBS_libxenctrl) $(LDLIBS_libxenguest) 
$(APPEND_LDFLAGS)
 
+xen-detect: xen-detect.o
+       $(CC) $(LDFLAGS) -o $@ $< $(APPEND_LDFLAGS)
+
 xen-hvmctx: xen-hvmctx.o
        $(CC) $(LDFLAGS) -o $@ $< $(LDLIBS_libxenctrl) $(APPEND_LDFLAGS)
 
--
generated by git-patchbot for /home/xen/git/xen.git#staging



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.