CARGS := -Wall -Werror -I. CPPARGS := -Wall -Werror -I. all: cpp-vector.pdf c_build/vectors %.pdf: %.md pandoc \ --latex-engine=xelatex \ --filter pandoc-include-code \ $< -o $@ c_build/%: %.c mkdir -p c_build gcc $(CARGS) $< -o $@ cpp_build/%: %.cpp mkdir -p cpp_build g++ $(CPPARGS) $< -o $@