File: Makefile

package info (click to toggle)
opensips 2.2.2-3.1
  • links: PTS
  • area: main
  • in suites: bullseye, sid
  • size: 31,160 kB
  • sloc: ansic: 334,348; xml: 91,231; perl: 6,659; sh: 5,148; sql: 4,175; makefile: 3,167; yacc: 2,499; python: 1,197; cpp: 611; php: 573
file content (50 lines) | stat: -rw-r--r-- 1,285 bytes parent folder | download | duplicates (2)
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
#
# radius module makefile
#
# 
# WARNING: do not run this directly, it should be run by the master Makefile

include ../../Makefile.defs
auto_gen=
NAME=aaa_radius.so

ETC_DIR?=../../etc/

# Find the radius library we shall use
#
ifeq ($(RADIUSCLIENT),)
RADIUSCLIENT=$(shell if [ -n "`ldconfig -p | grep radcli`" ]; then echo "RADCLI"; \
	elif [ -n "`ldconfig -p | grep freeradius`" ]; then echo "FREERADIUS"; \
	elif [ -n "`ldconfig -p | grep radiusclient-ng`" ];then echo "RADIUSCLIENT"; fi)
endif


ifneq ($(RADIUSCLIENT), RADCLI)
ifneq ($(RADIUSCLIENT), FREERADIUS)
ifeq ($(RADIUSCLIENT), RADIUSCLIENT)
	DEFS+= -DRADIUSCLIENT
	RADIUS_LIB= -lradiusclient-ng
endif
else
	DEFS+= -DFREERADIUS
	RADIUS_LIB= -lfreeradius-client
endif
else
	RADIUS_LIB= -lradiusclient-ng
	DEFS+= -DRADCLI
	RADIUS_LIB= -lradcli
endif

LIBS=$(RADIUS_LIB)

include ../../Makefile.modules

install_module_custom: $(cfg_prefix)/$(cfg_dir)
	$(INSTALL_TOUCH) \
		$(cfg_prefix)/$(cfg_dir)/dictionary.opensips.sample ; \
	$(INSTALL_CFG) $(ETC_DIR)/dictionary.opensips \
		$(cfg_prefix)/$(cfg_dir)/dictionary.opensips.sample ; \
	if [ ! -f $(cfg_prefix)/$(cfg_dir)/dictionary.opensips ]; then \
		mv -f $(cfg_prefix)/$(cfg_dir)/dictionary.opensips.sample \
			$(cfg_prefix)/$(cfg_dir)/dictionary.opensips; \
	fi; \