diff -urN a/extras/ext4_utils/sha1.c b/extras/ext4_utils/sha1.c --- a/extras/ext4_utils/sha1.c 2015-09-15 06:06:00.000000000 +0000 +++ b/extras/ext4_utils/sha1.c 2016-04-20 23:38:47.459902412 +0000 @@ -17,9 +17,6 @@ #define SHA1HANDSOFF /* Copies data before messing with it. */ -#ifndef USE_MINGW -#include -#endif #include #include #include diff -urN a/extras/ext4_utils/sha1.h b/extras/ext4_utils/sha1.h --- a/extras/ext4_utils/sha1.h 2015-09-15 06:06:00.000000000 +0000 +++ b/extras/ext4_utils/sha1.h 2016-04-20 23:37:19.204904922 +0000 @@ -20,8 +20,6 @@ #define __BEGIN_DECLS #define __END_DECLS -#else -#include #endif #define SHA1_DIGEST_LENGTH 20 @@ -33,11 +31,15 @@ u_char buffer[64]; } SHA1_CTX; -__BEGIN_DECLS +#ifdef __cplusplus +extern "C" { +#endif void SHA1Transform(uint32_t[5], const u_char[64]); void SHA1Init(SHA1_CTX *); void SHA1Update(SHA1_CTX *, const u_char *, u_int); void SHA1Final(u_char[SHA1_DIGEST_LENGTH], SHA1_CTX *); -__END_DECLS +#ifdef __cplusplus +} +#endif #endif /* _SYS_SHA1_H_ */