X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/c4fda16bb0d3b9b5fae6d289e4c3a93701fa4839..ce6d2511f82aafc78aba320018c868f826ab172b:/samples/bombs/makefile.unx diff --git a/samples/bombs/makefile.unx b/samples/bombs/makefile.unx index 738e5f4cec..9b4f82a501 100644 --- a/samples/bombs/makefile.unx +++ b/samples/bombs/makefile.unx @@ -17,18 +17,19 @@ CC = gcc PROGRAM = bombs -$(PROGRAM): $(PROGRAM).o game.o bombs1.o - $(CC) -o $(PROGRAM) \ - $(PROGRAM).o bombs1.o game.o `wx-config --libs` - -$(PROGRAM).o: $(PROGRAM).cpp - $(CC) `wx-config --cflags` -c $(PROGRAM).cpp - -game.o: game.cpp - $(CC) `wx-config --cflags` -c game.cpp - -bombs1.o: bombs1.cpp - $(CC) `wx-config --cflags` -c bombs1.cpp +OBJECTS = $(PROGRAM).o game.o bombs1.o + +# implementation + +.SUFFIXES: .o .cpp + +.cpp.o : + $(CC) -c `wx-config --cflags` -o $@ $< + +all: $(PROGRAM) + +$(PROGRAM): $(OBJECTS) + $(CC) -o $(PROGRAM) $(OBJECTS) `wx-config --libs` clean: rm -f *.o $(PROGRAM)