forked from meetecho/janus-gateway
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.am
116 lines (86 loc) · 2.65 KB
/
Makefile.am
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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
ACLOCAL_AMFLAGS = -I m4
# FIXME: These should be enabled once the code is safe for them. That requires
# some fairly big refactoring though, which can wait.
# AM_CFLAGS += -Wshadow -Wstrict-aliasing=2
# FIXME: make docs work with distcheck
DISTCHECK_CONFIGURE_FLAGS = --disable-docs --enable-post-processing
EXTRA_DIST = $(NULL)
CLEANFILES = $(NULL)
confdir = $(sysconfdir)/janus
conf_DATA = conf/janus.jcfg.sample
plugindir = $(libdir)/janus/plugins
transportdir = $(libdir)/janus/transports
eventdir = $(libdir)/janus/events
loggerdir = $(libdir)/janus/loggers
SUBDIRS = src html
dist_html_DATA = README.md
demosdir = $(datadir)/janus/demos
demos_DATA = $(NULL)
jsmodulesdir = $(datadir)/janus/javascript
jsmodules_DATA = html/janus.js
%.sample: %.sample.in
$(MKDIR_P) $(@D)
$(AM_V_GEN) sed -e "\
s|[@]confdir[@]|$(confdir)|;\
s|[@]plugindir[@]|$(plugindir)|;\
s|[@]transportdir[@]|$(transportdir)|;\
s|[@]eventdir[@]|$(eventdir)|;\
s|[@]loggerdir[@]|$(loggerdir)|;\
s|[@]recordingsdir[@]|$(recordingsdir)|;\
s|[@]demosdir[@]|$(demosdir)|;\
s|[@]streamdir[@]|$(streamdir)|; \
s|[@]luadir[@]|$(luadir)|; \
s|[@]duktapedir[@]|$(duktapedir)|" \
$< > $@ || rm $@
EXTRA_DIST += conf/janus.jcfg.sample.in
CLEANFILES += conf/janus.jcfg.sample
##
# Fuzzers checking
##
check-fuzzers: FORCE
CC=$(CC) SKIP_JANUS_BUILD=1 LIB_FUZZING_ENGINE=fuzzers/standalone.o ./fuzzers/build.sh
./fuzzers/run.sh rtcp_fuzzer out/rtcp_fuzzer_seed_corpus
./fuzzers/run.sh rtp_fuzzer out/rtp_fuzzer_seed_corpus
./fuzzers/run.sh sdp_fuzzer out/sdp_fuzzer_seed_corpus
.PHONY: FORCE
FORCE:
##
# Docs
##
if ENABLE_DOCS
SUBDIRS += docs
endif
##
# JavaScript module flavours for janus.js
##
if ENABLE_JAVASCRIPT_ES_MODULE
jsmodules_DATA += npm/bundles/janus.es.js
endif
if ENABLE_JAVASCRIPT_UMD_MODULE
jsmodules_DATA += npm/bundles/janus.umd.js
endif
if ENABLE_JAVASCRIPT_IIFE_MODULE
jsmodules_DATA += npm/bundles/janus.iife.js
endif
if ENABLE_JAVASCRIPT_COMMON_JS_MODULE
jsmodules_DATA += npm/bundles/janus.cjs.js
endif
EXTRA_DIST += $(jsmodules_DATA)
if ENABLE_JAVASCRIPT_MODULES
npm/node_modules/rollup/bin/rollup: npm/package.json
cd npm && $(NPM) install && touch node_modules/rollup/bin/rollup
npm/bundles/janus.%.js: html/janus.js npm/node_modules/rollup/bin/rollup npm/rollup.config.js npm/module.js
cd npm && $(NPM) run rollup -- --o $(patsubst npm/%,%,$@) --f $*
endif
##
# Configuration
##
configs:
$(MKDIR_P) $(DESTDIR)$(confdir)
$(foreach config,$(conf_DATA),cp "$(CURDIR)/$(config)" "$(DESTDIR)$(confdir)/$(notdir $(basename $(config) .sample))";)
$(MAKE) -C src configs
##
# Extra cleanup
##
clean-local:
-rm -f docs/doxygen_sqlite3.db