Kevin Jerebica
a176afab7e
source code was taken from my project gravity and modified so I can reuse the renderer in other projects. I will also upgrade it, free it from old bugs, put more effort into learning the math behind rendering, etc.
24 lines
529 B
Makefile
24 lines
529 B
Makefile
CC=gcc
|
|
CFLAGS=-DFREEGLUT_STATIC -g3
|
|
LFLAGS=-lglfw -L/usr/lib64 -lGLEW -lGL -lX11 -lGLU -lassimp -lm
|
|
LD=ld
|
|
OUT=build
|
|
DEV=dev.c
|
|
|
|
all:
|
|
mkdir -p $(OUT)
|
|
$(CC) $(CFLAGS) -c rendlib.c -o $(OUT)/rendlib.o $(LFLAGS)
|
|
$(CC) $(CFLAGS) -c math.c -o $(OUT)/math.o $(LFLAGS)
|
|
$(CC) $(CFLAGS) -c object.c -o $(OUT)/object.o $(LFLAGS)
|
|
$(LD) -relocatable $(OUT)/rendlib.o $(OUT)/math.o $(OUT)/object.o -o $(OUT)/rendlib
|
|
|
|
dev: all
|
|
$(CC) $(CFLAGS) dev.c $(OUT)/rendlib -o $(OUT)/dev $(LFLAGS)
|
|
|
|
devall: dev
|
|
$(OUT)/dev
|
|
|
|
|
|
clean:
|
|
rm -rf $(OUT)
|