17 lines
485 B
Makefile
17 lines
485 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)
|
|
find . -name "*.o" -type f -delete
|
|
|
|
.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
|