2012-05-12 18:08:26 +02:00
|
|
|
# use pkg-config for getting CFLAGS and LDLIBS
|
2012-05-08 18:22:28 +02:00
|
|
|
FFMPEG_LIBS= libavdevice \
|
|
|
|
libavformat \
|
|
|
|
libavfilter \
|
|
|
|
libavcodec \
|
2012-05-09 23:45:16 +02:00
|
|
|
libswresample \
|
2012-05-08 18:22:28 +02:00
|
|
|
libswscale \
|
|
|
|
libavutil \
|
|
|
|
|
2013-06-26 16:13:58 +02:00
|
|
|
CFLAGS += -Wall -g
|
2012-08-24 16:49:04 +02:00
|
|
|
CFLAGS := $(shell pkg-config --cflags $(FFMPEG_LIBS)) $(CFLAGS)
|
|
|
|
LDLIBS := $(shell pkg-config --libs $(FFMPEG_LIBS)) $(LDLIBS)
|
2011-05-29 12:47:40 +02:00
|
|
|
|
2012-05-08 18:22:28 +02:00
|
|
|
EXAMPLES= decoding_encoding \
|
2013-11-04 12:35:17 +01:00
|
|
|
demuxing_decoding \
|
2012-05-08 18:22:28 +02:00
|
|
|
filtering_video \
|
|
|
|
filtering_audio \
|
|
|
|
metadata \
|
|
|
|
muxing \
|
2012-11-30 13:51:40 +01:00
|
|
|
resampling_audio \
|
2012-08-21 14:43:51 +02:00
|
|
|
scaling_video \
|
2011-05-29 12:47:40 +02:00
|
|
|
|
|
|
|
OBJS=$(addsuffix .o,$(EXAMPLES))
|
|
|
|
|
2012-05-09 23:06:43 +02:00
|
|
|
# the following examples make explicit use of the math library
|
|
|
|
decoding_encoding: LDLIBS += -lm
|
|
|
|
muxing: LDLIBS += -lm
|
2013-09-04 15:49:18 +02:00
|
|
|
resampling_audio: LDLIBS += -lm
|
2012-05-09 23:06:43 +02:00
|
|
|
|
2012-08-23 20:17:25 +02:00
|
|
|
.phony: all clean-test clean
|
2011-05-29 12:47:40 +02:00
|
|
|
|
|
|
|
all: $(OBJS) $(EXAMPLES)
|
|
|
|
|
2012-08-23 20:17:25 +02:00
|
|
|
clean-test:
|
2012-08-30 22:37:44 +02:00
|
|
|
$(RM) test*.pgm test.h264 test.mp2 test.sw test.mpg
|
2012-08-23 20:17:25 +02:00
|
|
|
|
|
|
|
clean: clean-test
|
2012-08-28 20:06:45 +02:00
|
|
|
$(RM) $(EXAMPLES) $(OBJS)
|