-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
25 lines (19 loc) · 881 Bytes
/
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
SHELL = /bin/sh
CXX = g++
LIBS = -lpthread -lssl -lcrypto
EXE = dns64sec
INC_DIR = include
CXXFLAGS = -O2 -Wall -Werror -Wextra -pedantic -std=c++17 -I$(INC_DIR)
TARGET = $(EXE)
SOURCES = $(shell echo src/*.cc)
HEADERS = $(shell echo $(INC_DIR)/*.h)
OBJECTS = $(SOURCES:.cc=.o)
all: $(TARGET)
clean:
rm -f $(OBJECTS) $(TARGET)
astyle:
astyle -C -S -f $(SOURCES) $(HEADERS)
tidy:
clang-tidy $(SOURCES) -header-filter=.* -checks='*',-hicpp-vararg,-cppcoreguidelines-pro-type-vararg,-fuchsia-default-arguments-declarations,-fuchsia-trailing-return,-fuchsia-default-arguments-calls,-hicpp-avoid-c-arrays,-modernize-avoid-c-arrays,-cppcoreguidelines-avoid-c-arrays,-fuchsia-overloaded-operator,-llvm-header-guard,-cppcoreguidelines-pro-type-reinterpret-cast -extra-arg=-std=c++17 -extra-arg=-I$(INC_DIR)
$(TARGET): $(OBJECTS)
$(CXX) $(CXXFLAGS) -o $(TARGET) $(OBJECTS) $(LIBS)