-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile_macOS
166 lines (115 loc) · 5.23 KB
/
Makefile_macOS
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
# Assumes you have a Homebrew-managed installation of LLVM.
CXX = /opt/homebrew/opt/llvm/bin/clang++ -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS
LIBS = -L/opt/homebrew/opt/llvm/lib
CXXFLAGS = -fcolor-diagnostics -fansi-escape-codes -std=c++20 -stdlib=libc++ -Wall -Wextra -pedantic
INCLUDES = -I/opt/homebrew/opt/llvm/include -I.
sha256.o: sha256.cpp
$(CXX) -c sha256.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
sha512.o: sha512.cpp
$(CXX) -c sha512.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
md5.o: md5.cpp
$(CXX) -c md5.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
sha1.o: sha1.cpp
$(CXX) -c sha1.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
ripemd.o: ripemd.cpp
$(CXX) -c ripemd.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
sha224sum.o: sha224sum.cpp
$(CXX) -c sha224sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
sha224sum: sha256.o sha224sum.o
$(CXX) -o $@ $^ $(LIBS) $(CXXFLAGS)
sha224sum_debug: sha256.cpp sha224sum.cpp
$(CXX) -g -O0 -c sha256.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -g -O0 -c sha224sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -o sha224sum sha256.o sha224sum.o $(LIBS) $(CXXFLAGS)
sha256sum.o: sha256sum.cpp
$(CXX) -c sha256sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
sha256sum: sha256.o sha256sum.o
$(CXX) -o $@ $^ $(LIBS) $(CXXFLAGS)
sha256sum_debug: sha256.cpp sha256sum.cpp
$(CXX) -g -O0 -c sha256.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -g -O0 -c sha256sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -o sha256sum sha256.o sha256sum.o $(LIBS) $(CXXFLAGS)
sha384sum.o: sha384sum.cpp
$(CXX) -c sha384sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
sha384sum: sha512.o sha384sum.o
$(CXX) -o $@ $^ $(LIBS) $(CXXFLAGS)
sha384sum_debug: sha512.cpp sha384sum.cpp
$(CXX) -g -O0 -c sha512.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -g -O0 -c sha384sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -o sha384sum sha512.o sha384sum.o $(LIBS) $(CXXFLAGS)
sha512sum.o: sha512sum.cpp
$(CXX) -c sha512sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
sha512sum: sha512.o sha512sum.o
$(CXX) -o $@ $^ $(LIBS) $(CXXFLAGS)
sha512sum_debug: sha512.cpp sha512sum.cpp
$(CXX) -g -O0 -c sha512.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -g -O0 -c sha512sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -o sha512sum sha512.o sha512sum.o $(LIBS) $(CXXFLAGS)
sha512t224sum.o: sha512t224sum.cpp
$(CXX) -c sha512t224sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
sha512t224sum: sha512.o sha512t224sum.o
$(CXX) -o $@ $^ $(LIBS) $(CXXFLAGS)
sha512t224sum_debug: sha512.cpp sha512t224sum.cpp
$(CXX) -g -O0 -c sha512.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -g -O0 -c sha512t224sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -o sha512t224sum sha512.o sha512t224sum.o $(LIBS) $(CXXFLAGS)
sha512t256sum.o: sha512t256sum.cpp
$(CXX) -c sha512t256sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
sha512t256sum: sha512.o sha512t256sum.o
$(CXX) -o $@ $^ $(LIBS) $(CXXFLAGS)
sha512t256sum_debug: sha512.cpp sha512t256sum.cpp
$(CXX) -g -O0 -c sha512.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -g -O0 -c sha512t256sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -o sha512t256sum sha512.o sha512t256sum.o $(LIBS) $(CXXFLAGS)
md5sum.o: md5sum.cpp
$(CXX) -c md5sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
md5sum: md5.o md5sum.o
$(CXX) -o $@ $^ $(LIBS) $(CXXFLAGS)
md5sum_debug: md5.cpp md5sum.cpp
$(CXX) -g -O0 -c md5.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -g -O0 -c md5sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -o md5sum md5.o md5sum.o $(LIBS) $(CXXFLAGS)
sha1sum.o: sha1sum.cpp
$(CXX) -c sha1sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
sha1sum: sha1.o sha1sum.o
$(CXX) -o $@ $^ $(LIBS) $(CXXFLAGS)
sha1sum_debug: sha1.cpp sha1sum.cpp
$(CXX) -g -O0 -c sha1.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -g -O0 -c sha1sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -o sha1sum sha1.o sha1sum.o $(LIBS) $(CXXFLAGS)
ripemd128.o: ripemd128.cpp
$(CXX) -c ripemd128.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
ripemd128sum.o: ripemd128sum.cpp
$(CXX) -c ripemd128sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
ripemd128sum: ripemd.o ripemd128.o ripemd128sum.o
$(CXX) -o $@ $^ $(LIBS) $(CXXFLAGS)
ripemd128sum_debug: ripemd.cpp ripemd128sum.cpp
$(CXX) -g -O0 -c ripemd.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -g -O0 -c ripemd128sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -o ripemd128sum ripemd.o ripemd128sum.o $(LIBS) $(CXXFLAGS)
ripemd160.o: ripemd160.cpp
$(CXX) -c ripemd160.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
ripemd160sum.o: ripemd160sum.cpp
$(CXX) -c ripemd160sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
ripemd160sum: ripemd.o ripemd160.o ripemd160sum.o
$(CXX) -o $@ $^ $(LIBS) $(CXXFLAGS)
ripemd160sum_debug: ripemd.cpp ripemd160sum.cpp
$(CXX) -g -O0 -c ripemd.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -g -O0 -c ripemd160sum.cpp $(INCLUDES) $(LIBS) $(CXXFLAGS)
$(CXX) -o ripemd160sum ripemd.o ripemd160sum.o $(LIBS) $(CXXFLAGS)
EXEC_DEPS := sha224sum sha256sum sha384sum sha512sum
EXEC_DEPS += sha512t224sum sha512t256sum
EXEC_DEPS += md5sum sha1sum
EXEC_DEPS += ripemd128sum ripemd160sum
execs: $(EXEC_DEPS)
DEBUG_DEPS := sha224sum_debug sha256sum_debug sha384sum_debug sha512sum_debug
DEBUG_DEPS += sha512t224sum_debug sha512t256sum_debug
DEBUG_DEPS += md5sum_debug sha1sum_debug
DEBUG_DEPS += ripemd128sum_debug ripemd160sum_debug
debug: $(DEBUG_DEPS)
clean:
rm -f *.o
rm -f sha*sum
rm -f md5sum
rm -f ripemd*sum
rm -f encode_test