provides developper files
authorJosé Bollo <jose.bollo@iot.bzh>
Tue, 17 May 2016 13:12:11 +0000 (15:12 +0200)
committerJosé Bollo <jose.bollo@iot.bzh>
Tue, 17 May 2016 13:29:46 +0000 (15:29 +0200)
Change-Id: I0e41a0db778c69b5f5ce71115d495b2bb8b4cffe
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
21 files changed:
CMakeLists.txt
include/CMakeLists.txt [new file with mode: 0644]
include/afb/afb-evmgr-itf.h [moved from include/afb-evmgr-itf.h with 100% similarity]
include/afb/afb-plugin.h [moved from include/afb-plugin.h with 97% similarity]
include/afb/afb-req-itf.h [moved from include/afb-req-itf.h with 100% similarity]
plugins/afm-main-plugin/afm-main-plugin.c
plugins/audio/audio-api.c
plugins/media/media-api.c
plugins/radio/radio-api.c
plugins/samples/ClientCtx.c
plugins/samples/HelloWorld.c
plugins/samples/SamplePost.c
plugins/session/token-api.c
src/afb-api-dbus.c
src/afb-api-so.c
src/afb-apis.c
src/afb-hreq.c
src/afb-hsrv.c
src/afb-hswitch.c
src/afb-ws-json1.c
src/main.c

index 12e4be9..7600010 100644 (file)
@@ -121,5 +121,6 @@ SET(plugin_install_dir ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}/afb)
 ADD_DEFINITIONS(-DPLUGIN_INSTALL_DIR="${plugin_install_dir}")
 
 ADD_SUBDIRECTORY(src)
+ADD_SUBDIRECTORY(include)
 ADD_SUBDIRECTORY(plugins)
 
