Fix for Visual Studio compile and link error