Probably CRT Hell with lcms
Posted: 2009-01-29T14:53:24-07:00
Hi,
I am using visual studio 2005 on a winxp machine.
Using make files through the visual studio 2005 command prompt. I have compiled libjpeg, zlib and libtiff. Now I am trying to compile little cms, but failing miserably.
I get the following linker errors:
2>Linking...
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: _strncmp already defined in LIBCMT.lib(strncmp.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: _malloc already defined in LIBCMT.lib(malloc.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: _free already defined in LIBCMT.lib(free.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: _realloc already defined in LIBCMT.lib(realloc.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: _vfprintf already defined in LIBCMT.lib(vfprintf.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: _fprintf already defined in LIBCMT.lib(fprintf.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: ___iob_func already defined in LIBCMT.lib(_file.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: _sprintf already defined in LIBCMT.lib(sprintf.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: __read already defined in LIBCMT.lib(read.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: __write already defined in LIBCMT.lib(write.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: __lseek already defined in LIBCMT.lib(lseek.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: __close already defined in LIBCMT.lib(close.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: __open already defined in LIBCMT.lib(open.obj)
2>LINK : warning LNK4098: defaultlib 'MSVCRT' conflicts with use of other libs; use /NODEFAULTLIB:library
2>LINK : warning LNK4098: defaultlib 'LIBCMTD' conflicts with use of other libs; use /NODEFAULTLIB:library
2>..\..\bin\tifficc.exe : fatal error LNK1169: one or more multiply defined symbols found
2>Build log was saved at "file://c:\lib\lcms-1.17\lcms-1.17\Projects\VC2005\tifficcDebug\BuildLog.htm"
From what I have googled its likely a crt issue, but I have no idea how to proceed or what to attempt to remedy the issue.
Any guidance or advice will be appreciated!
j_galan
I am using visual studio 2005 on a winxp machine.
Using make files through the visual studio 2005 command prompt. I have compiled libjpeg, zlib and libtiff. Now I am trying to compile little cms, but failing miserably.
I get the following linker errors:
2>Linking...
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: _strncmp already defined in LIBCMT.lib(strncmp.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: _malloc already defined in LIBCMT.lib(malloc.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: _free already defined in LIBCMT.lib(free.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: _realloc already defined in LIBCMT.lib(realloc.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: _vfprintf already defined in LIBCMT.lib(vfprintf.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: _fprintf already defined in LIBCMT.lib(fprintf.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: ___iob_func already defined in LIBCMT.lib(_file.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: _sprintf already defined in LIBCMT.lib(sprintf.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: __read already defined in LIBCMT.lib(read.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: __write already defined in LIBCMT.lib(write.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: __lseek already defined in LIBCMT.lib(lseek.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: __close already defined in LIBCMT.lib(close.obj)
2>MSVCRT.lib(MSVCR80.dll) : error LNK2005: __open already defined in LIBCMT.lib(open.obj)
2>LINK : warning LNK4098: defaultlib 'MSVCRT' conflicts with use of other libs; use /NODEFAULTLIB:library
2>LINK : warning LNK4098: defaultlib 'LIBCMTD' conflicts with use of other libs; use /NODEFAULTLIB:library
2>..\..\bin\tifficc.exe : fatal error LNK1169: one or more multiply defined symbols found
2>Build log was saved at "file://c:\lib\lcms-1.17\lcms-1.17\Projects\VC2005\tifficcDebug\BuildLog.htm"
From what I have googled its likely a crt issue, but I have no idea how to proceed or what to attempt to remedy the issue.
Any guidance or advice will be appreciated!
j_galan