Do I need an extern \"C\" {} block to include standard C headers in a C++ program. Only consider standard C headers which do not have counterparts in C++.
No, you should use the C++ wrapper headers (for instance like ). Those take care of all that for you.
If it's a header that doesn't have those, then yes, you'll want to wrap them in extern "C" {}.
ETA: It's worth noting that many implementations will include the wrapper inside the .h file like below, so that you can get away with not doing it yourself.
#ifdef __cplusplus
extern "C" {
#endif
#ifdef __cplusplus
}
#endif