2017-05-08 21:23:01 +08:00
|
|
|
#
|
2023-11-11 03:02:00 +08:00
|
|
|
# To run the demos when linked with a shared library (default) ensure that
|
|
|
|
# libcrypto is on the library path. For example:
|
2017-05-08 21:23:01 +08:00
|
|
|
#
|
|
|
|
# LD_LIBRARY_PATH=../.. ./aesccm
|
|
|
|
|
2023-11-11 03:02:00 +08:00
|
|
|
TESTS = aesccm \
|
|
|
|
aesgcm \
|
|
|
|
aeskeywrap \
|
|
|
|
ariacbc
|
2017-05-08 21:23:01 +08:00
|
|
|
|
2023-11-11 03:02:00 +08:00
|
|
|
CFLAGS = -I../../include -g -Wall
|
|
|
|
LDFLAGS = -L../..
|
|
|
|
LDLIBS = -lcrypto
|
2023-03-20 13:08:38 +08:00
|
|
|
|
|
|
|
all: $(TESTS)
|
2017-05-08 21:23:01 +08:00
|
|
|
|
|
|
|
aesccm: aesccm.o
|
|
|
|
aesgcm: aesgcm.o
|
2022-09-06 13:51:59 +08:00
|
|
|
aeskeywrap: aeskeywrap.o
|
2022-03-01 04:57:06 +08:00
|
|
|
ariacbc: ariacbc.o
|
2017-05-08 21:23:01 +08:00
|
|
|
|
2023-11-11 03:02:00 +08:00
|
|
|
$(TESTS):
|
|
|
|
$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $< $(LDLIBS)
|
2018-08-29 22:00:44 +08:00
|
|
|
|
|
|
|
clean:
|
2023-11-11 03:02:00 +08:00
|
|
|
$(RM) $(TESTS) *.o
|
2023-03-20 13:08:38 +08:00
|
|
|
|
|
|
|
.PHONY: test
|
|
|
|
test: all
|
|
|
|
@echo "\nCipher tests:"
|
|
|
|
@set -e; for tst in $(TESTS); do \
|
|
|
|
echo "\n"$$tst; \
|
|
|
|
LD_LIBRARY_PATH=../.. ./$$tst; \
|
|
|
|
done
|