streamers-build / THIRDPARTY-LIBS / Makefile @ eee31b4f
History | View | Annotate | Download (1.78 KB)
1 |
THIRDPARTYLIBS = $(shell pwd) |
---|---|
2 |
#NAPA-LIBS = NAPA-BASELIBS/monl/libmon.a NAPA-BASELIBS/ml/libml.a |
3 |
#GRAPES-LIBS = GRAPES/src/libgrapes.a |
4 |
#LIBS = $(GRAPES-LIBS) $(NAPA-LIBS) |
5 |
|
6 |
.PHONY: GRAPES-build NAPA-build x264-build ffmpeg-build |
7 |
|
8 |
all: GRAPES-build NAPA-build |
9 |
|
10 |
x264/.git: |
11 |
cd .. && git submodule update --init $(shell dirname $(THIRDPARTYLIBS)/$@) |
12 |
|
13 |
x264/config.mak: x264/.git |
14 |
cd x264 && ./configure --prefix=$(THIRDPARTYLIBS)/x264-install/ || { echo "Error configuring x264" && exit 1; } |
15 |
|
16 |
x264-build: x264/config.mak |
17 |
$(MAKE) -C x264 || { echo "Error compiling x264" && exit 1; } |
18 |
|
19 |
x264-install: x264-build |
20 |
$(MAKE) -C x264 install || { echo "Error installing x264" && exit 1; } |
21 |
|
22 |
ffmpeg/.git: x264-install |
23 |
cd .. && git submodule update --init $(shell dirname $(THIRDPARTYLIBS)/$@) |
24 |
cd ffmpeg && ./configure --enable-libx264 --enable-gpl --enable-pthreads --extra-cflags=-I$(THIRDPARTYLIBS)/x264-install/include --extra-ldflags=-L$(THIRDPARTYLIBS)/x264-install/lib --prefix=$(THIRDPARTYLIBS)/ffmpeg-install || { echo "Error configuring ffmpeg" && exit 1; } |
25 |
#in case x264 is not reqired (do we need the encoding?): ./configure --enable-gpl --enable-pthreads --prefix=$BASEDIR/ffmpeg-install |
26 |
|
27 |
ffmpeg-build: ffmpeg/.git |
28 |
$(MAKE) -C ffmpeg || { echo "Error compiling ffmpeg" && exit 1; } |
29 |
|
30 |
ffmpeg-install: ffmpeg-build |
31 |
$(MAKE) -C ffmpeg install || { echo "Error installing ffmpeg" && exit 1; } |
32 |
|
33 |
GRAPES/.git: ffmpeg-install |
34 |
cd .. && git submodule update --init $(shell dirname $(THIRDPARTYLIBS)/$@) |
35 |
|
36 |
GRAPES-build: GRAPES/.git |
37 |
FFDIR=$(THIRDPARTYLIBS)/ffmpeg $(MAKE) -C GRAPES || { echo "Error compiling GRAPES" && exit 1; } |
38 |
|
39 |
NAPA-BASELIBS/.git: |
40 |
cd .. && git submodule update --init $(shell dirname $(THIRDPARTYLIBS)/$@) |
41 |
|
42 |
NAPA-build: NAPA-BASELIBS/.git |
43 |
cd NAPA-BASELIBS && ./build_all.sh -q |
44 |
|
45 |
clean: |
46 |
$(MAKE) -C GRAPES clean |