]> git.saurik.com Git - wxWidgets.git/blobdiff - samples/opengl/penguin/makefile.unx
Move oleacc.lib from the VC++ projects/makefiles to libraries.h
[wxWidgets.git] / samples / opengl / penguin / makefile.unx
index c8d335c1bf905c3de3d0c73faa85587de4228684..bc26127d08914d44eb0b1f7f334f9e670c2c5749 100644 (file)
@@ -7,15 +7,27 @@
 #
 # Makefile for penguin example (UNIX).
 
-PROGRAM=penguin
+OPENGL_LIBS=-lGL -lGLU
+#if you have old Mesa, try this:
+#OPENGL_LIBS=-lMesaGL -lMesaGLU
 
-OPENGLHOME=/home/jacs/mesa/Mesa-2.3
+CC = $(shell wx-config --cc)
+CXX = $(shell wx-config --cxx)
 
-EXTRACPPFLAGS=-I$(OPENGLHOME)/include # -I../../motif
-EXTRALDFLAGS=-L$(OPENGLHOME)/lib
-EXTRALDLIBS=-lMesaGL -lMesaGLU
+Penguin: penguin.o trackball.o lw.o
+       $(CXX) -o Penguin \
+       penguin.o trackball.o lw.o \
+       `wx-config --libs` -lwx_gtk_gl $(OPENGL_LIBS)
 
-OBJECTS=$(PROGRAM).o trackball.o lw.o
+penguin.o: penguin.cpp
+       $(CXX) `wx-config --cxxflags` -I../../gtk -c penguin.cpp
 
-include ../../../src/makeprog.env
+lw.o: lw.cpp
+       $(CXX) `wx-config --cxxflags` -I../../gtk -c lw.cpp
+
+trackball.o: trackball.c
+       $(CC) `wx-config --cflags` -I../../gtk -c trackball.c
+
+clean: 
+       rm -f *.o Penguin