Commit 30c01461 authored by Jim Harris's avatar Jim Harris
Browse files

event: add extern "C" wrappers to event.h



Allows this header to be included by C++ code.
Public header files (in include/spdk) already have
all of these - portions of event.h may eventually
move to an officially public header file, but until
then just add the extern "C" wrappers here for now.
This allows it to be included directly by C++
frameworks such as Seastar to do SPDK subsystem
initialization.

Signed-off-by: default avatarJim Harris <james.r.harris@intel.com>
Change-Id: I02275cde348d21510bbb69dcdb65cf85171e16b6

Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/466475


Reviewed-by: default avatarPaul Luse <paul.e.luse@intel.com>
Reviewed-by: default avatarChangpeng Liu <changpeng.liu@intel.com>
Reviewed-by: default avatarBroadcom SPDK FC-NVMe CI <spdk-ci.pdl@broadcom.com>
Reviewed-by: default avatarShuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: default avatarBen Walker <benjamin.walker@intel.com>
Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
parent d5073677
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -36,6 +36,10 @@

#include "spdk/stdinc.h"

#ifdef __cplusplus
extern "C" {
#endif

#include "spdk/event.h"
#include "spdk/json.h"
#include "spdk/thread.h"
@@ -129,4 +133,8 @@ void spdk_rpc_finish(void);
		spdk_add_subsystem_depend(&__subsystem_ ## _name ## _depend_on ## _depends_on); \
	}

#ifdef __cplusplus
}
#endif

#endif /* SPDK_INTERNAL_EVENT_H */