Windows 10 build: Some tests don't compile

Hello,
I got a sqlcipher build on windows 10 using the instructions at https://stackoverflow.com/questions/29196087/how-to-build-the-qt-sql-driver-plugin-qsqlcipher-for-sqlite-db-with-sqlcipher. Some of the tests (like fuzz data tests) build and run successfully. But I see the following errors, and the compile fails due to the following errors:

/fileio.c:545:3: error: unknown type name ’ DIR ’ 545 | DIR *pDir;
ext/misc/fileio.c:700:17: error: invalid use of undefined type ’ struct DIRENT

Can you please just give me a hint, on what is needed to supply these types?

Thanks

Help please.

Thanks.