2021-01-17 15:11:21 +00:00
|
|
|
# g++ and clang++ both have pretty garbage errors
|
2021-01-17 00:44:11 +00:00
|
|
|
CXX=g++
|
2021-01-17 15:11:21 +00:00
|
|
|
FLAGS=-std=c++17 -g
|
2021-01-17 16:16:57 +00:00
|
|
|
CXX_FLAGS=$(FLAGS) -c
|
|
|
|
L_FLAGS=$(FLAGS)
|
2021-01-17 00:44:11 +00:00
|
|
|
LIBS=-lsodium
|
|
|
|
|
2021-01-19 22:52:02 +00:00
|
|
|
bmc: bmc_main.o base64.o expiring_signature.o receiver.o sender.o signing_key.o sodium_helpers.o string_helpers.o time_helpers.o
|
2021-01-17 16:16:57 +00:00
|
|
|
$(CXX) -o $@ $^ $(L_FLAGS) $(LIBS)
|
|
|
|
|
2021-01-19 22:52:02 +00:00
|
|
|
bmc_main.o: bmc_main.cpp expiring_signature.h receiver.h sender.h signing_key.h sodium_helpers.h string_helpers.h time_helpers.h
|
2021-01-17 16:16:57 +00:00
|
|
|
$(CXX) -o $@ $(CXX_FLAGS) $<
|
|
|
|
|
|
|
|
base64.o: cpp-base64/base64.cpp cpp-base64/base64.h
|
|
|
|
$(CXX) -o $@ $(CXX_FLAGS) $<
|
2021-01-17 00:44:11 +00:00
|
|
|
|
2021-01-18 00:00:45 +00:00
|
|
|
expiring_signature.o: expiring_signature.cpp expiring_signature.h
|
|
|
|
$(CXX) -o $@ $(CXX_FLAGS) $<
|
|
|
|
|
|
|
|
receiver.o: receiver.cpp receiver.h expiring_signature.h sodium_helpers.h string_helpers.h time_helpers.h
|
|
|
|
$(CXX) -o $@ $(CXX_FLAGS) $<
|
|
|
|
|
2021-01-18 22:57:33 +00:00
|
|
|
sender.o: sender.cpp sender.h expiring_signature.h signing_key.h sodium_helpers.h time_helpers.h
|
|
|
|
$(CXX) -o $@ $(CXX_FLAGS) $<
|
|
|
|
|
|
|
|
signing_key.o: signing_key.cpp signing_key.h expiring_signature.h sodium_helpers.h time_helpers.h
|
|
|
|
$(CXX) -o $@ $(CXX_FLAGS) $<
|
|
|
|
|
2021-01-18 00:00:45 +00:00
|
|
|
sodium_helpers.o: sodium_helpers.cpp sodium_helpers.h
|
|
|
|
$(CXX) -o $@ $(CXX_FLAGS) $<
|
|
|
|
|
2021-01-17 21:36:56 +00:00
|
|
|
string_helpers.o: string_helpers.cpp string_helpers.h cpp-base64/base64.h
|
|
|
|
$(CXX) -o $@ $(CXX_FLAGS) $<
|
|
|
|
|
2021-01-17 21:45:59 +00:00
|
|
|
time_helpers.o: time_helpers.cpp time_helpers.h
|
|
|
|
$(CXX) -o $@ $(CXX_FLAGS) $<
|
|
|
|
|
2021-01-17 00:44:11 +00:00
|
|
|
clean:
|
2021-01-19 22:52:02 +00:00
|
|
|
rm -f bmc bmc_main.o base64.o expiring_signature.o receiver.o sender.o signing_key.o sodium_helpers.o string_helpers.o time_helpers.o
|
2021-01-17 00:44:11 +00:00
|
|
|
|