diff --git a/include/CMakeLists.txt b/include/CMakeLists.txt
new file mode 100644 (file)
index 0000000..07cbb04
--- /dev/null
@@ -0,0 +1 @@
+INSTALL(DIRECTORY afb DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
similarity index 97%
rename from include/afb-plugin.h
rename to include/afb/afb-plugin.h
index 40b26cf..2cfe628 100644 (file)
@@ -17,8 +17,8 @@
 
 #pragma once
 
-#include "afb-req-itf.h"
-#include "afb-evmgr-itf.h"
+#include <afb/afb-req-itf.h>
+#include <afb/afb-evmgr-itf.h>
 
 /* Plugin Type */
 enum  AFB_pluginE
index 9576730..705efcb 100644 (file)
@@ -21,7 +21,7 @@
 #include <assert.h>
 #include <json-c/json.h>
 
-#include "afb-plugin.h"
+#include <afb/afb-plugin.h>
 
 #include "utils-jbus.h"
 
index 00f8100..c486d1c 100644 (file)
@@ -25,8 +25,8 @@
 #include "audio-pulse.h"
 #endif
 
-#include "afb-plugin.h"
-#include "afb-req-itf.h"
+#include <afb/afb-plugin.h>
+#include <afb/afb-req-itf.h>
 
 /* ------ BACKEND FUNCTIONS ------- */
 
index 7b4fa18..91676d4 100644 (file)
@@ -24,8 +24,8 @@
 #include "media-api.h"
 #include "media-rygel.h"
 
-#include "afb-plugin.h"
-#include "afb-req-itf.h"
+#include <afb/afb-plugin.h>
+#include <afb/afb-req-itf.h>
 
 json_object* _rygel_list (mediaCtxHandleT *);
 
index edeb978..e4a89ba 100644 (file)
@@ -22,8 +22,8 @@
 #include "radio-api.h"
 #include "radio-rtlsdr.h"
 
-#include "afb-plugin.h"
-#include "afb-req-itf.h"
+#include <afb/afb-plugin.h>
+#include <afb/afb-req-itf.h>
 
 /* ********************************************************
 
index 4d8e720..bf26937 100644 (file)
@@ -19,7 +19,7 @@
 #include <stdio.h>
 #include <json-c/json.h>
 
-#include "afb-plugin.h"
+#include <afb/afb-plugin.h>
 
 typedef struct {
   /* 
index 6f9d01d..4795dd3 100644 (file)
@@ -19,7 +19,7 @@
 #include <string.h>
 #include <json-c/json.h>
 
-#include "afb-plugin.h"
+#include <afb/afb-plugin.h>
 
 const struct AFB_interface *interface;
 
index 25e73f9..1d3069e 100644 (file)
@@ -20,7 +20,7 @@
 #include <string.h>
 #include <json-c/json.h>
 
-#include "afb-plugin.h"
+#include <afb/afb-plugin.h>
 
 
 // Sample Generic Ping Debug API
index 8028948..fd31260 100644 (file)
@@ -19,7 +19,7 @@
 #include <stdio.h>
 #include <json-c/json.h>
 
-#include "afb-plugin.h"
+#include <afb/afb-plugin.h>
 
 // Dummy sample of Client Application Context
 typedef struct {
index 3a882a5..52d449f 100644 (file)
@@ -25,8 +25,8 @@
 #include <systemd/sd-bus.h>
 #include <json-c/json.h>
 
-#include "afb-plugin.h"
-#include "afb-req-itf.h"
+#include <afb/afb-plugin.h>
+#include <afb/afb-req-itf.h>
 
 #include "afb-common.h"
 
index 6ac5070..72599e5 100644 (file)
@@ -27,9 +27,9 @@
 #include <sys/types.h>
 #include <sys/stat.h>
 
-#include "afb-plugin.h"
-#include "afb-req-itf.h"
-#include "afb-evmgr-itf.h"
+#include <afb/afb-plugin.h>
+#include <afb/afb-req-itf.h>
+#include <afb/afb-evmgr-itf.h>
 
 #include "session.h"
 #include "afb-common.h"
index 834850f..5ebc96f 100644 (file)
@@ -26,7 +26,7 @@
 #include "verbose.h"
 #include "afb-apis.h"
 #include "afb-context.h"
-#include "afb-req-itf.h"
+#include <afb/afb-req-itf.h>
 
 struct api_desc {
        struct afb_api api;
index 0f2f0ff..a1c750b 100644 (file)
@@ -33,7 +33,7 @@
 #endif
 
 #include "afb-method.h"
-#include "afb-req-itf.h"
+#include <afb/afb-req-itf.h>
 #include "afb-msg-json.h"
 #include "afb-context.h"
 #include "afb-hreq.h"
@@ -471,6 +471,7 @@ int afb_hreq_reply_file(struct afb_hreq *hreq, int dirfd, const char *filename)
 
 int afb_hreq_redirect_to(struct afb_hreq *hreq, const char *url)
 {
+       /* TODO: append the query part! */
        afb_hreq_reply_static(hreq, MHD_HTTP_MOVED_PERMANENTLY, 0, NULL,
                        MHD_HTTP_HEADER_LOCATION, url, NULL);
        DEBUG("redirect from [%s] to [%s]", hreq->url, url);
index 743315c..46e61a0 100644 (file)
@@ -33,7 +33,7 @@
 #include "afb-context.h"
 #include "afb-hreq.h"
 #include "afb-hsrv.h"
-#include "afb-req-itf.h"
+#include <afb/afb-req-itf.h>
 #include "verbose.h"
 
 #include "afb-common.h"
index bdded7f..8dee80b 100644 (file)
@@ -23,7 +23,7 @@
 
 #include <microhttpd.h>
 
-#include "afb-req-itf.h"
+#include <afb/afb-req-itf.h>
 #include "afb-context.h"
 #include "afb-hreq.h"
 #include "afb-apis.h"
index fe7514d..85dc025 100644 (file)
@@ -29,7 +29,7 @@
 #include "afb-ws-json1.h"
 #include "afb-msg-json.h"
 #include "session.h"
-#include "afb-req-itf.h"
+#include <afb/afb-req-itf.h>
 #include "afb-apis.h"
 #include "afb-context.h"
 
index fdea907..dbfbac5 100644 (file)
@@ -41,7 +41,7 @@
 #include "verbose.h"
 #include "afb-common.h"
 
-#include "afb-plugin.h"
+#include <afb/afb-plugin.h>
 
 #if !defined(PLUGIN_INSTALL_DIR)
 #error "you should define PLUGIN_INSTALL_DIR"