blob: 90b2028f5244094c7e5de23f19f38af0432c18e2 [file] [log] [blame]
Paul Bakker0049c2f2009-07-11 19:15:43 +00001
2# To compile on SunOS: add "-lsocket -lnsl" to LDFLAGS
Paul Bakker43b7e352011-01-18 15:27:19 +00003# To compile with PKCS11: add "-lpkcs11-helper" to LDFLAGS
Paul Bakker0049c2f2009-07-11 19:15:43 +00004
Alon Bar-Levf7a9f302015-02-18 17:55:05 +02005CFLAGS ?= -O2
6WARNING_CFLAGS ?= -Wall -W -Wdeclaration-after-statement -Wno-unused-function -Wno-unused-value
Alon Bar-Levada41052015-02-18 17:47:52 +02007LDFLAGS ?=
Paul Bakker0049c2f2009-07-11 19:15:43 +00008
Alon Bar-Levf7a9f302015-02-18 17:55:05 +02009LOCAL_CFLAGS = $(WARNING_CFLAGS) -I../include -D_FILE_OFFSET_BITS=64
Manuel Pégourié-Gonnard5c59a4f2015-06-24 13:06:24 +020010LOCAL_LDFLAGS = -L../library \
Manuel Pégourié-Gonnard21e1ac22015-06-25 08:45:12 +020011 -lmbedtls$(SHARED_SUFFIX) \
Manuel Pégourié-Gonnard5c59a4f2015-06-24 13:06:24 +020012 -lmbedx509$(SHARED_SUFFIX) \
Manuel Pégourié-Gonnard21e1ac22015-06-25 08:45:12 +020013 -lmbedcrypto$(SHARED_SUFFIX)
Paul Bakker0049c2f2009-07-11 19:15:43 +000014
Paul Bakker674e0b02014-03-26 13:26:52 +010015ifndef SHARED
Manuel Pégourié-Gonnard5c59a4f2015-06-24 13:06:24 +020016DEP=../library/libmbedcrypto.a ../library/libmbedx509.a ../library/libmbedtls.a
Paul Bakker674e0b02014-03-26 13:26:52 +010017else
Manuel Pégourié-Gonnard5c59a4f2015-06-24 13:06:24 +020018DEP=../library/libmbedcrypto.$(DLEXT) ../library/libmbedx509.$(DLEXT) ../library/libmbedtls.$(DLEXT)
Paul Bakker674e0b02014-03-26 13:26:52 +010019endif
20
Paul Bakkerc7ffd362012-04-05 12:08:29 +000021ifdef DEBUG
Alon Bar-Levf7a9f302015-02-18 17:55:05 +020022LOCAL_CFLAGS += -g3
Paul Bakkerc7ffd362012-04-05 12:08:29 +000023endif
24
Manuel Pégourié-Gonnard5c59a4f2015-06-24 13:06:24 +020025# if we're running on Windows, build for Windows
Paul Bakkercd5b5292012-05-10 20:49:10 +000026ifdef WINDOWS
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +020027WINDOWS_BUILD=1
28endif
29
30ifdef WINDOWS_BUILD
31DLEXT=dll
32EXEXT=.exe
Alon Bar-Levada41052015-02-18 17:47:52 +020033LOCAL_LDFLAGS += -lws2_32
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +020034ifdef SHARED
35SHARED_SUFFIX=.$(DLEXT)
36endif
Manuel Pégourié-Gonnard8d4a6132015-06-24 12:16:20 +020037else
Andres Amaya Garcia420f0cc2018-03-27 19:17:21 +010038DLEXT ?= so
Manuel Pégourié-Gonnard8d4a6132015-06-24 12:16:20 +020039EXEXT=
40SHARED_SUFFIX=
Paul Bakkercd5b5292012-05-10 20:49:10 +000041endif
42
Paul Bakker2770fbd2012-07-03 13:30:23 +000043# Zlib shared library extensions:
44ifdef ZLIB
Alon Bar-Levada41052015-02-18 17:47:52 +020045LOCAL_LDFLAGS += -lz
Paul Bakker2770fbd2012-07-03 13:30:23 +000046endif
47
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +020048APPS = test_suite_aes.ecb$(EXEXT) test_suite_aes.cbc$(EXEXT) \
49 test_suite_aes.cfb$(EXEXT) test_suite_aes.rest$(EXEXT) \
50 test_suite_arc4$(EXEXT) test_suite_asn1write$(EXEXT) \
51 test_suite_base64$(EXEXT) test_suite_blowfish$(EXEXT) \
52 test_suite_camellia$(EXEXT) test_suite_ccm$(EXEXT) \
Daniel King34b822c2016-05-15 17:28:08 -030053 test_suite_chacha20$(EXEXT) test_suite_cmac$(EXEXT) \
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +020054 test_suite_cipher.aes$(EXEXT) \
55 test_suite_cipher.arc4$(EXEXT) test_suite_cipher.ccm$(EXEXT) \
Daniel Kingbd920622016-05-15 19:56:20 -030056 test_suite_cipher.chacha20$(EXEXT) \
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +020057 test_suite_cipher.gcm$(EXEXT) \
58 test_suite_cipher.blowfish$(EXEXT) \
59 test_suite_cipher.camellia$(EXEXT) \
60 test_suite_cipher.des$(EXEXT) test_suite_cipher.null$(EXEXT) \
61 test_suite_cipher.padding$(EXEXT) \
62 test_suite_ctr_drbg$(EXEXT) test_suite_debug$(EXEXT) \
63 test_suite_des$(EXEXT) test_suite_dhm$(EXEXT) \
64 test_suite_ecdh$(EXEXT) test_suite_ecdsa$(EXEXT) \
Manuel Pégourié-Gonnard4d8685b2015-08-05 15:44:42 +020065 test_suite_ecjpake$(EXEXT) test_suite_ecp$(EXEXT) \
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +020066 test_suite_error$(EXEXT) test_suite_entropy$(EXEXT) \
67 test_suite_gcm.aes128_de$(EXEXT) \
68 test_suite_gcm.aes192_de$(EXEXT) \
69 test_suite_gcm.aes256_de$(EXEXT) \
70 test_suite_gcm.aes128_en$(EXEXT) \
71 test_suite_gcm.aes192_en$(EXEXT) \
72 test_suite_gcm.aes256_en$(EXEXT) \
Manuel Pégourié-Gonnardec4a3392015-03-24 16:59:49 +010073 test_suite_gcm.camellia$(EXEXT) \
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +020074 test_suite_hmac_drbg.misc$(EXEXT) \
75 test_suite_hmac_drbg.no_reseed$(EXEXT) \
76 test_suite_hmac_drbg.nopr$(EXEXT) \
77 test_suite_hmac_drbg.pr$(EXEXT) \
78 test_suite_md$(EXEXT) test_suite_mdx$(EXEXT) \
79 test_suite_memory_buffer_alloc$(EXEXT) \
Manuel Pégourié-Gonnardb6b16bd2015-03-11 11:20:43 +000080 test_suite_mpi$(EXEXT) \
Simon Butcherf8758b82016-04-12 11:31:00 +010081 test_suite_pem$(EXEXT) test_suite_pkcs1_v15$(EXEXT) \
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +020082 test_suite_pkcs1_v21$(EXEXT) test_suite_pkcs5$(EXEXT) \
83 test_suite_pkparse$(EXEXT) test_suite_pkwrite$(EXEXT) \
84 test_suite_pk$(EXEXT) \
Daniel Kingadc32c02016-05-16 18:25:45 -030085 test_suite_poly1305$(EXEXT) \
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +020086 test_suite_rsa$(EXEXT) test_suite_shax$(EXEXT) \
Paul Bakker50157ff2016-07-19 14:57:00 +010087 test_suite_ssl$(EXEXT) test_suite_timing$(EXEXT) \
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +020088 test_suite_x509parse$(EXEXT) test_suite_x509write$(EXEXT) \
89 test_suite_xtea$(EXEXT) test_suite_version$(EXEXT)
Paul Bakker0049c2f2009-07-11 19:15:43 +000090
91.SILENT:
92
Manuel Pégourié-Gonnard5c59a4f2015-06-24 13:06:24 +020093.PHONY: all check test clean
94
Paul Bakker0049c2f2009-07-11 19:15:43 +000095all: $(APPS)
96
Manuel Pégourié-Gonnard5c59a4f2015-06-24 13:06:24 +020097$(DEP):
Manuel Pégourié-Gonnardfc367082015-06-26 16:50:24 +020098 $(MAKE) -C ../library
Manuel Pégourié-Gonnard5c59a4f2015-06-24 13:06:24 +020099
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200100# invoke perl explicitly for the sake of mingw32-make
101
Paul Bakker19343182013-08-16 13:31:10 +0200102test_suite_aes.ecb.c : suites/test_suite_aes.function suites/test_suite_aes.ecb.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100103 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200104 perl scripts/generate_code.pl suites test_suite_aes test_suite_aes.ecb
Paul Bakker286bf3c2013-04-08 18:09:51 +0200105
Paul Bakker19343182013-08-16 13:31:10 +0200106test_suite_aes.cbc.c : suites/test_suite_aes.function suites/test_suite_aes.cbc.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100107 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200108 perl scripts/generate_code.pl suites test_suite_aes test_suite_aes.cbc
Paul Bakker286bf3c2013-04-08 18:09:51 +0200109
Paul Bakker19343182013-08-16 13:31:10 +0200110test_suite_aes.cfb.c : suites/test_suite_aes.function suites/test_suite_aes.cfb.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100111 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200112 perl scripts/generate_code.pl suites test_suite_aes test_suite_aes.cfb
Paul Bakker286bf3c2013-04-08 18:09:51 +0200113
Paul Bakker19343182013-08-16 13:31:10 +0200114test_suite_aes.rest.c : suites/test_suite_aes.function suites/test_suite_aes.rest.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100115 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200116 perl scripts/generate_code.pl suites test_suite_aes test_suite_aes.rest
Paul Bakker286bf3c2013-04-08 18:09:51 +0200117
Paul Bakker19343182013-08-16 13:31:10 +0200118test_suite_cipher.aes.c : suites/test_suite_cipher.function suites/test_suite_cipher.aes.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100119 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200120 perl scripts/generate_code.pl suites test_suite_cipher test_suite_cipher.aes
Paul Bakker46c17942011-07-13 14:54:54 +0000121
Manuel Pégourié-Gonnard37e230c2013-08-28 13:50:42 +0200122test_suite_cipher.arc4.c : suites/test_suite_cipher.function suites/test_suite_cipher.arc4.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100123 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200124 perl scripts/generate_code.pl suites test_suite_cipher test_suite_cipher.arc4
Manuel Pégourié-Gonnard37e230c2013-08-28 13:50:42 +0200125
Manuel Pégourié-Gonnard542eac52014-05-15 16:03:07 +0200126test_suite_cipher.ccm.c : suites/test_suite_cipher.function suites/test_suite_cipher.ccm.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100127 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200128 perl scripts/generate_code.pl suites test_suite_cipher test_suite_cipher.ccm
Manuel Pégourié-Gonnard542eac52014-05-15 16:03:07 +0200129
Daniel Kingbd920622016-05-15 19:56:20 -0300130test_suite_cipher.chacha20.c : suites/test_suite_cipher.function suites/test_suite_cipher.chacha20.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
131 echo " Gen $@"
132 perl scripts/generate_code.pl suites test_suite_cipher test_suite_cipher.chacha20
133
Manuel Pégourié-Gonnard07f8fa52013-08-30 18:34:08 +0200134test_suite_cipher.gcm.c : suites/test_suite_cipher.function suites/test_suite_cipher.gcm.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100135 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200136 perl scripts/generate_code.pl suites test_suite_cipher test_suite_cipher.gcm
Manuel Pégourié-Gonnard07f8fa52013-08-30 18:34:08 +0200137
Paul Bakker19343182013-08-16 13:31:10 +0200138test_suite_cipher.blowfish.c : suites/test_suite_cipher.function suites/test_suite_cipher.blowfish.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100139 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200140 perl scripts/generate_code.pl suites test_suite_cipher test_suite_cipher.blowfish
Paul Bakker6132d0a2012-07-04 17:10:40 +0000141
Paul Bakker19343182013-08-16 13:31:10 +0200142test_suite_cipher.camellia.c : suites/test_suite_cipher.function suites/test_suite_cipher.camellia.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100143 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200144 perl scripts/generate_code.pl suites test_suite_cipher test_suite_cipher.camellia
Paul Bakker46c17942011-07-13 14:54:54 +0000145
Paul Bakker19343182013-08-16 13:31:10 +0200146test_suite_cipher.des.c : suites/test_suite_cipher.function suites/test_suite_cipher.des.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100147 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200148 perl scripts/generate_code.pl suites test_suite_cipher test_suite_cipher.des
Paul Bakker46c17942011-07-13 14:54:54 +0000149
Paul Bakker19343182013-08-16 13:31:10 +0200150test_suite_cipher.null.c : suites/test_suite_cipher.function suites/test_suite_cipher.null.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100151 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200152 perl scripts/generate_code.pl suites test_suite_cipher test_suite_cipher.null
Paul Bakkerfab5c822012-02-06 16:45:10 +0000153
Paul Bakker19343182013-08-16 13:31:10 +0200154test_suite_cipher.padding.c : suites/test_suite_cipher.function suites/test_suite_cipher.padding.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100155 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200156 perl scripts/generate_code.pl suites test_suite_cipher test_suite_cipher.padding
Manuel Pégourié-Gonnardd5fdcaf2013-07-24 18:05:00 +0200157
Manuel Pégourié-Gonnard94dd5b42013-10-24 11:57:47 +0200158test_suite_gcm.aes128_de.c : suites/test_suite_gcm.function suites/test_suite_gcm.aes128_de.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100159 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200160 perl scripts/generate_code.pl suites test_suite_gcm test_suite_gcm.aes128_de
Paul Bakker89e80c92012-03-20 13:50:09 +0000161
Manuel Pégourié-Gonnard94dd5b42013-10-24 11:57:47 +0200162test_suite_gcm.aes192_de.c : suites/test_suite_gcm.function suites/test_suite_gcm.aes192_de.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100163 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200164 perl scripts/generate_code.pl suites test_suite_gcm test_suite_gcm.aes192_de
Paul Bakker286bf3c2013-04-08 18:09:51 +0200165
Manuel Pégourié-Gonnard94dd5b42013-10-24 11:57:47 +0200166test_suite_gcm.aes256_de.c : suites/test_suite_gcm.function suites/test_suite_gcm.aes256_de.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100167 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200168 perl scripts/generate_code.pl suites test_suite_gcm test_suite_gcm.aes256_de
Paul Bakker286bf3c2013-04-08 18:09:51 +0200169
Manuel Pégourié-Gonnard94dd5b42013-10-24 11:57:47 +0200170test_suite_gcm.aes128_en.c : suites/test_suite_gcm.function suites/test_suite_gcm.aes128_en.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100171 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200172 perl scripts/generate_code.pl suites test_suite_gcm test_suite_gcm.aes128_en
Paul Bakker286bf3c2013-04-08 18:09:51 +0200173
Manuel Pégourié-Gonnard94dd5b42013-10-24 11:57:47 +0200174test_suite_gcm.aes192_en.c : suites/test_suite_gcm.function suites/test_suite_gcm.aes192_en.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100175 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200176 perl scripts/generate_code.pl suites test_suite_gcm test_suite_gcm.aes192_en
Paul Bakker286bf3c2013-04-08 18:09:51 +0200177
Manuel Pégourié-Gonnard94dd5b42013-10-24 11:57:47 +0200178test_suite_gcm.aes256_en.c : suites/test_suite_gcm.function suites/test_suite_gcm.aes256_en.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100179 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200180 perl scripts/generate_code.pl suites test_suite_gcm test_suite_gcm.aes256_en
Paul Bakker89e80c92012-03-20 13:50:09 +0000181
Manuel Pégourié-Gonnard13e0d442013-10-24 12:59:00 +0200182test_suite_gcm.camellia.c : suites/test_suite_gcm.function suites/test_suite_gcm.camellia.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100183 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200184 perl scripts/generate_code.pl suites test_suite_gcm test_suite_gcm.camellia
Paul Bakker0049c2f2009-07-11 19:15:43 +0000185
Manuel Pégourié-Gonnard48bc3e82014-01-30 21:11:16 +0100186test_suite_hmac_drbg.misc.c : suites/test_suite_hmac_drbg.function suites/test_suite_hmac_drbg.misc.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100187 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200188 perl scripts/generate_code.pl suites test_suite_hmac_drbg test_suite_hmac_drbg.misc
Manuel Pégourié-Gonnard48bc3e82014-01-30 21:11:16 +0100189
Manuel Pégourié-Gonnard6801f392014-01-30 17:22:14 +0100190test_suite_hmac_drbg.no_reseed.c : suites/test_suite_hmac_drbg.function suites/test_suite_hmac_drbg.no_reseed.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100191 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200192 perl scripts/generate_code.pl suites test_suite_hmac_drbg test_suite_hmac_drbg.no_reseed
Manuel Pégourié-Gonnard6801f392014-01-30 17:22:14 +0100193
Manuel Pégourié-Gonnard24600b72014-01-31 09:54:14 +0100194test_suite_hmac_drbg.nopr.c : suites/test_suite_hmac_drbg.function suites/test_suite_hmac_drbg.nopr.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100195 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200196 perl scripts/generate_code.pl suites test_suite_hmac_drbg test_suite_hmac_drbg.nopr
Manuel Pégourié-Gonnard24600b72014-01-31 09:54:14 +0100197
Manuel Pégourié-Gonnard62273b82014-01-31 10:16:57 +0100198test_suite_hmac_drbg.pr.c : suites/test_suite_hmac_drbg.function suites/test_suite_hmac_drbg.pr.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100199 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200200 perl scripts/generate_code.pl suites test_suite_hmac_drbg test_suite_hmac_drbg.pr
Manuel Pégourié-Gonnard62273b82014-01-31 10:16:57 +0100201
Paul Bakker19343182013-08-16 13:31:10 +0200202%.c : suites/%.function suites/%.data scripts/generate_code.pl suites/helpers.function suites/main_test.function
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100203 echo " Gen $@"
Manuel Pégourié-Gonnard6cacde22015-07-08 16:02:43 +0200204 perl scripts/generate_code.pl suites $* $*
Paul Bakker0049c2f2009-07-11 19:15:43 +0000205
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200206test_suite_aes.ecb$(EXEXT): test_suite_aes.ecb.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100207 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200208 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker286bf3c2013-04-08 18:09:51 +0200209
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200210test_suite_aes.cbc$(EXEXT): test_suite_aes.cbc.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100211 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200212 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker286bf3c2013-04-08 18:09:51 +0200213
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200214test_suite_aes.cfb$(EXEXT): test_suite_aes.cfb.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100215 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200216 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker286bf3c2013-04-08 18:09:51 +0200217
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200218test_suite_aes.rest$(EXEXT): test_suite_aes.rest.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100219 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200220 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker0049c2f2009-07-11 19:15:43 +0000221
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200222test_suite_arc4$(EXEXT): test_suite_arc4.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100223 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200224 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker0049c2f2009-07-11 19:15:43 +0000225
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200226test_suite_asn1write$(EXEXT): test_suite_asn1write.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100227 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200228 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Manuel Pégourié-Gonnard36178ff2014-05-29 14:26:03 +0200229
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200230test_suite_base64$(EXEXT): test_suite_base64.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100231 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200232 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker0049c2f2009-07-11 19:15:43 +0000233
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200234test_suite_blowfish$(EXEXT): test_suite_blowfish.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100235 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200236 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakkera9379c02012-07-04 11:02:11 +0000237
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200238test_suite_camellia$(EXEXT): test_suite_camellia.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100239 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200240 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker0049c2f2009-07-11 19:15:43 +0000241
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200242test_suite_ccm$(EXEXT): test_suite_ccm.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100243 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200244 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Manuel Pégourié-Gonnarda6916fa2014-05-02 15:17:29 +0200245
Daniel King34b822c2016-05-15 17:28:08 -0300246test_suite_chacha20$(EXEXT): test_suite_chacha20.c $(DEP)
247 echo " CC $<"
248 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
249
Simon Butcherd812fa62016-10-05 14:13:31 +0100250test_suite_cmac$(EXEXT): test_suite_cmac.c $(DEP)
251 echo " CC $<"
252 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
253
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200254test_suite_cipher.aes$(EXEXT): test_suite_cipher.aes.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100255 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200256 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker46c17942011-07-13 14:54:54 +0000257
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200258test_suite_cipher.arc4$(EXEXT): test_suite_cipher.arc4.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100259 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200260 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Manuel Pégourié-Gonnard37e230c2013-08-28 13:50:42 +0200261
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200262test_suite_cipher.ccm$(EXEXT): test_suite_cipher.ccm.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100263 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200264 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Manuel Pégourié-Gonnard542eac52014-05-15 16:03:07 +0200265
Daniel Kingbd920622016-05-15 19:56:20 -0300266test_suite_cipher.chacha20$(EXEXT): test_suite_cipher.chacha20.c $(DEP)
267 echo " CC $<"
268 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
269
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200270test_suite_cipher.gcm$(EXEXT): test_suite_cipher.gcm.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100271 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200272 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Manuel Pégourié-Gonnard07f8fa52013-08-30 18:34:08 +0200273
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200274test_suite_cipher.blowfish$(EXEXT): test_suite_cipher.blowfish.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100275 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200276 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker6132d0a2012-07-04 17:10:40 +0000277
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200278test_suite_cipher.camellia$(EXEXT): test_suite_cipher.camellia.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100279 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200280 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker46c17942011-07-13 14:54:54 +0000281
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200282test_suite_cipher.des$(EXEXT): test_suite_cipher.des.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100283 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200284 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker0e04d0e2011-11-27 14:46:59 +0000285
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200286test_suite_cipher.null$(EXEXT): test_suite_cipher.null.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100287 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200288 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakkerfab5c822012-02-06 16:45:10 +0000289
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200290test_suite_cipher.padding$(EXEXT): test_suite_cipher.padding.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100291 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200292 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Manuel Pégourié-Gonnardd5fdcaf2013-07-24 18:05:00 +0200293
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200294test_suite_ctr_drbg$(EXEXT): test_suite_ctr_drbg.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100295 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200296 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker8123e9d2011-01-06 15:37:30 +0000297
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200298test_suite_des$(EXEXT): test_suite_des.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100299 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200300 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker0049c2f2009-07-11 19:15:43 +0000301
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200302test_suite_dhm$(EXEXT): test_suite_dhm.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100303 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200304 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker0049c2f2009-07-11 19:15:43 +0000305
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200306test_suite_ecdh$(EXEXT): test_suite_ecdh.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100307 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200308 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakkerd589a0d2013-03-13 16:30:17 +0100309
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200310test_suite_ecdsa$(EXEXT): test_suite_ecdsa.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100311 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200312 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakkerd589a0d2013-03-13 16:30:17 +0100313
Manuel Pégourié-Gonnard4d8685b2015-08-05 15:44:42 +0200314test_suite_ecjpake$(EXEXT): test_suite_ecjpake.c $(DEP)
315 echo " CC $<"
316 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
317
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200318test_suite_ecp$(EXEXT): test_suite_ecp.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100319 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200320 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakkera95919b2013-01-16 17:00:05 +0100321
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200322test_suite_entropy$(EXEXT): test_suite_entropy.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100323 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200324 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Manuel Pégourié-Gonnard2c25eb02014-05-30 10:38:18 +0200325
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200326test_suite_error$(EXEXT): test_suite_error.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100327 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200328 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker9d781402011-05-09 16:17:09 +0000329
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200330test_suite_gcm.aes128_de$(EXEXT): test_suite_gcm.aes128_de.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100331 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200332 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker89e80c92012-03-20 13:50:09 +0000333
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200334test_suite_gcm.aes192_de$(EXEXT): test_suite_gcm.aes192_de.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100335 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200336 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker286bf3c2013-04-08 18:09:51 +0200337
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200338test_suite_gcm.aes256_de$(EXEXT): test_suite_gcm.aes256_de.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100339 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200340 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker286bf3c2013-04-08 18:09:51 +0200341
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200342test_suite_gcm.aes128_en$(EXEXT): test_suite_gcm.aes128_en.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100343 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200344 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker286bf3c2013-04-08 18:09:51 +0200345
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200346test_suite_gcm.aes192_en$(EXEXT): test_suite_gcm.aes192_en.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100347 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200348 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker286bf3c2013-04-08 18:09:51 +0200349
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200350test_suite_gcm.aes256_en$(EXEXT): test_suite_gcm.aes256_en.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100351 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200352 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker89e80c92012-03-20 13:50:09 +0000353
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200354test_suite_gcm.camellia$(EXEXT): test_suite_gcm.camellia.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100355 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200356 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker9dcc3222011-03-08 14:16:06 +0000357
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200358test_suite_hmac_drbg.misc$(EXEXT): test_suite_hmac_drbg.misc.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100359 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200360 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Manuel Pégourié-Gonnard48bc3e82014-01-30 21:11:16 +0100361
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200362test_suite_hmac_drbg.no_reseed$(EXEXT): test_suite_hmac_drbg.no_reseed.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100363 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200364 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Manuel Pégourié-Gonnard6801f392014-01-30 17:22:14 +0100365
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200366test_suite_hmac_drbg.nopr$(EXEXT): test_suite_hmac_drbg.nopr.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100367 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200368 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Manuel Pégourié-Gonnard24600b72014-01-31 09:54:14 +0100369
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200370test_suite_hmac_drbg.pr$(EXEXT): test_suite_hmac_drbg.pr.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100371 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200372 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Manuel Pégourié-Gonnard62273b82014-01-31 10:16:57 +0100373
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200374test_suite_md$(EXEXT): test_suite_md.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100375 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200376 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker17373852011-01-06 14:20:01 +0000377
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200378test_suite_mdx$(EXEXT): test_suite_mdx.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100379 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200380 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker0049c2f2009-07-11 19:15:43 +0000381
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200382test_suite_memory_buffer_alloc$(EXEXT): test_suite_memory_buffer_alloc.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100383 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200384 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Manuel Pégourié-Gonnard765bb312014-11-27 11:55:27 +0100385
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200386test_suite_mpi$(EXEXT): test_suite_mpi.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100387 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200388 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker0049c2f2009-07-11 19:15:43 +0000389
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200390test_suite_pem$(EXEXT): test_suite_pem.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100391 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200392 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker16300582014-04-11 13:28:43 +0200393
Simon Butcherf8758b82016-04-12 11:31:00 +0100394test_suite_pkcs1_v15$(EXEXT): test_suite_pkcs1_v15.c $(DEP)
395 echo " CC $<"
396 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
397
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200398test_suite_pkcs1_v21$(EXEXT): test_suite_pkcs1_v21.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100399 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200400 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker9dcc3222011-03-08 14:16:06 +0000401
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200402test_suite_pkcs5$(EXEXT): test_suite_pkcs5.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100403 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200404 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakkerb0c19a42013-06-24 19:26:38 +0200405
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200406test_suite_pkparse$(EXEXT): test_suite_pkparse.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100407 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200408 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker1a7550a2013-09-15 13:01:22 +0200409
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200410test_suite_pkwrite$(EXEXT): test_suite_pkwrite.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100411 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200412 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakkerc7bb02b2013-09-15 14:54:56 +0200413
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200414test_suite_pk$(EXEXT): test_suite_pk.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100415 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200416 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker32925622013-10-28 17:32:48 +0100417
Daniel Kingadc32c02016-05-16 18:25:45 -0300418test_suite_poly1305$(EXEXT): test_suite_poly1305.c $(DEP)
419 echo " CC $<"
420 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
421
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200422test_suite_rsa$(EXEXT): test_suite_rsa.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100423 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200424 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker0049c2f2009-07-11 19:15:43 +0000425
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200426test_suite_shax$(EXEXT): test_suite_shax.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100427 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200428 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker0049c2f2009-07-11 19:15:43 +0000429
Manuel Pégourié-Gonnardd901d172015-02-16 18:37:53 +0000430test_suite_ssl$(EXEXT): test_suite_ssl.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100431 echo " CC $<"
Manuel Pégourié-Gonnard7f7aebc2015-03-13 17:15:49 +0000432 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Manuel Pégourié-Gonnard4956fd72014-09-24 11:13:44 +0200433
Paul Bakker50157ff2016-07-19 14:57:00 +0100434test_suite_timing$(EXEXT): test_suite_timing.c $(DEP)
435 echo " CC $<"
436 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
437
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200438test_suite_x509parse$(EXEXT): test_suite_x509parse.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100439 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200440 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker0049c2f2009-07-11 19:15:43 +0000441
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200442test_suite_x509write$(EXEXT): test_suite_x509write.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100443 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200444 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker6d620502012-02-16 14:09:13 +0000445
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200446test_suite_xtea$(EXEXT): test_suite_xtea.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100447 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200448 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker0049c2f2009-07-11 19:15:43 +0000449
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200450test_suite_debug$(EXEXT): test_suite_debug.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100451 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200452 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker7d7f4f42010-02-18 18:26:04 +0000453
Alon Bar-Lev18ba0cc2015-02-14 01:04:58 +0200454test_suite_version$(EXEXT): test_suite_version.c $(DEP)
Manuel Pégourié-Gonnard78ec2b02015-07-08 22:12:06 +0100455 echo " CC $<"
Alon Bar-Levf7a9f302015-02-18 17:55:05 +0200456 $(CC) $(LOCAL_CFLAGS) $(CFLAGS) $< $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
Paul Bakker3ac1b2d2010-06-18 22:47:29 +0000457
Paul Bakker0049c2f2009-07-11 19:15:43 +0000458clean:
Paul Bakker62f88dc2012-05-10 21:26:28 +0000459ifndef WINDOWS
Manuel Pégourié-Gonnardea9556a2015-06-25 14:18:20 +0200460 rm -f $(APPS) *.c
Manuel Pégourié-Gonnard5c59a4f2015-06-24 13:06:24 +0200461else
Paul Bakker62f88dc2012-05-10 21:26:28 +0000462 del /Q /F *.c *.exe
463endif
Paul Bakker0049c2f2009-07-11 19:15:43 +0000464
Manuel Pégourié-Gonnard5c59a4f2015-06-24 13:06:24 +0200465check: $(APPS)
Manuel Pégourié-Gonnard85113842015-07-08 21:20:03 +0100466 perl scripts/run-test-suites.pl
Manuel Pégourié-Gonnard5c59a4f2015-06-24 13:06:24 +0200467
468test: check