From c98e73039798f569d3f5bdf2e96997e0d322aa48 Mon Sep 17 00:00:00 2001 From: jpekkila Date: Tue, 23 Jul 2019 15:02:54 +0300 Subject: [PATCH] Added extern C to the include headers --- include/astaroth.h | 8 ++++++++ include/astaroth_defines.h | 9 +++++++++ 2 files changed, 17 insertions(+) diff --git a/include/astaroth.h b/include/astaroth.h index 2df267d..b45db11 100644 --- a/include/astaroth.h +++ b/include/astaroth.h @@ -18,6 +18,10 @@ */ #pragma once +#ifdef __cplusplus +extern "C" { +#endif + #include "astaroth_defines.h" typedef struct { @@ -208,3 +212,7 @@ acSetParam(const AcReal3Param param, const AcReal3 value, AcMeshInfo* info) info->real3_params[param] = value; } */ + +#ifdef __cplusplus +} // extern "C" +#endif diff --git a/include/astaroth_defines.h b/include/astaroth_defines.h index f05685b..222dc9e 100644 --- a/include/astaroth_defines.h +++ b/include/astaroth_defines.h @@ -17,6 +17,11 @@ along with Astaroth. If not, see . */ #pragma once + +#ifdef __cplusplus +extern "C" { +#endif + #include // FLT_EPSILON, etc #include // size_t #include // CUDA vector types (float4, etc) @@ -110,3 +115,7 @@ extern const char* int3param_names[]; extern const char* realparam_names[]; extern const char* real3param_names[]; extern const char* vtxbuf_names[]; + +#ifdef __cplusplus +} // extern "C" +#endif