From 84ceed63bcfc7f16ea11d32242836a1773cf7d7a Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Mon, 14 Jan 2013 13:05:28 -0500 Subject: [PATCH] Makefile: Link to pattern rule documentation And call them "pattern rules" not "matching rules". --- Makefile | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 2316c1d..b8b7787 100644 --- a/Makefile +++ b/Makefile @@ -135,10 +135,13 @@ $(CXX_PROGRAMS): % : $$($$(*)_OBJECTS) run: $(PROGRAMS) ./$(RUN_PROGRAM) -# Matching rule for compiling object files from C++ source +# Pattern rule for compiling object files from C++ source # There is an implicit rule for this in GNU make # http://www.gnu.org/software/make/manual/html_node/Catalogue-of-Rules.html -# but I redefine it here for clarity. +# but I redefine it here for clarity. For an explanation of the +# %.o: %.cpp +# syntax, see +# http://www.gnu.org/software/make/manual/html_node/Pattern-Intro.html # # CXX and CXXFLAGS have defaults defined by make # http://www.gnu.org/software/make/manual/html_node/Implicit-Variables.html @@ -149,7 +152,7 @@ run: $(PROGRAMS) %.o: %.cpp $(CXX) $(CXXFLAGS) -c $< -# Matching rule for compiling object files from C source +# Pattern rule for compiling object files from C source # The comments from the C++ rule above also apply here %.o: %.c $(CC) $(CFLAGS) -c $< -- 2.26.2