bcrypt.h omits windows.h, but makes use of Windows data types (LONG, ULONG, etc). This results in a build failure if the external program doesn't include windows.h first:
// i686-w64-mingw32-gcc -c bug.c
#include "bcrypt.h"
bcrypt.h:27:11: error: unknown type name 'LONG'
27 | typedef LONG NTSTATUS,*PNTSTATUS;
| ^~~~
...