summaryrefslogtreecommitdiffstats
path: root/filescan-utils.h
diff options
context:
space:
mode:
authorFulup Ar Foll <fulup@iot.bzh>2017-10-23 18:05:33 +0200
committerRomain Forlot <romain.forlot@iot.bzh>2018-12-13 14:12:02 +0100
commitcabfef0ff81395a2286e11b416ae07f22e335730 (patch)
treeb752a8b83813eb896f367bffc0caa4722959ba31 /filescan-utils.h
parent239f29ae28da7ebf55510fb7fffb47d32fbf52cd (diff)
Prepare for future API-V3
Diffstat (limited to 'filescan-utils.h')
-rw-r--r--filescan-utils.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/filescan-utils.h b/filescan-utils.h
index e17867e..940eafd 100644
--- a/filescan-utils.h
+++ b/filescan-utils.h
@@ -26,8 +26,17 @@
extern "C" {
#endif
-#define AFB_BINDING_VERSION 2
-#include <afb/afb-binding.h>
+// hack waiting for official V3 API
+#ifdef USE_API_DYN
+ #define AFB_BINDING_VERSION dyn
+ #include <afb/afb-binding.h>
+ extern afb_dynapi *AFB_default;
+ #define AFB_DEBUG(...) AFB_DYNAPI_DEBUG(AFB_default, __VA_ARGS__)
+#else
+ #define AFB_BINDING_VERSION 2
+ #include <afb/afb-binding.h>
+#endif
+
#include <json-c/json.h>
#ifndef PUBLIC