aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLaurent Ghigonis <laurent@p1sec.com>2013-09-20 06:34:58 +0200
committerLaurent Ghigonis <laurent@p1sec.com>2013-09-20 06:34:58 +0200
commit41b9c2ad2fa53e1fefbb6e52c75831dcdbc42434 (patch)
treee81f469cf415d276fb92c58583afa6c9eaff20f2
parentredis notifications test (diff)
downloadglouglou-41b9c2ad2fa53e1fefbb6e52c75831dcdbc42434.tar.xz
glouglou-41b9c2ad2fa53e1fefbb6e52c75831dcdbc42434.zip
glougloud viz module notification
-rw-r--r--v3/glougloud/glougloud_mod_0_internal/Makefile22
-rw-r--r--v3/glougloud/glougloud_mod_0_internal/glougloud_mod_0_internal.c50
-rw-r--r--v3/glougloud/glougloud_mod_1_net/Makefile (renamed from v3/glougloud/glougloud_mod_net/Makefile)0
-rw-r--r--v3/glougloud/glougloud_mod_1_net/glougloud_mod_1_net.c (renamed from v3/glougloud/glougloud_mod_net/glougloud_mod_net.c)0
4 files changed, 72 insertions, 0 deletions
diff --git a/v3/glougloud/glougloud_mod_0_internal/Makefile b/v3/glougloud/glougloud_mod_0_internal/Makefile
new file mode 100644
index 0000000..e9afc40
--- /dev/null
+++ b/v3/glougloud/glougloud_mod_0_internal/Makefile
@@ -0,0 +1,22 @@
+#CFLAGS += -Wall -O2 -fPIC -shared -g
+CFLAGS += -Wall -O0 -fPIC -shared -g
+
+LIBDIR=/var/lib/glougloud/chroot/modules/
+LIBNAME=glougloud_mod_0_internal
+
+TARGET = ${LIBNAME}.so
+SOURCES = glougloud_mod_0_internal.c
+OBJECTS = $(SOURCES:.c=.o)
+
+all: $(TARGET)
+
+$(TARGET): $(OBJECTS)
+ $(CC) $(CFLAGS) -o $(TARGET) $(OBJECTS)
+
+install:
+ @echo "installation of $(LIBNAME)"
+ mkdir -p $(LIBDIR)
+ install -m 0644 $(TARGET) $(LIBDIR)
+
+clean:
+ rm -f $(TARGET) $(OBJECTS)
diff --git a/v3/glougloud/glougloud_mod_0_internal/glougloud_mod_0_internal.c b/v3/glougloud/glougloud_mod_0_internal/glougloud_mod_0_internal.c
new file mode 100644
index 0000000..38d7119
--- /dev/null
+++ b/v3/glougloud/glougloud_mod_0_internal/glougloud_mod_0_internal.c
@@ -0,0 +1,50 @@
+#include <glougloud.h>
+
+#include <libglouglou.h>
+
+struct ggdmodviz_conf *
+ggdmodviz_init(struct glougloud *ggd)
+{
+ struct ggdmodviz_conf *mod;
+
+ log_debug("glougloud_mod_internal: viz init");
+
+ mod = xcalloc(1, sizeof(struct ggdmodviz_conf));
+ mod->id = 0;
+ mod->api_version = 1;
+
+ return mod;
+}
+
+char *
+ggdmodviz_text_get(struct ggdviz_cli *cli, char *op, char *target)
+{
+ log_debug("glougloud_mod_internal:\nop: %s\ntarget: %s");
+ return NULL;
+}
+
+void *
+ggdmodviz_netstream_get(struct ggdviz_cli *cli, char *notification)
+{
+ return NULL;
+}
+
+int
+ggdmodviz_conf_set(struct ggdviz_cli *cli, void *conf)
+{
+ return -1;
+}
+
+int
+ggmodprobe_init(struct glougloud *ggd)
+{
+ log_debug("glougloud_mod_internal: probe init");
+ return 0;
+}
+
+char *
+ggdmodprobe_redis_get(struct ggdprobe_cli *prb,
+ struct gg_packet *pkt)
+{
+ return NULL;
+}
diff --git a/v3/glougloud/glougloud_mod_net/Makefile b/v3/glougloud/glougloud_mod_1_net/Makefile
index 8bdcf2f..8bdcf2f 100644
--- a/v3/glougloud/glougloud_mod_net/Makefile
+++ b/v3/glougloud/glougloud_mod_1_net/Makefile
diff --git a/v3/glougloud/glougloud_mod_net/glougloud_mod_net.c b/v3/glougloud/glougloud_mod_1_net/glougloud_mod_1_net.c
index 758767b..758767b 100644
--- a/v3/glougloud/glougloud_mod_net/glougloud_mod_net.c
+++ b/v3/glougloud/glougloud_mod_1_net/glougloud_mod_1_net.c