[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [XEN PATCH 03/15] build, x86: clean build log for boot/ targets
On 23.05.2023 18:37, Anthony PERARD wrote: > We are adding %.lnk to .PRECIOUS or make treat them as intermediate > targets and remove them. What's wrong with them getting removed? Note also that's no different from today, so it's an orthogonal change in any event (unless I'm overlooking something). Plus if such behavior was intended, shouldn't $(targets) be made a prereq of .PRECIOUS in generic makefile logic? > Signed-off-by: Anthony PERARD <anthony.perard@xxxxxxxxxx> > --- > xen/arch/x86/boot/Makefile | 16 ++++++++++++---- > 1 file changed, 12 insertions(+), 4 deletions(-) > > diff --git a/xen/arch/x86/boot/Makefile b/xen/arch/x86/boot/Makefile > index 03d8ce3a9e..2693b938bd 100644 > --- a/xen/arch/x86/boot/Makefile > +++ b/xen/arch/x86/boot/Makefile > @@ -5,6 +5,8 @@ head-bin-objs := cmdline.o reloc.o > nocov-y += $(head-bin-objs) > noubsan-y += $(head-bin-objs) > targets += $(head-bin-objs) > +targets += $(head-bin-objs:.o=.bin) > +targets += $(head-bin-objs:.o=.lnk) Leaving aside the question of whether .lnk really should be part of $(targets), don't these two lines also ... > @@ -26,10 +28,16 @@ $(head-bin-objs): XEN_CFLAGS := $(CFLAGS_x86_32) -fpic > LDFLAGS_DIRECT-$(call ld-option,--warn-rwx-segments) := > --no-warn-rwx-segments > LDFLAGS_DIRECT += $(LDFLAGS_DIRECT-y) > > -%.bin: %.lnk > - $(OBJCOPY) -j .text -O binary $< $@ > +%.bin: OBJCOPYFLAGS := -j .text -O binary > +%.bin: %.lnk FORCE > + $(call if_changed,objcopy) > > -%.lnk: %.o $(src)/build32.lds > - $(LD) $(subst x86_64,i386,$(LDFLAGS_DIRECT)) -N -T $(filter %.lds,$^) > -o $@ $< > +quiet_cmd_ld_lnk_o = LD $@ > +cmd_ld_lnk_o = $(LD) $(subst x86_64,i386,$(LDFLAGS_DIRECT)) -N -T $(filter > %.lds,$^) -o $@ $< > + > +%.lnk: %.o $(src)/build32.lds FORCE > + $(call if_changed,ld_lnk_o) > > clean-files := *.lnk *.bin ... eliminate the need for this? Jan > + > +.PRECIOUS: %.lnk
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |