[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH v2 2/2] x86emul/test: avoid race in link farm rune
Several `ln -sf` can race with each other. Provide dedicated targets for soft-linking directories. Signed-off-by: Wei Liu <wei.liu2@xxxxxxxxxx> --- tools/tests/x86_emulator/Makefile | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/tools/tests/x86_emulator/Makefile b/tools/tests/x86_emulator/Makefile index 9bf36947c0..6fa0b6c803 100644 --- a/tools/tests/x86_emulator/Makefile +++ b/tools/tests/x86_emulator/Makefile @@ -40,16 +40,17 @@ distclean: clean .PHONY: install install: -x86_emulate/x86_emulate.c x86_emulate/x86_emulate.h: - [ -L x86_emulate ] || ln -sf $(XEN_ROOT)/xen/arch/x86/x86_emulate . +x86_emulate: + [ -L $@ ] || ln -sf $(XEN_ROOT)/xen/arch/x86/$@ . -asm/x86-vendors.h asm/x86-defns.h asm/msr-index.h: - [ -L asm ] || ln -sf $(XEN_ROOT)/xen/include/asm-x86 asm +x86_emulate/x86_emulate.c x86_emulate/x86_emulate.h: x86_emulate + +asm: + [ -L $@ ] || ln -sf $(XEN_ROOT)/xen/include/asm-x86 $@ HOSTCFLAGS += $(CFLAGS_xeninclude) -I. -x86.h := asm/x86-vendors.h asm/x86-defns.h asm/msr-index.h -x86_emulate.h := x86_emulate.h x86_emulate/x86_emulate.h $(x86.h) +x86_emulate.h := x86_emulate.h x86_emulate/x86_emulate.h asm x86_emulate.o: x86_emulate.c x86_emulate/x86_emulate.c $(x86_emulate.h) $(HOSTCC) $(HOSTCFLAGS) -D__XEN_TOOLS__ -c -g -o $@ $< -- 2.11.0 _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx https://lists.xen.org/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |