1
0
Fork 0

scsi: fix dependency bug in aic7 Makefile

Building the aic7xxx driver includes the copy
of an .h file from a _shipped file.

In a highly parallel build Ingo saw that the
build sometimes failed (included distcc usage).
It was tracked down to a missing dependency from the .c
source file to the generated .h file.
We started to build the .c file before the
copy (cat) operation of the .h file completed
and we then only got half of the definitions
from the copied .h file.

Add an explicit dependency from the .c files to the
generated .h files so make knows all dependencies and
finsih the build of the .h files before it starts
building the .o files.

Ingo tested this fix and reported:
good news: hundreds of successful kernel builds and no failures
overnight.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Acked-by: Ingo Molnar <mingo@elte.hu>
Acked-by: James Bottomley <James.Bottomley@HansenPartnership.com>
hifive-unleashed-5.1
Sam Ravnborg 2008-02-03 21:55:49 +01:00
parent ba3d05fb63
commit 8891fec65a
1 changed files with 2 additions and 7 deletions

View File

@ -44,13 +44,8 @@ clean-files += aic79xx_seq.h aic79xx_reg.h aic79xx_reg_print.c
# Dependencies for generated files need to be listed explicitly
$(obj)/aic7xxx_core.o: $(obj)/aic7xxx_seq.h
$(obj)/aic7xxx_core.o: $(obj)/aic7xxx_reg.h
$(obj)/aic79xx_core.o: $(obj)/aic79xx_seq.h
$(obj)/aic79xx_core.o: $(obj)/aic79xx_reg.h
$(addprefix $(obj)/,$(aic7xxx-y)): $(obj)/aic7xxx_seq.h
$(addprefix $(obj)/,$(aic79xx-y)): $(obj)/aic79xx_seq.h
$(addprefix $(src)/,$(aic7xxx-y:.o=.c)): $(obj)/aic7xxx_seq.h $(obj)/aic7xxx_reg.h
$(addprefix $(src)/,$(aic79xx-y:.o=.c)): $(obj)/aic79xx_seq.h $(obj)/aic79xx_reg.h
aic7xxx-gen-$(CONFIG_AIC7XXX_BUILD_FIRMWARE) := $(obj)/aic7xxx_reg.h
aic7xxx-gen-$(CONFIG_AIC7XXX_REG_PRETTY_PRINT) += $(obj)/aic7xxx_reg_print.c