我在使用C ++语言的Visual Studio 2013中的项目中使用DCMTK 3.6.1库。我的代码在Debug模式下可以正常运行,但在Release模式下则不能。当我尝试编译它时,我有275个错误,如下所示:
dcmdata.lib(dcdatset.obj):错误LNK2038:检测到不匹配
'_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in testapp_new.obj
2>dcmdata.lib(dcdatset.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MDd_DynamicDebug' doesn't match value 'MD_DynamicRelease' in testapp_new.obj
2>dcmdata.lib(dcfilefo.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in testapp_new.obj
2>dcmdata.lib(dcfilefo.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MDd_DynamicDebug' doesn't match value 'MD_DynamicRelease' in testapp_new.obj
2>dcmdata.lib(dcxfer.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in testapp_new.obj
2>dcmdata.lib(dcxfer.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MDd_DynamicDebug' doesn't match value 'MD_DynamicRelease' in testapp_new.obj
2>dcmdata.lib(dctagkey.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in testapp_new.obj
2>dcmdata.lib(dctagkey.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MDd_DynamicDebug' doesn't match value 'MD_DynamicRelease' in testapp_new.obj
2>dcmdata.lib(dctag.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in testapp_new.obj
2>dcmdata.lib(dctag.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MDd_DynamicDebug' doesn't match value 'MD_DynamicRelease' in testapp_new.obj
2>dcmdata.lib(dcstack.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0' in testapp_new.obj
我尝试了很多在网络上找到的解决方案,但是没有任何效果...
如果我尝试在发布模式下编译DCMTL库,则会出现以下错误:
Error 4 error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MD_DynamicRelease' in dcmdjpls.obj C:\dcmtk-bin_2\dcmjpls\apps\charls.lib(intrface.obj)
Error 5 error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MD_DynamicRelease' in dcmdjpls.obj C:\dcmtk-bin_2\dcmjpls\apps\charls.lib(header.obj)
Error 6 error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MD_DynamicRelease' in dcmdjpls.obj C:\dcmtk-bin_2\dcmjpls\apps\charls.lib(jpegls.obj)
Error 7 error LNK2005: __invoke_watson already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(invarg.obj)
Error 8 error LNK2005: ___crtSetUnhandledExceptionFilter already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(winapisupp.obj)
Error 9 error LNK2005: ___crtTerminateProcess already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(winapisupp.obj)
Error 10 error LNK2005: ___crtUnhandledException already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(winapisupp.obj)
Error 11 error LNK2005: ___iob_func already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(_file.obj)
Error 12 error LNK2005: __lock_file already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(_file.obj)
Error 13 error LNK2005: __unlock_file already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(_file.obj)
Error 14 error LNK2005: _fflush already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(fflush.obj)
Error 15 error LNK2005: __amsg_exit already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0dat.obj)
Error 16 error LNK2005: __cexit already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0dat.obj)
Error 17 error LNK2005: __exit already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0dat.obj)
Error 18 error LNK2005: __initterm_e already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0dat.obj)
Error 19 error LNK2005: _exit already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0dat.obj)
Error 20 error LNK2005: __errno already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(dosmap.obj)
Error 21 error LNK2005: __calloc_crt already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crtheap.obj)
Error 22 error LNK2005: "void __cdecl terminate(void)" (?terminate@@YAXXZ) already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(hooks.obj)
Error 23 error LNK2005: ___xi_a already defined in MSVCRT.lib(cinitexe.obj) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0init.obj)
Error 24 error LNK2005: ___xi_z already defined in MSVCRT.lib(cinitexe.obj) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0init.obj)
Error 25 error LNK2005: ___xc_a already defined in MSVCRT.lib(cinitexe.obj) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0init.obj)
Error 26 error LNK2005: ___xc_z already defined in MSVCRT.lib(cinitexe.obj) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0init.obj)
Error 27 error LNK2005: __get_osfhandle already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(osfinfo.obj)
Error 28 error LNK2005: ___set_app_type already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(errmode.obj)
Error 29 error LNK2005: __XcptFilter already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(winxfltr.obj)
Error 30 error LNK2005: __lock already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(mlock.obj)
Error 31 error LNK2005: __unlock already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(mlock.obj)
Error 32 error LNK2005: __configthreadlocale already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(wsetloca.obj)
Error 33 error LNK2005: __fileno already defined in LIBCMT.lib(fileno.obj) C:\dcmtk-bin_2\dcmjpls\apps\MSVCRT.lib(MSVCR120.dll)
Warning 34 warning LNK4098: defaultlib 'MSVCRT' conflicts with use of other libs; use /NODEFAULTLIB:library C:\dcmtk-bin_2\dcmjpls\apps\LINK
Warning 35 warning LNK4098: defaultlib 'LIBCMT' conflicts with use of other libs; use /NODEFAULTLIB:library C:\dcmtk-bin_2\dcmjpls\apps\LINK
Error 36 error LNK1169: one or more multiply defined symbols found C:\dcmtk-bin_2\bin\Release\dcmdjpls.exe
Error 37 error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MD_DynamicRelease' in dcml2pnm.obj C:\dcmtk-bin_2\dcmjpls\apps\charls.lib(intrface.obj)
Error 38 error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MD_DynamicRelease' in dcml2pnm.obj C:\dcmtk-bin_2\dcmjpls\apps\charls.lib(header.obj)
Error 39 error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MD_DynamicRelease' in dcml2pnm.obj C:\dcmtk-bin_2\dcmjpls\apps\charls.lib(jpegls.obj)
Error 40 error LNK2005: __invoke_watson already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(invarg.obj)
Error 41 error LNK2005: ___crtSetUnhandledExceptionFilter already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(winapisupp.obj)
Error 42 error LNK2005: ___crtTerminateProcess already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(winapisupp.obj)
Error 43 error LNK2005: ___crtUnhandledException already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(winapisupp.obj)
Error 44 error LNK2005: ___iob_func already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(_file.obj)
Error 45 error LNK2005: __lock_file already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(_file.obj)
Error 46 error LNK2005: __unlock_file already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(_file.obj)
Error 47 error LNK2005: _fflush already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(fflush.obj)
Error 48 error LNK2005: __amsg_exit already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0dat.obj)
Error 49 error LNK2005: __cexit already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0dat.obj)
Error 50 error LNK2005: __exit already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0dat.obj)
Error 51 error LNK2005: __initterm_e already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0dat.obj)
Error 52 error LNK2005: _exit already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0dat.obj)
Error 53 error LNK2005: __errno already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(dosmap.obj)
Error 54 error LNK2005: __calloc_crt already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crtheap.obj)
Error 55 error LNK2005: "void __cdecl terminate(void)" (?terminate@@YAXXZ) already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(hooks.obj)
Error 56 error LNK2005: ___xi_a already defined in MSVCRT.lib(cinitexe.obj) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0init.obj)
Error 57 error LNK2005: ___xi_z already defined in MSVCRT.lib(cinitexe.obj) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0init.obj)
Error 58 error LNK2005: ___xc_a already defined in MSVCRT.lib(cinitexe.obj) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0init.obj)
Error 59 error LNK2005: ___xc_z already defined in MSVCRT.lib(cinitexe.obj) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0init.obj)
Error 60 error LNK2005: __get_osfhandle already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(osfinfo.obj)
Error 61 error LNK2005: ___set_app_type already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(errmode.obj)
Error 62 error LNK2005: __XcptFilter already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(winxfltr.obj)
Error 63 error LNK2005: __lock already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(mlock.obj)
Error 64 error LNK2005: __unlock already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(mlock.obj)
Error 65 error LNK2005: __configthreadlocale already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(wsetloca.obj)
Error 66 error LNK2005: __fileno already defined in LIBCMT.lib(fileno.obj) C:\dcmtk-bin_2\dcmjpls\apps\MSVCRT.lib(MSVCR120.dll)
Warning 67 warning LNK4098: defaultlib 'MSVCRT' conflicts with use of other libs; use /NODEFAULTLIB:library C:\dcmtk-bin_2\dcmjpls\apps\LINK
Warning 68 warning LNK4098: defaultlib 'LIBCMT' conflicts with use of other libs; use /NODEFAULTLIB:library C:\dcmtk-bin_2\dcmjpls\apps\LINK
Error 69 error LNK1169: one or more multiply defined symbols found C:\dcmtk-bin_2\bin\Release\dcml2pnm.exe
Error 70 error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MD_DynamicRelease' in dcmcjpls.obj C:\dcmtk-bin_2\dcmjpls\apps\charls.lib(intrface.obj)
Error 71 error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MD_DynamicRelease' in dcmcjpls.obj C:\dcmtk-bin_2\dcmjpls\apps\charls.lib(header.obj)
Error 72 error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MD_DynamicRelease' in dcmcjpls.obj C:\dcmtk-bin_2\dcmjpls\apps\charls.lib(jpegls.obj)
Error 73 error LNK2005: __invoke_watson already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(invarg.obj)
Error 74 error LNK2005: ___crtSetUnhandledExceptionFilter already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(winapisupp.obj)
Error 75 error LNK2005: ___crtTerminateProcess already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(winapisupp.obj)
Error 76 error LNK2005: ___crtUnhandledException already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(winapisupp.obj)
Error 77 error LNK2005: ___iob_func already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(_file.obj)
Error 78 error LNK2005: __lock_file already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(_file.obj)
Error 79 error LNK2005: __unlock_file already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(_file.obj)
Error 80 error LNK2005: _fflush already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(fflush.obj)
Error 81 error LNK2005: __amsg_exit already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0dat.obj)
Error 82 error LNK2005: __cexit already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0dat.obj)
Error 83 error LNK2005: __exit already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0dat.obj)
Error 84 error LNK2005: __initterm_e already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0dat.obj)
Error 85 error LNK2005: _exit already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0dat.obj)
Error 86 error LNK2005: __errno already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(dosmap.obj)
Error 87 error LNK2005: __calloc_crt already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crtheap.obj)
Error 88 error LNK2005: "void __cdecl terminate(void)" (?terminate@@YAXXZ) already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(hooks.obj)
Error 89 error LNK2005: ___xi_a already defined in MSVCRT.lib(cinitexe.obj) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0init.obj)
Error 90 error LNK2005: ___xi_z already defined in MSVCRT.lib(cinitexe.obj) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0init.obj)
Error 91 error LNK2005: ___xc_a already defined in MSVCRT.lib(cinitexe.obj) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0init.obj)
Error 92 error LNK2005: ___xc_z already defined in MSVCRT.lib(cinitexe.obj) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(crt0init.obj)
Error 93 error LNK2005: __get_osfhandle already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(osfinfo.obj)
Error 94 error LNK2005: ___set_app_type already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(errmode.obj)
Error 95 error LNK2005: __XcptFilter already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(winxfltr.obj)
Error 96 error LNK2005: __lock already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(mlock.obj)
Error 97 error LNK2005: __unlock already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(mlock.obj)
Error 98 error LNK2005: __configthreadlocale already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmjpls\apps\LIBCMT.lib(wsetloca.obj)
Error 99 error LNK2005: __fileno already defined in LIBCMT.lib(fileno.obj) C:\dcmtk-bin_2\dcmjpls\apps\MSVCRT.lib(MSVCR120.dll)
Warning 100 warning LNK4098: defaultlib 'MSVCRT' conflicts with use of other libs; use /NODEFAULTLIB:library C:\dcmtk-bin_2\dcmjpls\apps\LINK
Warning 101 warning LNK4098: defaultlib 'LIBCMT' conflicts with use of other libs; use /NODEFAULTLIB:library C:\dcmtk-bin_2\dcmjpls\apps\LINK
Error 102 error LNK1169: one or more multiply defined symbols found C:\dcmtk-bin_2\bin\Release\dcmcjpls.exe
Error 103 error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MD_DynamicRelease' in dcmsend.obj C:\dcmtk-bin_2\dcmnet\apps\charls.lib(intrface.obj)
Error 104 error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MD_DynamicRelease' in dcmsend.obj C:\dcmtk-bin_2\dcmnet\apps\charls.lib(header.obj)
Error 105 error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MD_DynamicRelease' in dcmsend.obj C:\dcmtk-bin_2\dcmnet\apps\charls.lib(jpegls.obj)
Error 106 error LNK2005: __invoke_watson already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(invarg.obj)
Error 107 error LNK2005: ___crtSetUnhandledExceptionFilter already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(winapisupp.obj)
Error 108 error LNK2005: ___crtTerminateProcess already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(winapisupp.obj)
Error 109 error LNK2005: ___crtUnhandledException already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(winapisupp.obj)
Error 110 error LNK2005: ___iob_func already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(_file.obj)
Error 111 error LNK2005: __lock_file already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(_file.obj)
Error 112 error LNK2005: __unlock_file already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(_file.obj)
Error 113 error LNK2005: _fflush already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(fflush.obj)
Error 114 error LNK2005: __amsg_exit already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(crt0dat.obj)
Error 115 error LNK2005: __cexit already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(crt0dat.obj)
Error 116 error LNK2005: __exit already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(crt0dat.obj)
Error 117 error LNK2005: __initterm_e already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(crt0dat.obj)
Error 118 error LNK2005: _exit already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(crt0dat.obj)
Error 119 error LNK2005: __errno already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(dosmap.obj)
Error 120 error LNK2005: __calloc_crt already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(crtheap.obj)
Error 121 error LNK2005: "void __cdecl terminate(void)" (?terminate@@YAXXZ) already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(hooks.obj)
Error 122 error LNK2005: ___xi_a already defined in MSVCRT.lib(cinitexe.obj) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(crt0init.obj)
Error 123 error LNK2005: ___xi_z already defined in MSVCRT.lib(cinitexe.obj) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(crt0init.obj)
Error 124 error LNK2005: ___xc_a already defined in MSVCRT.lib(cinitexe.obj) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(crt0init.obj)
Error 125 error LNK2005: ___xc_z already defined in MSVCRT.lib(cinitexe.obj) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(crt0init.obj)
Error 126 error LNK2005: __get_osfhandle already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(osfinfo.obj)
Error 127 error LNK2005: ___set_app_type already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(errmode.obj)
Error 128 error LNK2005: __XcptFilter already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(winxfltr.obj)
Error 129 error LNK2005: __lock already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(mlock.obj)
Error 130 error LNK2005: __unlock already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(mlock.obj)
Error 131 error LNK2005: __configthreadlocale already defined in MSVCRT.lib(MSVCR120.dll) C:\dcmtk-bin_2\dcmnet\apps\LIBCMT.lib(wsetloca.obj)
Error 132 error LNK2005: __fileno already defined in LIBCMT.lib(fileno.obj) C:\dcmtk-bin_2\dcmnet\apps\MSVCRT.lib(MSVCR120.dll)
你知道如何解决这个问题吗?
最佳答案
根据DCMTK官方论坛中的建议,我重新编译了DCMTK库,并禁用了DCMTK_OVERWRITE_WIN32_COMPILER_FLAGS标志,现在我可以在Debug / Release模式下进行编译,因此可以正常工作!
我需要在调试模式下安装库,然后在发布模式下安装
无论如何,我将对此进行更多调查。