Decision Optimization

Decision Optimization

Delivers prescriptive analytics capabilities and decision intelligence to improve decision-making.


#Analytics
#DecisionOptimization
#DecisionOptimization
 View Only
  • 1.  error lnk2038 and lnk2001 using msvs 2010

    Posted 01/10/13 09:30 PM

    Originally posted by: SystemAdmin


    I was trying to resolve a mip using Microsoft Visual Studio 2010 calling cplex 12.4.
    I had some issues with x86 and x64 compatibility (my cplex is x64), but somehow (SDK 7.1 and proyect configurations) I solved that.
    But now there is a bigger problem and there is no way for me to find a solution.

    There is the output of the solving. Thanks in advance.

    1>------ Operación Generar iniciada: proyecto: Prueba, configuración: Debug x64
    1> base.cpp
    1>C:\Program Files\IBM\ILOG\CPLEX_Studio124\concert\include\ilconcert/iloexpressioni.h(451): warning C4244: 'argument' : conversion from 'IloInt' to 'IloNum', possible loss of data
    1>C:\Program Files\IBM\ILOG\CPLEX_Studio124\cplex\include\ilcplex/ilocplexi.h(3024): warning C4244: 'initializing' : conversion from 'IloInt' to 'int', possible loss of data
    1>C:\Program Files\IBM\ILOG\CPLEX_Studio124\cplex\include\ilcplex/ilocplexi.h(3032): warning C4244: 'initializing' : conversion from 'IloInt' to 'int', possible loss of data
    1>C:\Program Files\IBM\ILOG\CPLEX_Studio124\cplex\include\ilcplex/ilocplexi.h(3037): warning C4244: 'initializing' : conversion from 'IloInt' to 'int', possible loss of data
    1>C:\Program Files\IBM\ILOG\CPLEX_Studio124\cplex\include\ilcplex/ilocplexi.h(3042): warning C4244: 'initializing' : conversion from 'IloInt' to 'int', possible loss of data
    1>C:\Program Files\IBM\ILOG\CPLEX_Studio124\cplex\include\ilcplex/ilocplexi.h(3109): warning C4244: 'argument' : conversion from 'IloInt' to 'CPXINT', possible loss of data
    1>C:\Program Files\IBM\ILOG\CPLEX_Studio124\cplex\include\ilcplex/ilocplexi.h(3907): warning C4244: 'return' : conversion from 'const IloBool' to 'int', possible loss of data
    1>ilocplex.lib(ilocplex.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(ilocplexreader.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(ilocpxcallback.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(ilocpxindexmanager.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(iloextrmgr.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(iloexpr.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(ilosvec.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(ilogoals.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(cpxcache.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(ilocolextr.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(ilodeflpextr.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(ilologicextr.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(ilocplexsolnpool.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(ilocpxsoln.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(ilosetextr.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(ilomipstart.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(ilomutex.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>ilocplex.lib(ilolpextr.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(iloalg.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(iloenv.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(iloextractable.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(iloexpression.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(iloconstraint.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilotypes.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(iloallocator.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(evalexpand.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(iloset.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(evaluator.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilosolution.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilohash.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilothread.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilorandom.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(iloiterator.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilosimplecollection.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(iloanyexpr.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilostimei.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilocollectioniterator.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilocollection.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilossol.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilocollectionstruct.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilomap.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilocollectionoperator.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilosdisplayi.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(iloskiplist.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilonumfunci.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(iloserror.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(evalkernel.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilosbasic.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(iloparami.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilosstructi.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilossequencei.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilosmodel.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilosatomi.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>concert.lib(ilointervalsi.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in base.obj
    1>LINK : warning LNK4098: defaultlib 'LIBCMT' conflicts with use of other libs; use /NODEFAULTLIB:library
    1>libcpmtd.lib(cout.obj) : error LNK2001: unresolved external symbol _free_dbg
    1>libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol _free_dbg
    1>base.obj : error LNK2019: unresolved external symbol _free_dbg referenced in function "private: void __cdecl std::_Yarn<char>::_Tidy(void)" (?_Tidy@?$_Yarn@D@std@@AEAAXXZ)
    1>libcpmtd.lib(cerr.obj) : error LNK2001: unresolved external symbol _free_dbg
    1>libcpmtd.lib(locale0.obj) : error LNK2001: unresolved external symbol _free_dbg
    1>libcpmtd.lib(xdebug.obj) : error LNK2001: unresolved external symbol _free_dbg
    1>libcpmtd.lib(cerr.obj) : error LNK2019: unresolved external symbol _CrtDbgReportW referenced in function "public: char const & __cdecl std::_String_const_iterator<char,struct std::char_traits<char>,class std::allocator<char> >::operator*(void)const " (??D?$_String_const_iterator@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEBAAEBDXZ)
    1>libcpmtd.lib(stdthrow.obj) : error LNK2001: unresolved external symbol _CrtDbgReportW
    1>libcpmtd.lib(cout.obj) : error LNK2001: unresolved external symbol _CrtDbgReportW
    1>libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol _CrtDbgReportW
    1>libcpmtd.lib(locale0.obj) : error LNK2019: unresolved external symbol _malloc_dbg referenced in function "public: class std::_Yarn<char> & __cdecl std::_Yarn<char>::operator=(char const *)" (??4?$_Yarn@D@std@@QEAAAEAV01@PEBD@Z)
    1>libcpmtd.lib(xdebug.obj) : error LNK2001: unresolved external symbol _malloc_dbg
    1>libcpmtd.lib(xmbtowc.obj) : error LNK2001: unresolved external symbol _malloc_dbg
    1>libcpmtd.lib(_tolower.obj) : error LNK2019: unresolved external symbol _calloc_dbg referenced in function _Getctype
    1>C:\Users\Pedro\Desktop\Prueba\Prueba\x64\Debug\Prueba.exe : fatal error LNK1120: 4 unresolved externals
    #CPLEXOptimizers
    #DecisionOptimization


  • 2.  Re: error lnk2038 and lnk2001 using msvs 2010

    Posted 01/11/13 01:14 AM

    Originally posted by: SystemAdmin


    Can you please check if the discussion in one of the following threads provides an answer to your question?
    CPLEX 12.2 MSVS2010 : LNK2038: mismatch detected for _ITERATOR_DEBUG_LEVEL
    Problem with Visual Studio 2010 and CPLEX 12.3 (Windows7 32bit)
    #CPLEXOptimizers
    #DecisionOptimization


  • 3.  Re: error lnk2038 and lnk2001 using msvs 2010

    Posted 10/15/15 01:30 PM

    Originally posted by: kingaj12


    I just solved this problem for MSVS 2010 by changing the Cplex library directories.

    Project->Properties->Linker->General->Additional Library Directories:

    C:\Program Files\IBM\ILOG\CPLEX_Studio1261\cplex\lib\x64_windows_vs2010\stat_mdd;C:\Program Files\IBM\ILOG\CPLEX_Studio1261\concert\lib\x64_windows_vs2010\stat_mdd;C:\Program Files\Microsoft SDKs\Windows\v7.1\Lib\x64

     


    #CPLEXOptimizers
    #DecisionOptimization