-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
32 lines (20 loc) · 1.16 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# BIKE reference and optimized implementations assume that OpenSSL and NTL libraries are available in the platform.
# To compile this code for NIST KAT routine use: make bike-nist-kat
# To compile this code for demo tests use: make bike-demo-test
# TO EDIT PARAMETERS AND SELECT THE BIKE VARIANT: please edit defs.h file in the indicated sections.
# The file measurements.h controls how the cycles are counted. Note that #define REPEAT is initially set to 100,
# which means that every keygen, encaps and decaps is repeated 100 times and the number of cycles is averaged.
# Verbose levels: 0, 1, 2 or 3
VERBOSE=0
CC:=g++
CFLAGS:=-m64 -O3
SRC:=*.c ntl.cpp FromNIST/rng.c
INCLUDE:=-I. -I$(OpenSSL)/include -L$(OpenSSL)/lib -std=c++11 -lcrypto -lssl -lm -ldl -lntl -lgmp -lgf2x -lpthread
all: bike-nist-kat
bike-demo-test: $(SRC) *.h tests/test.cpp
$(CC) $(CFLAGS) tests/test.cpp $(SRC) $(INCLUDE) -DVERBOSE=$(VERBOSE) -DNIST_RAND=1 -o $@
bike-nist-kat: $(SRC) *.h FromNIST/*.h FromNIST/PQCgenKAT_kem.c
$(CC) $(CFLAGS) FromNIST/PQCgenKAT_kem.c $(SRC) $(INCLUDE) -DVERBOSE=$(VERBOSE) -DNIST_RAND=1 -o $@
clean:
rm -f PQCkemKAT_*
rm -f bike*