mod_netconf: mod_netconf only receives requests.
Since now, requests are send to the mod_netconf daemon via UNIX socket
using JSON format. There is new testing application (not completed yet)
to provide examples of sending messages to the daemon and receiving the
answers. In future, this will be done by php/python/perl/... scripts
providing web-based NETCONF GUI.
diff --git a/src/Makefile b/src/Makefile
index a817e39..af7dbd8 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -1,17 +1,21 @@
NAME=mod_netconf
-SOURCES=$(NAME).c
APXS=/usr/sbin/apxs2
-CFLAGS=-I/usr/include/libxml2
-LIBS=-lnetconf -lxml2 -lz -lm
+CFLAGS=-I/usr/include/libxml2 -I/usr/include/json
+LIBS=-lnetconf -lxml2 -lz -lm -ljson
-all: $(SOURCES)
- $(APXS) $(CPPFLAGS) $(CFLAGS) $(LIBS) -c $(SOURCES)
+all: module client
+
+module: mod_netconf.c
+ $(APXS) $(CPPFLAGS) $(CFLAGS) $(LIBS) -c mod_netconf.c
+
+client: test-client.c
+ gcc -std=gnu99 -Wall -g -ljson -I/usr/include/json test-client.c -o test-client
install: $(NAME).la
$(APXS) -i $(NAME).la
clean:
- rm -rf .libs *.la *.lo *.slo
+ rm -rf .libs *.la *.lo *.slo test-client