ucrt64: get_lanserver_announcement(): readfs used uninitialized
Reply To cazfi
In file included from C:/freeciv/msys2/prod/msys2-freeciv-win64-220611/mingw64/include/winsock2.h:56
Likely the problem is in that "/mingw64/". And likely that somehow comes from the fact that our msys2 Makefile (and the win_arch.sh it uses) understands only two different systems; win32 and win64.
Reply To cazfi
Likely the problem is in that "/mingw64/". And likely that somehow comes from the fact that our msys2 Makefile (and the win_arch.sh it uses) understands only two different systems; win32 and win64.
That was the problem, and that's what the attached patch fixes (gets rid of win_arch.sh completely, and uses MSYSTEM instead)
I did first test to build using ucrt64 toolchain of msys2.
In file included from C:/freeciv/msys2/prod/msys2-freeciv-win64-220611/mingw64/include/winsock2.h:56,
from ../../../../server/sernet.c:18:
C:/freeciv/msys2/prod/msys2-freeciv-win64-220611/mingw64/include/psdk_inc/_fd_types.h: In function 'get_lanserver_announcement':
C:/freeciv/msys2/prod/msys2-freeciv-win64-220611/mingw64/include/psdk_inc/_fd_types.h:77:48: error: 'readfs' may be used uninitialized [-Werror=maybe-uninitialized!]
../../../../server/sernet.c:1463:10: note: 'readfs' declared here
~