|
@@ -32,7 +32,7 @@ CFLAGS = -O2 -DUSE_LTM -DLTM_DESC -I../libtommath
|
|
EXTRALIBS = ../libtommath/libtommath.a
|
|
EXTRALIBS = ../libtommath/libtommath.a
|
|
|
|
|
|
#Compilation flags
|
|
#Compilation flags
|
|
-LTC_CFLAGS = $(CFLAGS) -Isrc/headers -Itestprof -DLTC_SOURCE
|
|
|
|
|
|
+LTC_CFLAGS = $(CFLAGS) -Isrc/headers -Itests -DLTC_SOURCE
|
|
LTC_LDFLAGS = $(LDFLAGS) $(EXTRALIBS)
|
|
LTC_LDFLAGS = $(LDFLAGS) $(EXTRALIBS)
|
|
VERSION=1.17
|
|
VERSION=1.17
|
|
|
|
|
|
@@ -192,12 +192,11 @@ src/stream/rc4/rc4.o src/stream/rc4/rc4_test.o src/stream/sober128/sober128.o \
|
|
src/stream/sober128/sober128_test.o
|
|
src/stream/sober128/sober128_test.o
|
|
|
|
|
|
#List of test objects to compile (all goes to libtomcrypt_prof.a)
|
|
#List of test objects to compile (all goes to libtomcrypt_prof.a)
|
|
-TOBJECTS=testprof/base64_test.o testprof/cipher_hash_test.o testprof/common.o testprof/der_tests.o \
|
|
|
|
-testprof/dh_test.o testprof/dsa_test.o testprof/ecc_test.o testprof/file_test.o testprof/katja_test.o \
|
|
|
|
-testprof/mac_test.o testprof/misc_test.o testprof/modes_test.o testprof/multi_test.o testprof/no_prng.o \
|
|
|
|
-testprof/pkcs_1_eme_test.o testprof/pkcs_1_emsa_test.o testprof/pkcs_1_oaep_test.o \
|
|
|
|
-testprof/pkcs_1_pss_test.o testprof/pkcs_1_test.o testprof/rotate_test.o testprof/rsa_test.o \
|
|
|
|
-testprof/store_test.o testprof/test.o
|
|
|
|
|
|
+TOBJECTS=tests/base64_test.o tests/cipher_hash_test.o tests/common.o tests/der_tests.o tests/dh_test.o \
|
|
|
|
+tests/dsa_test.o tests/ecc_test.o tests/file_test.o tests/katja_test.o tests/mac_test.o tests/misc_test.o \
|
|
|
|
+tests/modes_test.o tests/multi_test.o tests/no_prng.o tests/pkcs_1_eme_test.o tests/pkcs_1_emsa_test.o \
|
|
|
|
+tests/pkcs_1_oaep_test.o tests/pkcs_1_pss_test.o tests/pkcs_1_test.o tests/rotate_test.o \
|
|
|
|
+tests/rsa_test.o tests/store_test.o tests/test.o
|
|
|
|
|
|
#The following headers will be installed by "make install"
|
|
#The following headers will be installed by "make install"
|
|
HEADERS=src/headers/tomcrypt.h src/headers/tomcrypt_argchk.h src/headers/tomcrypt_cfg.h \
|
|
HEADERS=src/headers/tomcrypt.h src/headers/tomcrypt_argchk.h src/headers/tomcrypt_cfg.h \
|
|
@@ -224,7 +223,7 @@ src/hashes/sha2/sha256.o: src/hashes/sha2/sha256.c src/hashes/sha2/sha224.c
|
|
|
|
|
|
#Dependencies on *.h
|
|
#Dependencies on *.h
|
|
$(OBJECTS): $(HEADERS)
|
|
$(OBJECTS): $(HEADERS)
|
|
-$(TOBJECTS): $(HEADERS) testprof/tomcrypt_test.h
|
|
|
|
|
|
+$(TOBJECTS): $(HEADERS) tests/tomcrypt_test.h
|
|
|
|
|
|
#This is necessary for compatibility with BSD make (namely on OpenBSD)
|
|
#This is necessary for compatibility with BSD make (namely on OpenBSD)
|
|
.SUFFIXES: .o .c
|
|
.SUFFIXES: .o .c
|
|
@@ -237,18 +236,18 @@ $(LIBMAIN_S): $(OBJECTS)
|
|
$(RANLIB) $@
|
|
$(RANLIB) $@
|
|
|
|
|
|
#Demo tools/utilities
|
|
#Demo tools/utilities
|
|
-hashsum: demos/hashsum.o testprof/common.o $(LIBMAIN_S)
|
|
|
|
- $(CC) demos/hashsum.o testprof/common.o $(LIBMAIN_S) $(LTC_LDFLAGS) -o $@
|
|
|
|
-ltcrypt: demos/ltcrypt.o testprof/common.o $(LIBMAIN_S)
|
|
|
|
- $(CC) demos/ltcrypt.o testprof/common.o $(LIBMAIN_S) $(LTC_LDFLAGS) -o $@
|
|
|
|
-small: demos/small.o testprof/common.o $(LIBMAIN_S)
|
|
|
|
- $(CC) demos/small.o testprof/common.o $(LIBMAIN_S) $(LTC_LDFLAGS) -o $@
|
|
|
|
-tv_gen: demos/tv_gen.o testprof/common.o $(LIBMAIN_S)
|
|
|
|
- $(CC) demos/tv_gen.o testprof/common.o $(LIBMAIN_S) $(LTC_LDFLAGS) -o $@
|
|
|
|
|
|
+hashsum: demos/hashsum.o tests/common.o $(LIBMAIN_S)
|
|
|
|
+ $(CC) demos/hashsum.o tests/common.o $(LIBMAIN_S) $(LTC_LDFLAGS) -o $@
|
|
|
|
+ltcrypt: demos/ltcrypt.o tests/common.o $(LIBMAIN_S)
|
|
|
|
+ $(CC) demos/ltcrypt.o tests/common.o $(LIBMAIN_S) $(LTC_LDFLAGS) -o $@
|
|
|
|
+small: demos/small.o tests/common.o $(LIBMAIN_S)
|
|
|
|
+ $(CC) demos/small.o tests/common.o $(LIBMAIN_S) $(LTC_LDFLAGS) -o $@
|
|
|
|
+tv_gen: demos/tv_gen.o tests/common.o $(LIBMAIN_S)
|
|
|
|
+ $(CC) demos/tv_gen.o tests/common.o $(LIBMAIN_S) $(LTC_LDFLAGS) -o $@
|
|
|
|
|
|
#Tests + timing tests
|
|
#Tests + timing tests
|
|
-timing: demos/timing.o $(LIBMAIN_S) testprof/common.o
|
|
|
|
- $(CC) demos/timing.o $(LIBMAIN_S) testprof/common.o $(LTC_LDFLAGS) -o $@
|
|
|
|
|
|
+timing: demos/timing.o $(LIBMAIN_S) tests/common.o
|
|
|
|
+ $(CC) demos/timing.o $(LIBMAIN_S) tests/common.o $(LTC_LDFLAGS) -o $@
|
|
@echo "NOTICE: start the timing tests by: ./timing"
|
|
@echo "NOTICE: start the timing tests by: ./timing"
|
|
test: $(TOBJECTS) $(LIBMAIN_S)
|
|
test: $(TOBJECTS) $(LIBMAIN_S)
|
|
$(CC) $(TOBJECTS) $(LIBMAIN_S) $(LTC_LDFLAGS) -o $@
|
|
$(CC) $(TOBJECTS) $(LIBMAIN_S) $(LTC_LDFLAGS) -o $@
|