diff options
| author | Peter Stadler | 2019-12-07 11:45:47 +0000 |
|---|---|---|
| committer | Hauke Mehrtens | 2020-01-05 16:34:03 +0000 |
| commit | d35df8adda873dc75d876f72b78e84db8cfa72ee (patch) | |
| tree | 9e9698df46fe989924d83f9f61a16434aa045a17 | |
| parent | 041c9d1c052bb4936fd03240f7d0dd64aedda972 (diff) | |
| download | ubus-d35df8adda873dc75d876f72b78e84db8cfa72ee.tar.gz | |
ubus: make libubus ready for linking into C++
Use extern "C" { ... } if using libubus.h in a C++ project.
Signed-off-by: Peter Stadler <peter.stadler@student.uibk.ac.at>
| -rw-r--r-- | libubus.h | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -14,6 +14,10 @@ #ifndef __LIBUBUS_H #define __LIBUBUS_H +#ifdef __cplusplus +extern "C" { +#endif + #include <libubox/avl.h> #include <libubox/list.h> #include <libubox/blobmsg.h> @@ -414,4 +418,8 @@ static inline int ubus_unregister_event_handler(struct ubus_context *ctx, return ubus_remove_object(ctx, &ev->obj); } +#ifdef __cplusplus +} +#endif + #endif |