Blame view

build/rtp/Makefile 1.27 KB
c8285c8d   Hu Chunming   GB28181 UDP 有重大进展...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
  XX = g++
  
  
  PROJECT_ROOT= /home/cmhu/vpt_ascend_arm
  
  DEPEND_DIR = $(PROJECT_ROOT)/bin
  
  TARGET= $(PROJECT_ROOT)/bin/test_rtp
  
  DEFS = -DLinux
  
  
  THIRDPARTY_ROOT = $(PROJECT_ROOT)/3rdparty
  SPDLOG_ROOT = $(THIRDPARTY_ROOT)/spdlog-1.9.2/release
  
  GB28181_ROOT = /home/cmhu/vpt_ascend_arm/3rdparty/gb28181_3rd
  JRTP_ROOT = $(GB28181_ROOT)/jrtp_export
  FFMPEG_ROOT = $(THIRDPARTY_ROOT)/ffmpeg-4.4.4/release
  
  
  SRC_ROOT = /home/cmhu/vpt_ascend_arm/build/rtp
  
  
  INCLUDE=-I $(SPDLOG_ROOT)/include \
  			-I $(JRTP_ROOT)/jrtplib/include/jrtplib3 \
    			-I $(JRTP_ROOT)/jthread/include/jthread \
  			-I $(FFMPEG_ROOT)/include \
  
  
  LIBS= -L $(SPDLOG_ROOT)/lib -l:libspdlog.a \
  	-L $(JRTP_ROOT)/jthread/lib -l:libjthread.a \
     	-L $(JRTP_ROOT)/jrtplib/lib -ljrtp \
  	-L $(FFMPEG_ROOT)/lib -lavformat -lavcodec -lswscale -lavutil -lavfilter -lswresample -lavdevice \
  
  
  CXXFLAGS= -g -O0 -fPIC $(INCLUDE) $(LIBS) $(DEFS) -lpthread -lrt -lz -fexceptions -std=c++11 -D_GLIBCXX_USE_CXX11_ABI=0 -fvisibility=hidden -Wall -Wno-deprecated -Wdeprecated-declarations -Wl,-Bsymbolic -ldl
  
  
  
  SRCS:=$(wildcard $(SRC_ROOT)/*.cpp) \
  
  OBJS = $(patsubst %.cpp, %.o, $(notdir $(SRCS)))
  
  
  $(TARGET):$(OBJS)
  	rm -f $(TARGET)
  	$(XX) -o $@ $^ $(CXXFLAGS)
  # rm -f *.o
  
  %.o:$(SRC_ROOT)/%.cpp
  	$(XX) $(CXXFLAGS) -c $<
  
  clean:
  	rm -f *.o $(TARGET)