I am using C++ on VS 2019. I created a C++ project library for auxiliary math functions and I was trying to test my code using the provided unit test tools for c++ inside. I just started and immediately I got blocked.
Platform:VS2019 (v142).
Configuration type: Dynamic Library .dll
Windows SDK Version: 10.0
Common Language Runtime Support: Common Language RunTime Support (/clr)
Compiler command line:
/Yu"pch.h" /GS /TP /analyze- /W3 /Zc:wchar_t /I"C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\UnitTest\include" /Od /sdl /Fd"Debug\vc142.pdb" /Zc:inline /fp:precise /D "WIN32" /D "_DEBUG" /errorReport:prompt /WX- /Zc:forScope /Gd /Oy- /clr /FU"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0\mscorlib.dll" /MDd /FC /Fa"Debug\" /nologo /Fo"Debug\" /Fp"Debug\UTCommFunctions.pch" /diagnostics:column
Linker command line:
/OUT:"C:\Users\fguido\Source\Repos\SSABL2NewModels\SSABL2NewModels\Debug\UTCommFunctions.dll" /MANIFEST /NXCOMPAT /PDB:"C:\Users\fguido\Source\Repos\SSABL2NewModels\SSABL2NewModels\Debug\UTCommFunctions.pdb" /DYNAMICBASE "kernel32.lib" "user32.lib" "gdi32.lib" "winspool.lib" "comdlg32.lib" "advapi32.lib" "shell32.lib" "ole32.lib" "oleaut32.lib" "uuid.lib" "odbc32.lib" "odbccp32.lib" /FIXED:NO /DLL /MACHINE:X86 /INCREMENTAL:NO /PGD:"C:\Users\fguido\Source\Repos\SSABL2NewModels\SSABL2NewModels\Debug\UTCommFunctions.pgd" /SUBSYSTEM:WINDOWS /MANIFESTUAC:"level='asInvoker' uiAccess='false'" /ManifestFile:"Debug\UTCommFunctions.dll.intermediate.manifest" /ERRORREPORT:PROMPT /NOLOGO /LIBPATH:"C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\UnitTest\lib" /ASSEMBLYDEBUG /TLBID:1
I get these errors and I am stuck. I am quite new to the UT
Severity Code Description Project File Line Suppression State
Error LNK1120 3 unresolved externals UTCommFunctions C:\Users\fguido\Source\Repos\SSABL2NewModels\SSABL2NewModels\Debug\UTCommFunctions.dll 1
Error LNK2020 unresolved token (06000001) CCommMath::.ctor UTCommFunctions C:\Users\fguido\Source\Repos\SSABL2NewModels\SSABL2NewModels\UTCommFunctions\UTCommFunctions.obj 1
Error LNK2020 unresolved token (06000002) CCommMath::Interpolation UTCommFunctions C:\Users\fguido\Source\Repos\SSABL2NewModels\SSABL2NewModels\UTCommFunctions\UTCommFunctions.obj 1
Error LNK2020 unresolved token (06000003) CCommMath::Sum UTCommFunctions C:\Users\fguido\Source\Repos\SSABL2NewModels\SSABL2NewModels\UTCommFunctions\UTCommFunctions.obj 1