3 COMMON_SRC = gltest.cpp glwindow.cpp glutil.cpp
4 COMMON_HDR = glwindow.h glutil.h
5 COMMON_LD = -lX11 -lboost_program_options
7 BINARIES := glxtest egltest glx2test egl2test glx3test gles2test eglinfo
11 # choices (not all combinations are valid)
12 # windowing system: WIN_{GLX,EGL}
13 # the kind of context: CON_{GL1,GL3,GLES2}
14 # the API used to draw: compile in glutil_gl1.cpp or glutil_gl2.cpp
16 glxtest: $(COMMON_SRC) $(COMMON_HDR) glutil_gl1.cpp glxbackend.cpp glxbackend.h
17 g++ $(CFLAGS) -DWIN_GLX -DCON_GL1 $^ -lGL $(COMMON_LD) -o $@
19 egltest: $(COMMON_SRC) $(COMMON_HDR) glutil_gl1.cpp eglbackend.cpp eglbackend.h
20 g++ $(CFLAGS) -DWIN_EGL -DCON_GL1 $^ -lEGL -lGL $(COMMON_LD) -o $@
22 glx2test: $(COMMON_SRC) $(COMMON_HDR) glutil_gl2.cpp glxbackend.cpp glxbackend.h
23 g++ $(CFLAGS) -DWIN_GLX -DCON_GL1 $^ -lGL $(COMMON_LD) -o $@
25 egl2test: $(COMMON_SRC) $(COMMON_HDR) glutil_gl2.cpp eglbackend.cpp eglbackend.h
26 g++ $(CFLAGS) -DWIN_EGL -DCON_GL1 $^ -lEGL -lGL $(COMMON_LD) -o $@
28 glx3test: $(COMMON_SRC) $(COMMON_HDR) glutil_gl2.cpp glxbackend.cpp glxbackend.h
29 g++ $(CFLAGS) -DWIN_GLX -DCON_GL3 $^ -lGL $(COMMON_LD) -o $@
31 gles2test: $(COMMON_SRC) $(COMMON_HDR) glutil_gl2.cpp eglbackend.cpp eglbackend.h
32 g++ $(CFLAGS) -DWIN_EGL -DCON_GLES2 $^ -lEGL -lGLESv2 $(COMMON_LD) -o $@
35 gcc $(CFLAGS) $^ -lEGL -lGL -lX11 -o $@