[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH 3/3] xen: Use $(T) and $(D) aliases in install target
On 07/17/2013 04:37 PM, Ian Campbell wrote: > This is consistent with the uninstall target and also shortens some longish > lines. > > $(Z) be used in the depencies when it is declared in this way, so expand it. > > Suggested-by: Jan Beulich <jbeulich@xxxxxxxx> > Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx> Acked-by: Julien Grall <julien.grall@xxxxxxxxxx> > --- > xen/Makefile | 32 +++++++++++++++++--------------- > 1 files changed, 17 insertions(+), 15 deletions(-) > > diff --git a/xen/Makefile b/xen/Makefile > index 0a20662..2bb5851 100644 > --- a/xen/Makefile > +++ b/xen/Makefile > @@ -30,26 +30,28 @@ endif > > .PHONY: _build > _build: Z=$(CONFIG_XEN_INSTALL_SUFFIX) > -_build: $(TARGET)$(Z) > +_build: $(TARGET)$(CONFIG_XEN_INSTALL_SUFFIX) > > .PHONY: _install > _install: Z=$(CONFIG_XEN_INSTALL_SUFFIX) > -_install: $(TARGET)$(Z) > - [ -d $(DESTDIR)/boot ] || $(INSTALL_DIR) $(DESTDIR)/boot > - $(INSTALL_DATA) $(TARGET)$(Z) $(DESTDIR)/boot/$(notdir > $(TARGET))-$(XEN_FULLVERSION) > - ln -f -s $(notdir $(TARGET))-$(XEN_FULLVERSION) > $(DESTDIR)/boot/$(notdir $(TARGET))-$(XEN_VERSION).$(XEN_SUBVERSION) > - ln -f -s $(notdir $(TARGET))-$(XEN_FULLVERSION) > $(DESTDIR)/boot/$(notdir $(TARGET))-$(XEN_VERSION) > - ln -f -s $(notdir $(TARGET))-$(XEN_FULLVERSION) > $(DESTDIR)/boot/$(notdir $(TARGET)) > - $(INSTALL_DATA) $(TARGET)-syms $(DESTDIR)/boot/$(notdir > $(TARGET))-syms-$(XEN_FULLVERSION) > +_install: D=$(DESTDIR) > +_install: T=$(notdir $(TARGET)) > +_install: $(TARGET)$(CONFIG_XEN_INSTALL_SUFFIX) > + [ -d $(D)/boot ] || $(INSTALL_DIR) $(D)/boot > + $(INSTALL_DATA) $(TARGET)$(Z) $(D)/boot/$(T)-$(XEN_FULLVERSION) > + ln -f -s $(T)-$(XEN_FULLVERSION) > $(D)/boot/$(T)-$(XEN_VERSION).$(XEN_SUBVERSION) > + ln -f -s $(T)-$(XEN_FULLVERSION) $(D)/boot/$(T)-$(XEN_VERSION) > + ln -f -s $(T)-$(XEN_FULLVERSION) $(D)/boot/$(T) > + $(INSTALL_DATA) $(TARGET)-syms $(D)/boot/$(T)-syms-$(XEN_FULLVERSION) > if [ -r $(TARGET).efi -a -n '$(EFI_DIR)' ]; then \ > - [ -d $(DESTDIR)$(EFI_DIR) ] || $(INSTALL_DIR) > $(DESTDIR)$(EFI_DIR); \ > - $(INSTALL_DATA) $(TARGET).efi $(DESTDIR)$(EFI_DIR)/$(notdir > $(TARGET))-$(XEN_FULLVERSION).efi; \ > - ln -sf $(notdir $(TARGET))-$(XEN_FULLVERSION).efi > $(DESTDIR)$(EFI_DIR)/$(notdir > $(TARGET))-$(XEN_VERSION).$(XEN_SUBVERSION).efi; \ > - ln -sf $(notdir $(TARGET))-$(XEN_FULLVERSION).efi > $(DESTDIR)$(EFI_DIR)/$(notdir $(TARGET))-$(XEN_VERSION).efi; \ > - ln -sf $(notdir $(TARGET))-$(XEN_FULLVERSION).efi > $(DESTDIR)$(EFI_DIR)/$(notdir $(TARGET)).efi; \ > + [ -d $(D)$(EFI_DIR) ] || $(INSTALL_DIR) $(D)$(EFI_DIR); \ > + $(INSTALL_DATA) $(TARGET).efi > $(D)$(EFI_DIR)/$(T)-$(XEN_FULLVERSION).efi; \ > + ln -sf $(T)-$(XEN_FULLVERSION).efi > $(D)$(EFI_DIR)/$(T)-$(XEN_VERSION).$(XEN_SUBVERSION).efi; \ > + ln -sf $(T)-$(XEN_FULLVERSION).efi > $(D)$(EFI_DIR)/$(T)-$(XEN_VERSION).efi; \ > + ln -sf $(T)-$(XEN_FULLVERSION).efi $(D)$(EFI_DIR)/$(T).efi; \ > if [ -n '$(EFI_MOUNTPOINT)' -a -n '$(EFI_VENDOR)' ]; then \ > - $(INSTALL_DATA) $(TARGET).efi > $(DESTDIR)$(EFI_MOUNTPOINT)/efi/$(EFI_VENDOR)/$(notdir > $(TARGET))-$(XEN_FULLVERSION).efi; \ > - elif [ "$(DESTDIR)" = "$(patsubst $(shell cd $(XEN_ROOT) && > pwd)/%,%,$(DESTDIR))" ]; then \ > + $(INSTALL_DATA) $(TARGET).efi > $(D)$(EFI_MOUNTPOINT)/efi/$(EFI_VENDOR)/$(T)-$(XEN_FULLVERSION).efi; \ > + elif [ "$(D)" = "$(patsubst $(shell cd $(XEN_ROOT) && > pwd)/%,%,$(D))" ]; then \ > echo 'EFI installation only partially done (EFI_VENDOR > not set)' >&2; \ > fi; \ > fi > _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |