2023-05-10 20:56:30 +02:00
|
|
|
|
|
|
|
CXX = g++
|
2023-05-12 20:51:49 +02:00
|
|
|
OPTFLAGS = -O2
|
|
|
|
DBGFLAGS =
|
|
|
|
CXXFLAGS = -std=c++11 -Wall -Wextra $(OPTFLAGS) $(DBGFLAGS)
|
|
|
|
LIB_BOOST_TEST = -l:libboost_unit_test_framework.a
|
2023-05-10 20:56:30 +02:00
|
|
|
|
2023-05-12 20:51:49 +02:00
|
|
|
.PHONY: all
|
2024-11-24 14:22:26 +01:00
|
|
|
all: run_matching run_matching_dbg test_mwmatching test_concatenable_queue test_priority_queue
|
2023-05-12 20:51:49 +02:00
|
|
|
|
2024-11-24 14:25:43 +01:00
|
|
|
run_matching: run_matching.cpp mwmatching.hpp concatenable_queue.hpp priority_queue.hpp
|
2023-05-12 20:51:49 +02:00
|
|
|
$(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -o $@ $<
|
|
|
|
|
|
|
|
run_matching_dbg: OPTFLAGS = -Og
|
|
|
|
run_matching_dbg: DBGFLAGS = -g -fsanitize=address -fsanitize=undefined
|
2024-11-24 14:25:43 +01:00
|
|
|
run_matching_dbg: run_matching.cpp mwmatching.hpp concatenable_queue.hpp priority_queue.hpp
|
2023-05-12 20:51:49 +02:00
|
|
|
$(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -o $@ $<
|
|
|
|
|
|
|
|
test_mwmatching: OPTFLAGS = -O1
|
|
|
|
test_mwmatching: DBGFLAGS = -fsanitize=address -fsanitize=undefined
|
2024-11-24 14:25:43 +01:00
|
|
|
test_mwmatching: test_mwmatching.cpp mwmatching.hpp concatenable_queue.hpp priority_queue.hpp
|
2023-05-12 20:51:49 +02:00
|
|
|
$(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -o $@ $< $(LIB_BOOST_TEST)
|
2023-05-10 20:56:30 +02:00
|
|
|
|
2024-11-24 14:22:26 +01:00
|
|
|
test_concatenable_queue: OPTFLAGS = -O1
|
|
|
|
test_concatenable_queue: DBGFLAGS = -fsanitize=address -fsanitize=undefined
|
|
|
|
test_concatenable_queue: test_concatenable_queue.cpp concatenable_queue.hpp
|
|
|
|
$(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -o $@ $< $(LIB_BOOST_TEST)
|
|
|
|
|
|
|
|
test_priority_queue: OPTFLAGS = -O1
|
|
|
|
test_priority_queue: DBGFLAGS = -fsanitize=address -fsanitize=undefined
|
|
|
|
test_priority_queue: test_priority_queue.cpp priority_queue.hpp
|
2023-06-16 19:55:43 +02:00
|
|
|
$(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -o $@ $< $(LIB_BOOST_TEST)
|
|
|
|
|
2023-05-10 20:56:30 +02:00
|
|
|
.PHONY: clean
|
|
|
|
clean:
|
2024-11-24 14:22:26 +01:00
|
|
|
$(RM) run_matching run_matching_dbg
|
|
|
|
$(RM) test_mwmatching
|
|
|
|
$(RM) test_concatenable_queue test_priority_queue
|
2023-05-10 20:56:30 +02:00
|
|
|
|