]> git.saurik.com Git - wxWidgets.git/blobdiff - samples/caret/makefile.unx
use wxDC::GetMultiLineTextExtent() instead of duplicating its code in wxButton::DoGet...
[wxWidgets.git] / samples / caret / makefile.unx
index f3803608065a71b5dcbb7bac5080ce03e26a91a7..f82a4c5990637eba90ee113de7dd1c98dcde21ff 100644 (file)
 # under Linux.
 #
 
-CC = gcc
+CXX = $(shell wx-config --cxx)
 
 PROGRAM = caret
 
-$(PROGRAM): $(PROGRAM).o
-       $(CC) -o $(PROGRAM) \
-       $(PROGRAM).o `wx-config --libs`
+OBJECTS = $(PROGRAM).o
 
-$(PROGRAM).o: $(PROGRAM).cpp
-       $(CC) `wx-config --cflags` -c $(PROGRAM).cpp
+# implementation
+
+.SUFFIXES:     .o .cpp
+
+.cpp.o :
+       $(CXX) -c `wx-config --cxxflags` -o $@ $<
+
+all:    $(PROGRAM)
+
+$(PROGRAM):    $(OBJECTS)
+       $(CXX) -o $(PROGRAM) $(OBJECTS) `wx-config --libs`
 
 clean: 
        rm -f *.o $(PROGRAM)