Visual Studio 2022 static linking resulting in error LNK2019
I’ve been trying to use the GameNetworkingSockets library by valve. I followed the building steps on their github page: https://github.com/ValveSoftware/GameNetworkingSockets/blob/master/BUILDING.md. Instead of using ninja for building I used Visual Studio 2022 so the command looked like this: cmake -G "Visual Studio 17 2022" -A x64
. This created a .sln file which i opened and then built the project(s). Projects in Solution file. I built the “ALL_BUILD” project in Debug x64 configuration which resulted in these files being created: Created Files. I assumed the GameNetworkingSockets_s.lib is the static library so I copied it into a folder in my projects directory which i added to the linkers library directories in my projects properties. Running following code: