aboutsummaryrefslogtreecommitdiffstats
path: root/ctl-lib/afb-definitions.h
diff options
context:
space:
mode:
authorJonathan Aillet <jonathan.aillet@iot.bzh>2018-07-10 10:20:12 +0200
committerJonathan Aillet <jonathan.aillet@iot.bzh>2018-07-10 08:50:53 +0000
commit440be0984f16562fdf321c770d65787ecea0e36d (patch)
tree9becb3fb9530a102c7a8bec00e73f17f2da991a4 /ctl-lib/afb-definitions.h
parent67b6d49ee0edca5177232cf9978b41d5c098f152 (diff)
Use binding version to set controller definitions
Use binding version to set controller definitions. It is cleaner to define binding version directly into repository cmake than into a header like before this commit. Change-Id: Ie0f2812c8ac980e69ff901fb6e347f47f284f21b Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
Diffstat (limited to 'ctl-lib/afb-definitions.h')
-rw-r--r--ctl-lib/afb-definitions.h7
1 files changed, 2 insertions, 5 deletions
diff --git a/ctl-lib/afb-definitions.h b/ctl-lib/afb-definitions.h
index d621f27..cf84fa4 100644
--- a/ctl-lib/afb-definitions.h
+++ b/ctl-lib/afb-definitions.h
@@ -21,9 +21,7 @@
#define _AFB_DEFINITIONS_INCLUDE_
// Waiting for a clean AppFW-V3 API
-#ifdef USE_API_DYN
- #define AFB_BINDING_VERSION 0
- #define AFB_BINDING_WANT_DYNAPI
+#if((AFB_BINDING_VERSION == 0 || AFB_BINDING_VERSION == 3) && defined(AFB_BINDING_WANT_DYNAPI))
#include <afb/afb-binding.h>
#define AFB_BINDING_PREV3
@@ -82,8 +80,7 @@
uint32_t session;
} AFB_ApiVerbs;
-#else
- #define AFB_BINDING_VERSION 2
+#elif(AFB_BINDING_VERSION == 2)
#include <afb/afb-binding.h>
typedef struct afb_req AFB_ReqT;