rk_engine/Makefile

16 lines
449 B
Makefile

SOURCES = cpp/opengl/render_context_glx.cpp cpp/opengl/render_opengles.cpp cpp/math.cpp
OUTPUTFILE = engine.so
CXXFLAGS = -fpic -Wall -Werror -O2 -flto -fomit-frame-pointer -ffast-math -funroll-loops -fno-rtti -fno-exceptions
.PHONY: all
all: clean $(OUTPUTFILE)
.PHONY: clean
clean:
rm -f $(OUTPUTFILE)
find . -name "*.o" -type f -delete
$(OUTPUTFILE): $(subst .cpp,.o,$(SOURCES))
$(CXX) -shared $(CXXFLAGS) -s -o $@ $^ -lGLESv2 -lGLX -lX11