1234567891011121314151617181920212223242526272829303132 |
- CXX = g++
- CXXFLAGS = -g3 -std=c++14 -D__STDC_CONSTANT_MACROS \
- -Wall -Wextra -Wextra -pedantic \
- -Wdisabled-optimization -Wctor-dtor-privacy -Wmissing-declarations \
- -Woverloaded-virtual -Wshadow -Wno-unused -Winline
- LDLIBS = -lavformat -lavcodec -lavutil -lswscale -pthread -lEGL -lGLESv2 -lm -lX11
- src = $(wildcard *.cpp)
- obj = $(src:.cpp=.o)
- dep = $(obj:.o=.d)
- target = player
- all: $(target)
- gles-display.o: gles-display.c
- gcc -c gles-display.c -g
- $(target): $(obj) gles-display.o
- $(CXX) -o $@ $^ $(LDLIBS)
- -include $(dep)
- %.d: %.cpp
- @$(CXX) $(CXXFLAGS) $< -MM -MT $(@:.d=.o) >$@
- test: $(target)
- ./$(target) test.mkv
- .PHONY: clean
- clean:
- $(RM) $(obj) $(target) $(dep)
|