Building simple.c on Windows

Hi,
I’m trying to use Graphviz as a library on Windows, but I can’t figure out how. As a first step, I want to compile simple.c from the documentation page.

I managed to do this on OpenBSD already, but am totally lost on Windows. I already spent multiple hours fumbling around with MSYS2 and MinGW / Mingw-w64, but just can’t get it right.

Has someone around here managed to use Graphviz as a library on Windows and could write up some noob-friendly instructions on how to do this? I would really appreciate the help!