My goal is to avoid the installation of Microsoft C++ 2010 by statically link it. Because I don’t know if that package will be installed on all the customer computers and his IT department doesn’t allow the installation of software.
One other alternative would be to avoid the use of administrative privilege. (extract dll in the same directory that my program for example)
I found one possible solution http://social.msdn.microsoft.com/Forums/en-US/vclanguage/thread/ab187afb-3af0-44ba-a03c-dde9e5208a1a/ and I tryied the parameter /MT.
I’ve 2 errors :
Erreur 1 error LNK2019: symbole externe non rÚsolu __CrtDbgReportW
rÚfÚrencÚ dans la fonction “void __cdecl std::_Debug_message(wchar_t
const *,wchar_t const *,unsigned int)”
(?_Debug_message@std@@YAXPB_W0I@Z) C:\Users\philippe\Downloads\Portable
Devices COM API Sample\C++\libcpmtd.lib(stdthrow.obj) WpdApiSampleErreur 2 error LNK1120: 1 externes non
rÚsolus C:\Users\philippe\Downloads\Portable Devices COM API
Sample\C++\Debug\WpdApiSample.exe 1 1 WpdApiSample
Am I in the good way ? And how can I resolve that problem ?
The documentation of
_CrtDbgReportWat the “requirement” section says:It means that such function are not present in the release version of the libraries, hence, the release version of your code should not call them.
According to this table may be you shold use
/MTdso that you will link to the static debug version.