-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmakefile
More file actions
56 lines (41 loc) · 1.35 KB
/
Copy pathmakefile
File metadata and controls
56 lines (41 loc) · 1.35 KB
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
CXX = g++
ifeq ($(PROF), true)
CXXPROF += -pg -no-pie
else
CXXPROF += -s
endif
ifeq ($(BUILD), debug)
CXXFLAGS += -fdiagnostics-color=always -DUNICODE -std=c++20 -Wall -Og -pg -no-pie
else
CXXFLAGS += -DUNICODE -DNDEBUG -std=c++20 -O3 -msse4 -mbmi2 -flto $(CXXPROF) -march=native
endif
ifeq ($(PEXT), true)
CXXFLAGS += -DPEXT
endif
STATIC_LIB = -luser32 -lgdi32 -lopengl32 -lgdiplus -lShlwapi -ldwmapi -lstdc++fs -lsetupapi -lhid -static
.PHONY: all cli test nn clean makedir
all: cli test tuner nn
cli: makedir
@$(CXX) $(CXXFLAGS) "core\*.cpp" "ai\*.cpp" "cli\*.cpp" -o "bin\cli\cli.exe"
test: makedir
@$(CXX) $(CXXFLAGS) -DTUNER "core\*.cpp" "ai\*.cpp" "test\*.cpp" -o "bin\test\test.exe"
tuner: makedir
@$(CXX) $(CXXFLAGS) -DTUNER "core\*.cpp" "ai\*.cpp" "tuner\*.cpp" -o "bin\tuner\tuner.exe"
ppc: makedir
@$(CXX) $(CXXFLAGS) "core\*.cpp" "ai\*.cpp" "ppc\*.cpp" $(STATIC_LIB) -o "bin\ppc\ppc.exe"
nn: makedir
@$(CXX) $(CXXFLAGS) -DTUNER "core\*.cpp" "ai\*.cpp" "nn\*.cpp" -o "bin\nn\nn.exe"
puyop: makedir
@$(CXX) $(CXXFLAGS) "core\*.cpp" "ai\*.cpp" "puyop\*.cpp" -o "bin\puyop\puyop.exe"
clean: makedir
@rm -rf bin
@make makedir
makedir:
@mkdir -p bin
@mkdir -p bin\cli
@mkdir -p bin\test
@mkdir -p bin\tuner\data
@mkdir -p bin\ppc
@mkdir -p bin\nn
@mkdir -p bin\puyop
.DEFAULT_GOAL := cli