mirror of
https://git.suyu.dev/suyu/mbedtls.git
synced 2026-01-07 15:09:28 +01:00
mbed-os test code generator
This commit is contained in:
parent
1f29be7241
commit
fff4904e6b
6 changed files with 1821 additions and 9 deletions
|
|
@ -2,7 +2,7 @@
|
|||
# To compile on SunOS: add "-lsocket -lnsl" to LDFLAGS
|
||||
# To compile with PKCS11: add "-lpkcs11-helper" to LDFLAGS
|
||||
|
||||
CFLAGS ?= -O2
|
||||
CFLAGS ?= -g3 #-O2
|
||||
WARNING_CFLAGS ?= -Wall -W -Wdeclaration-after-statement -Wno-unused-function -Wno-unused-value
|
||||
LDFLAGS ?=
|
||||
|
||||
|
|
@ -184,9 +184,16 @@ $(DEP):
|
|||
C_FILES := $(addsuffix .c,$(APPS))
|
||||
|
||||
.SECONDEXPANSION:
|
||||
$(C_FILES): %.c: suites/$$(func.$$*).function suites/%.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
|
||||
$(C_FILES): %.c: suites/$$(func.$$*).function suites/%.data scripts/gen_mbed_code.py suites/helpers.function suites/mbed_test.function suites/desktop_test.function
|
||||
echo " Gen $@"
|
||||
perl scripts/generate_code.pl suites $(func.$*) $*
|
||||
# perl scripts/generate_code.pl suites $(func.$*) $*
|
||||
python scripts/gen_mbed_code.py -f suites/$(func.$*).function \
|
||||
-d suites/$*.data \
|
||||
-t suites/mbed_test.function \
|
||||
-p suites/desktop_test.function \
|
||||
-s suites \
|
||||
--help-file suites/helpers.function \
|
||||
-o .
|
||||
|
||||
|
||||
$(BINARIES): %$(EXEXT): %.c $(DEP)
|
||||
|
|
@ -199,9 +206,9 @@ all: $(BINARIES)
|
|||
|
||||
clean:
|
||||
ifndef WINDOWS
|
||||
rm -rf $(APPS) *.c TESTS
|
||||
rm -rf $(APPS) *.c *.data TESTS
|
||||
else
|
||||
del /Q /F *.c *.exe
|
||||
del /Q /F *.c *.exe *.data
|
||||
rmdir /Q /S TESTS
|
||||
endif
|
||||
|
||||
|
|
@ -221,14 +228,15 @@ MBED_APPS := $(addprefix mbed_,$(APPS))
|
|||
# name is used as the test group dir.
|
||||
|
||||
.SECONDEXPANSION:
|
||||
$(MBED_APPS): mbed_%: suites/$$(func.$$*).function suites/%.data scripts/gen_mbed_code.py suites/helpers.function suites/main_test.function
|
||||
echo " Gen ./TESTS/mbedtls/$*/main.c"
|
||||
$(MBED_APPS): mbed_%: suites/$$(func.$$*).function suites/%.data scripts/gen_mbed_code.py suites/helpers.function suites/mbed_test.function suites/embedded_test.function
|
||||
echo " Gen ./TESTS/mbedtls/$*/$*.c"
|
||||
python scripts/gen_mbed_code.py -f suites/$(func.$*).function \
|
||||
-d suites/$*.data \
|
||||
-t suites/mbed_test.function \
|
||||
-p suites/embedded_test.function \
|
||||
-s suites \
|
||||
--help-file suites/helpers.function \
|
||||
-o ./TESTS
|
||||
-o ./TESTS/mbedtls/$*
|
||||
|
||||
gen-mbed-test: $(MBED_APPS)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue