diff options
| author | Dennis Brentjes <d.brentjes@gmail.com> | 2016-08-29 15:33:00 +0200 |
|---|---|---|
| committer | Dennis Brentjes <d.brentjes@gmail.com> | 2016-08-29 15:33:00 +0200 |
| commit | 4dea13e3cd25b6de602ffb53be5e60005b6ba10b (patch) | |
| tree | 35207ab9ef49540dabf44ce935edbed29dce4a36 /libcmix | |
| parent | 14f06109fe736d06d30f99a4acc0bd1f233ec2af (diff) | |
| download | cmix-4dea13e3cd25b6de602ffb53be5e60005b6ba10b.tar.gz cmix-4dea13e3cd25b6de602ffb53be5e60005b6ba10b.tar.bz2 cmix-4dea13e3cd25b6de602ffb53be5e60005b6ba10b.zip | |
Cleaned up cmix libraries, added extern "C" linkage when included from c++
Diffstat (limited to 'libcmix')
| -rw-r--r-- | libcmix/CMakeLists.txt | 6 | ||||
| -rw-r--r-- | libcmix/cmix.h | 14 |
2 files changed, 14 insertions, 6 deletions
diff --git a/libcmix/CMakeLists.txt b/libcmix/CMakeLists.txt index 5d87a56..826a604 100644 --- a/libcmix/CMakeLists.txt +++ b/libcmix/CMakeLists.txt @@ -5,4 +5,8 @@ add_library(cmix target_include_directories(cmix PUBLIC ${CMAKE_CURRENT_SOURCE_DIR} -)
\ No newline at end of file +) + +target_compile_options(cmix + PRIVATE -std=c99 +) diff --git a/libcmix/cmix.h b/libcmix/cmix.h index 5fe2e13..517f067 100644 --- a/libcmix/cmix.h +++ b/libcmix/cmix.h @@ -1,11 +1,11 @@ +#ifdef __cplusplus +extern "C" { +#endif + /** * \file */ -struct message { - char buffer[2048/8]; -}; - /** * \struct * \brief The CMixBuffer struct is the temporary storage of messages in each Node. @@ -48,4 +48,8 @@ enum cmix_error get_message(char* message, struct CMixBuffer b, unsigned int ind * \param[in] index The index into the buffer * \return index_out_of_range if \p index is greater than or equal to \p b.nr_messages , otherwise no_error. */ -enum cmix_error set_message(char const* message, struct CMixBuffer b, unsigned int index);
\ No newline at end of file +enum cmix_error set_message(char const* message, struct CMixBuffer b, unsigned int index); + +#ifdef __cplusplus +} // extern "C" +#endif |
