[ltp] fix build failure with Argument too long issue

Signed-off-by: nietingting <nietingting@xiaomi.com>
This commit is contained in:
nietingting 2021-01-05 16:43:30 +08:00 committed by Xiang Xiao
parent ccf5bd28fd
commit c98330fed9

View File

@ -83,12 +83,10 @@ BLACKSRCS += 35-2-buildonly.c
MAINWORDS += "main(" MAINWORDS += "main("
LTP_ORIGINS := $(shell find $(TESTDIR) -name *.c) $(foreach word, $(BLACKWORDS), $(eval BLACKLIST+=$(shell find $(TESTDIR) -name *.c |xargs grep -lr $(word))))
$(foreach src, $(BLACKSRCS), $(eval BLACKLIST+=$(filter %$(src),$(shell find $(TESTDIR) -name *.c))))
$(foreach word, $(BLACKWORDS), $(eval BLACKLIST+=$(shell grep -lr $(word) $(LTP_ORIGINS)))) LTP_ORIGINS := $(filter-out $(BLACKLIST), $(shell find $(TESTDIR) -name *.c))
$(foreach src, $(BLACKSRCS), $(eval BLACKLIST+=$(filter %$(src),$(LTP_ORIGINS))))
LTP_ORIGINS := $(filter-out $(BLACKLIST), $(LTP_ORIGINS))
$(foreach word, $(MAINWORDS), $(eval LTP_MAINCSRCS+=$(shell grep -lr $(word) $(LTP_ORIGINS)))) $(foreach word, $(MAINWORDS), $(eval LTP_MAINCSRCS+=$(shell grep -lr $(word) $(LTP_ORIGINS))))
@ -109,8 +107,6 @@ $(LTP_UNPACK):
$(Q) echo "git clone $(LTP_URL)" $(Q) echo "git clone $(LTP_URL)"
$(Q) git clone $(LTP_URL) $(Q) git clone $(LTP_URL)
$(LTP_CSRCS): $(LTP_UNPACK)
context:: $(LTP_UNPACK) context:: $(LTP_UNPACK)
distclean:: distclean::