2023-06-07 06:08:12 +00:00
|
|
|
CC=gcc
|
|
|
|
CXX=g++
|
|
|
|
RM=rm -f
|
2023-06-10 00:21:32 +00:00
|
|
|
CPPFLAGS=-Wall
|
|
|
|
LDFLAGS=
|
2023-06-07 06:08:12 +00:00
|
|
|
LDLIBS=-lm
|
|
|
|
|
|
|
|
SRCS=main.cpp Spigot.cpp
|
|
|
|
OBJS=$(subst .cpp,.o,$(SRCS))
|
|
|
|
|
|
|
|
all: main
|
|
|
|
|
2023-06-10 00:21:32 +00:00
|
|
|
debug: $(OBJS)
|
|
|
|
$(CXX) $(LDFLAGS) -ggdb -O0 -o main $(OBJS) $(LDLIBS)
|
|
|
|
|
2023-06-07 06:08:12 +00:00
|
|
|
main: $(OBJS)
|
2023-06-10 00:21:32 +00:00
|
|
|
$(CXX) $(LDFLAGS) -O3 -o main $(OBJS) $(LDLIBS)
|
2023-06-07 06:08:12 +00:00
|
|
|
|
|
|
|
depend: .depend
|
|
|
|
|
|
|
|
.depend: $(SRCS)
|
|
|
|
$(RM) ./.depend
|
2023-06-10 00:21:32 +00:00
|
|
|
$(CXX) $(CPPFLAGS) -MM $^ >> ./.depend
|
2023-06-07 06:08:12 +00:00
|
|
|
|
|
|
|
clean:
|
|
|
|
$(RM) $(OBJS)
|
2024-07-23 16:07:02 +00:00
|
|
|
$(RM) main
|
2023-06-07 06:08:12 +00:00
|
|
|
|
|
|
|
distclean: clean
|
|
|
|
$(RM) *~ .depend
|
|
|
|
|
|
|
|
include .depend
|