summaryrefslogtreecommitdiff
path: root/src/Makefile
blob: 1366de2e109acfa51b1c02549d30d36b0f8baf60 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
### if you want X11: CFLAGS=-Wall -pedantic -std=c99 -DGRAPHICAL
### and add graphics.o to hackvr build target.
### fuck it. I'll fix it later.
CFLAGS=-Wall -pedantic -std=c99 -DGRAPHICAL -ffast-math

all: hackvr_headless hackvr_x11 hackvr_opengl slowcat

hackvr_headless: LDLIBS=-lm
hackvr_headless: CFLAGS=-Wall -pedantic -std=c99 -ffast-math
hackvr_headless: hackvr_headless.o math.o

hackvr_x11: LDLIBS=-lm -lX11
hackvr_x11: hackvr_x11.o graphics.o graphics_x11.o math.o

hackvr_opengl: LDLIBS=-lm -lGL -lGLU -lglut
hackvr_opengl: hackvr_opengl.o graphics.o graphics_opengl.o math.o

hackvr_opengl.o: LDLIBS=-lm -lGL -lGLU -lglut
hackvr_x11.o: LDLIBS=-lm -lX11
hackvr_headless.o: LDLIBS=-lm

graphics.o: LDLIBS=-lm -lX11
graphics_x11.o: LDLIBS=-lm -lX11
graphics_opengl.o: LDLIBS=-lm -lGL -lGLU -lglut
math.o: LDLIBS=-lm

clean:
	rm -f hackvr
	rm -f hackvr_headless
	rm -f hackvr_opengl
	rm -f hackvr_x11
	rm -f slowcat
	rm -f *.o