Browse code

core: support radius radcli lib

Victor Seva authored on 10/05/2016 06:10:20
Showing 2 changed files
... ...
@@ -28,7 +28,13 @@ DEFS+= -DUSE_FREERADIUS
28 28
 RADIUSCLIENT_LIB=freeradius-client
29 29
 
30 30
 else
31
+ifeq ($(RADCLI),1)
31 32
 
33
+# - radcli library
34
+DEFS+= -DUSE_RADCLI
35
+RADIUSCLIENT_LIB=radcli
36
+
37
+else
32 38
 # - radiusclient-ng v5 or v4 library
33 39
 ifneq ($(radiusclient_ng), 4)
34 40
 
... ...
@@ -42,6 +48,7 @@ DEFS+=-DRADIUSCLIENT_NG_4
42 42
 RADIUSCLIENT_LIB=radiusclient
43 43
 
44 44
 endif
45
+endif
45 46
 
46 47
 endif
47 48
 
... ...
@@ -32,9 +32,14 @@
32 32
 #define _RADIUS_CORE_H
33 33
 
34 34
 #ifndef USE_FREERADIUS
35
-	#include <radiusclient-ng.h>
36
-	#define DEFAULT_RADIUSCLIENT_CONF \
37
-		"/usr/local/etc/radiusclient-ng/radiusclient.conf"
35
+	#ifdef USE_RADCLI
36
+		#include <radcli/radcli.h>
37
+		#define DEFAULT_RADIUSCLIENT_CONF ""
38
+	#else
39
+		#include <radiusclient-ng.h>
40
+		#define DEFAULT_RADIUSCLIENT_CONF \
41
+			"/usr/local/etc/radiusclient-ng/radiusclient.conf"
42
+	#endif
38 43
 #else
39 44
 	#include <freeradius-client.h>
40 45
 	#define DEFAULT_RADIUSCLIENT_CONF ""