aboutsummaryrefslogtreecommitdiff
path: root/com/BLAKE2/meson.build
diff options
context:
space:
mode:
authoraqua <aqua@iserlohn-fortress.net>2022-07-29 11:35:16 +0300
committeraqua <aqua@iserlohn-fortress.net>2022-12-28 21:01:45 +0200
commitbb6439d85b36d9ebbaf82a08e707428e8a7ef234 (patch)
treec8841eea0913f8fcda621870875422b1d6f28394 /com/BLAKE2/meson.build
parentAdd BLAKE2s implementation (diff)
downloadkernel-bb6439d85b36d9ebbaf82a08e707428e8a7ef234.tar.xz
BLAKE2s: add Known Answer Tests
Diffstat (limited to 'com/BLAKE2/meson.build')
-rw-r--r--com/BLAKE2/meson.build19
1 files changed, 14 insertions, 5 deletions
diff --git a/com/BLAKE2/meson.build b/com/BLAKE2/meson.build
index 005a157..1592dd7 100644
--- a/com/BLAKE2/meson.build
+++ b/com/BLAKE2/meson.build
@@ -1,7 +1,16 @@
-BLAKE2s = declare_dependency(
- sources: 'blake2s.c',
- compile_args: '-fanalyzer'
+#BLAKE2s = static_library('BLAKE2s', 'blake2s.c')
+BLAKE2s_native = shared_library('BLAKE2s_native', 'blake2s.c', native: true)
+
+test('BLAKE2s functions', executable('b2s_fns', 'test_fns.c', link_with: BLAKE2s_native, native: true), suite: 'BLAKE2')
+test('BLAKE2s selftest', executable('b2s_selftest', 'test_main.c', link_with: BLAKE2s_native, native: true), suite: 'BLAKE2')
+
+kat = generator(python3,
+ arguments: '@INPUT@',
+ capture: true, output: '@BASENAME@.h'
)
-test('BLAKE2s functions', executable('b2s_fns', 'test_fns.c', dependencies: BLAKE2s, native: true), suite: 'BLAKE2')
-test('BLAKE2s selftest', executable('b2s_selftest', 'test_main.c', dependencies: BLAKE2s, native: true), suite: 'BLAKE2')
+test('BLAKE2s KAT',
+ executable('b2s_kat', ['test/blake2s_kat.c', kat.process('test/blake2s_kat.py')],
+ link_with: BLAKE2s_native, native: true),
+ suite: 'BLAKE2'
+)