diff --git a/Fw/Types/BasicTypes.h b/Fw/Types/BasicTypes.h index 26675350c1..d4bdf1f88a 100644 --- a/Fw/Types/BasicTypes.h +++ b/Fw/Types/BasicTypes.h @@ -13,6 +13,10 @@ #ifndef FW_BASIC_TYPES_H #define FW_BASIC_TYPES_H +#ifdef __cplusplus +extern "C" { +#endif + // Compiler checks #if defined(__GNUC__) || defined(__llvm__) || defined(PLATFORM_OVERRIDE_GCC_CLANG_CHECK) #else @@ -79,4 +83,8 @@ typedef PlatformPointerCastType POINTER_CAST; #define PRIVATE private //!< overridable private for unit testing #endif +#ifdef __cplusplus +} +#endif + #endif // FW_BASIC_TYPES_H diff --git a/Fw/Types/CAssert.h b/Fw/Types/CAssert.h index 0b60953c0c..17e417e0ce 100644 --- a/Fw/Types/CAssert.h +++ b/Fw/Types/CAssert.h @@ -10,6 +10,10 @@ #include +#ifdef __cplusplus +extern "C" { +#endif + #if FW_ASSERT_LEVEL == FW_NO_ASSERT #define FW_CASSERT(...) @@ -28,4 +32,9 @@ I32 CAssert0(FILE_NAME_ARG file, U32 lineNo); //!< C asse I32 CAssert1(FILE_NAME_ARG file, U32 lineNo, NATIVE_INT_TYPE arg1); //!< C assert function 1 #endif // ASSERT is defined + +#ifdef __cplusplus +} +#endif + #endif /* FWCASSERT_HPP_ */ diff --git a/Utils/Hash/libcrc/lib_crc.h b/Utils/Hash/libcrc/lib_crc.h index 3a831bd60f..e84f1693f7 100644 --- a/Utils/Hash/libcrc/lib_crc.h +++ b/Utils/Hash/libcrc/lib_crc.h @@ -50,6 +50,9 @@ #ifndef UTILS_HASH_LIB_CRC_HPP #define UTILS_HASH_LIB_CRC_HPP +#ifdef __cplusplus +extern "C" { +#endif #define CRC_VERSION "1.16" @@ -67,4 +70,8 @@ unsigned short update_crc_dnp( unsigned short crc, char c unsigned short update_crc_kermit( unsigned short crc, char c ); unsigned short update_crc_sick( unsigned short crc, char c, char prev_byte ); +#ifdef __cplusplus +} +#endif + #endif // UTILS_HASH_LIB_CRC_HPP diff --git a/cmake/platform/types/PlatformTypes.h b/cmake/platform/types/PlatformTypes.h index ca5962779b..e71c2f91e1 100644 --- a/cmake/platform/types/PlatformTypes.h +++ b/cmake/platform/types/PlatformTypes.h @@ -26,6 +26,10 @@ #include #include +#ifdef __cplusplus +extern "C" { +#endif + // Define what types and checks are supported by this platform #define FW_HAS_64_BIT 1 //!< Architecture supports 64 bit integers #define FW_HAS_32_BIT 1 //!< Architecture supports 32 bit integers @@ -86,5 +90,10 @@ typedef uint8_t PlatformPointerCastType; #else #error "Expected __SIZEOF_POINTER__ to be one of 8, 4, 2, or 1" #endif +#endif // PLATFORM_POINTER_CAST_TYPE_DEFINED + +#ifdef __cplusplus +} #endif + #endif // PLATFORM_TYPES_H_ diff --git a/config/FpConfig.h b/config/FpConfig.h index 52ee212fca..f49f6e17f3 100644 --- a/config/FpConfig.h +++ b/config/FpConfig.h @@ -13,6 +13,10 @@ #include +#ifdef __cplusplus +extern "C" { +#endif + // ---------------------------------------------------------------------- // Type aliases // ---------------------------------------------------------------------- @@ -439,4 +443,9 @@ typedef FwIndexType FwQueueSizeType; // DO NOT TOUCH. These types are specified for backwards naming compatibility. typedef FwSizeStoreType FwBuffSizeType; #define PRI_FwBuffSizeType PRI_FwSizeStoreType + +#ifdef __cplusplus +} +#endif + #endif