24 lines
352 B
Makefile
24 lines
352 B
Makefile
|
TARGET = L1A
|
||
|
SRC_FILES = main.cpp
|
||
|
|
||
|
# NO EDITS BELOW THIS LINE
|
||
|
CXX = g++
|
||
|
OBJECTS = $(SRC_FILES:.cpp=.o)
|
||
|
|
||
|
ifeq ($(shell echo "Windows"), "Windows")
|
||
|
TARGET := $(TARGET).exe
|
||
|
DEL = del
|
||
|
else
|
||
|
DEL = rm -f
|
||
|
endif
|
||
|
|
||
|
all: $(TARGET)
|
||
|
|
||
|
$(TARGET): $(OBJECTS)
|
||
|
$(CXX) -std=c++17 -o $@ $^
|
||
|
|
||
|
%.o: %.cpp
|
||
|
$(CXX) -std=c++17 -o $@ -c $<
|
||
|
|
||
|
clean:
|
||
|
$(DEL) $(TARGET) $(OBJECTS)
|