22 lines
405 B
Makefile
22 lines
405 B
Makefile
# Compiler and flags
|
|
CXX = g++
|
|
CXXFLAGS = -pthread -Wall -Wextra -O2 -std=c++17
|
|
|
|
# Linker flags
|
|
LDFLAGS = -lcurses
|
|
|
|
# Default target
|
|
all: thread threadncurses
|
|
|
|
# Build rule
|
|
thread: thread.cpp
|
|
$(CXX) $(CXXFLAGS) thread.cpp -o thread $(LDFLAGS)
|
|
|
|
threadncurses: threadncurses.cpp
|
|
$(CXX) $(CXXFLAGS) threadncurses.cpp -o threadncurses $(LDFLAGS)
|
|
|
|
# Clean build artifacts
|
|
clean:
|
|
rm -f thread threadncurses
|
|
|