--- Makefile.orig	2016-08-25 16:21:38 UTC
+++ Makefile
@@ -2,9 +2,9 @@ DATADIR?=themes/
 
 #append -DWITH_WIIUSE to compile with WIIUSE support!
 #append -DNOSOUND to compile WITHOUT sound support
-CC=g++ -DDATADIR="\"$(DATADIR)\""
+CXX?=g++
 
-CFLAGS+=-c -Wall `sdl-config --cflags`
+CXXFLAGS+=-Wall `sdl-config --cflags` -DDATADIR="\"$(DATADIR)\""
 
 #append -lwiiuse to compile with WIIUSE support
 #remove -lSDL_mixer if compiling with -DNOSOUND
@@ -18,10 +18,10 @@ EXECUTABLE=sdl-ball
 all: $(SOURCES) $(EXECUTABLE)
 	
 $(EXECUTABLE): $(OBJECTS)
-	$(CC) $(LDFLAGS) $(OBJECTS) $(LIBS) -o $@
+	$(CXX) $(LDFLAGS) $(OBJECTS) $(LIBS) -o $@
 
 .cpp.o:
-	$(CC) $(CFLAGS) $< -o $@
+	$(CXX) -c $(CXXFLAGS) $< -o $@
 
 clean:
 	rm -f *.o sdl-ball
