527 $1 := $$($1_ALL_COPY_TARGETS) $$($1_ALL_COPY_CLEAN_TARGETS) $$($1_BIN)/_the.$1_batch |
527 $1 := $$($1_ALL_COPY_TARGETS) $$($1_ALL_COPY_CLEAN_TARGETS) $$($1_BIN)/_the.$1_batch |
528 |
528 |
529 # When building in batch, put headers in a temp dir to filter out those that actually |
529 # When building in batch, put headers in a temp dir to filter out those that actually |
530 # changed before copying them to the real header dir. |
530 # changed before copying them to the real header dir. |
531 ifneq (,$$($1_HEADERS)) |
531 ifneq (,$$($1_HEADERS)) |
532 $1_HEADERS_ARG := -h $$($1_HEADERS).tmp |
532 $1_HEADERS_ARG := -h $$($1_HEADERS).$1.tmp |
533 |
533 |
534 $$($1_HEADERS)/_the.$1_headers: $$($1_BIN)/_the.$1_batch |
534 $$($1_HEADERS)/_the.$1_headers: $$($1_BIN)/_the.$1_batch |
535 $(MKDIR) -p $$(@D) |
535 $(MKDIR) -p $$(@D) |
536 for f in `ls $$($1_HEADERS).tmp`; do \ |
536 for f in `ls $$($1_HEADERS).$1.tmp`; do \ |
537 if [ ! -f "$$($1_HEADERS)/$$$$f" ] || [ "`$(DIFF) $$($1_HEADERS)/$$$$f $$($1_HEADERS).tmp/$$$$f`" != "" ]; then \ |
537 if [ ! -f "$$($1_HEADERS)/$$$$f" ] || [ "`$(DIFF) $$($1_HEADERS)/$$$$f $$($1_HEADERS).$1.tmp/$$$$f`" != "" ]; then \ |
538 $(CP) -f $$($1_HEADERS).tmp/$$$$f $$($1_HEADERS)/$$$$f; \ |
538 $(CP) -f $$($1_HEADERS).$1.tmp/$$$$f $$($1_HEADERS)/$$$$f; \ |
539 fi; \ |
539 fi; \ |
540 done |
540 done |
541 $(RM) -r $$($1_HEADERS).tmp |
541 $(RM) -r $$($1_HEADERS).$1.tmp |
542 $(TOUCH) $$@ |
542 $(TOUCH) $$@ |
543 |
543 |
544 $1 += $$($1_HEADERS)/_the.$1_headers |
544 $1 += $$($1_HEADERS)/_the.$1_headers |
545 endif |
545 endif |
546 |
546 |