diff --git a/src/libnfc.h b/src/libnfc.h index 25045fb..588acf9 100644 --- a/src/libnfc.h +++ b/src/libnfc.h @@ -32,6 +32,10 @@ #include "defines.h" #include "types.h" +#ifdef __cplusplus + #define NFCAPI extern "C" { +#endif // __cplusplus + /** * @fn dev_info* nfc_connect(nfc_device_desc_t* pndd) * @brief Connect to a NFC device @@ -231,5 +235,10 @@ bool nfc_target_send_bytes(const dev_info* pdi, const byte_t* pbtTx, const size_ */ bool nfc_target_send_dep_bytes(const dev_info* pdi, const byte_t* pbtTx, const size_t szTxLen); +#ifdef __cplusplus +} +#endif // __cplusplus + + #endif // _LIBNFC_H_