-
-
Notifications
You must be signed in to change notification settings - Fork 49
/
Copy pathglobals.mk
32 lines (27 loc) · 846 Bytes
/
globals.mk
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
# Global variables
src=$(abs_top_srcdir)
ringlibdir=$(DESTDIR)$(libdir)/ring
ASTYLERC="$(top_srcdir)/../astylerc"
indent="/usr/bin/astyle"
RING_DIRTY_REPO ?= $(shell git diff-index --quiet HEAD 2>/dev/null || echo dirty)
RING_REVISION ?= $(shell git log -1 --format="%h" --abbrev=10 2>/dev/null)
# Preprocessor flags
AM_CPPFLAGS = \
-I$(src)/src \
-I$(src)/src/config \
-I$(src)/src/media \
-I$(src)/test \
-I$(src)/src/dring \
$(SIP_CFLAGS) \
-DPREFIX=\"$(prefix)\" \
-DPROGSHAREDIR=\"${datadir}/ring\" \
-DENABLE_TRACE \
-DRING_REVISION=\"$(RING_REVISION)\" \
-DRING_DIRTY_REPO=\"$(RING_DIRTY_REPO)\" \
-DPJSIP_MAX_PKT_LEN=8000 \
-DPJ_AUTOCONF=1
indent:
@echo "Indenting code:"
if [ -f $(ASTYLERC) ] ; then \
find $(top_srcdir)/src/ -name \*.cpp -o -name \*.h | xargs $(indent) --options=$(ASTYLERC) ; \
fi