diff options
Diffstat (limited to 'src/suil_internal.h')
-rw-r--r-- | src/suil_internal.h | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/src/suil_internal.h b/src/suil_internal.h index 0e565cb..b72c545 100644 --- a/src/suil_internal.h +++ b/src/suil_internal.h @@ -37,6 +37,10 @@ static inline char* dlerror(void) { return "Unknown error"; } #include "suil/suil.h" +#ifdef __cplusplus +extern "C" { +#endif + #define SUIL_ERRORF(fmt, ...) fprintf(stderr, "suil error: " fmt, __VA_ARGS__) struct SuilHostImpl { @@ -89,7 +93,15 @@ typedef SuilWrapper* (*SuilWrapperNewFunc)(SuilHost* host, LV2_Feature*** features, unsigned n_features); -typedef void (*SuilVoidFunc)(); +/** Prototype for suil_wrapper_new in each module. */ +SuilWrapper* +suil_wrapper_new(SuilHost* host, + const char* host_type_uri, + const char* ui_type_uri, + LV2_Feature*** features, + unsigned n_features); + +typedef void (*SuilVoidFunc)(void); /** dlsym wrapper to return a function pointer (without annoying warning) */ static inline SuilVoidFunc @@ -124,4 +136,8 @@ suil_add_feature(LV2_Feature*** features, *n += 1; } +#ifdef __cplusplus +} /* extern "C" */ +#endif + #endif // SUIL_INTERNAL_H |