On windows it is possible to use the mingw32 (64bit) gcc compiler instead of visual studio c compiler as well and all thats needed is to add a MINGW definition in playdate_game.cmake
like this :
elseif (MINGW)
add_custom_command(
TARGET ${PLAYDATE_GAME_NAME} POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy
${CMAKE_CURRENT_BINARY_DIR}/lib${PLAYDATE_GAME_NAME}.dll
${CMAKE_CURRENT_SOURCE_DIR}/Source/pdex.dll)
then people can run a msys2 prompt with mingw32 (64 bit version) and run
cmake .. -G "MSYS Makefiles"
to generate the make file and then
make
to compile the pdex.dll etc
this dll loads fine in the simulator when i tested it.
i think this setup might be easier to setup for compiling C programs with visual studio code if people already have that installed as you can load a msys prompt inside visual studio code. Its how i usually compile windows program's using gcc (mingw) toolchains in windows
I did not test it but theoretically it might allow for debugging using gdb debugger inside visual studio code as well