I installed Cygwin on my windows computer yesterday, and compiled & ran a socket-based C code, which is programmed for Linux. Before compiling(GCC) and running a Linux-environment code on windows, I installed all the packages in the 'Devel' category. I didn't install anything else, and it worked fine.
But now that I have completed my program, I want to share it. But I don't want my users to hassle installing Cygwin on windows for hours. The users will not compile the program, they'll just run it. So what are the only required packages to run a Linux-environment program with Cygwin? Or do I even need to install any package to run a Linux-environment program, if I am not going to compile it?
If you don't want the hassle of Cygwin and it's compatibility layers, you should consider building for native Windows with MinGW-w64.
In Windows you can get a standalone MinGW-w64 from https://winlibs.com/ or via MSYS2 using its pacman
package manager.
But you can also cross-compile for Windows on Linux using the MinGW-w64 that you can install via your Linux distribution's package manager.