- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am creating a .exe for code that was created for DVF. Compiles fine and links using an external .lib file that I have referenced in the dependency parameter. I am getting 5 error and 1 warning message :
Error fatal error LNK1169: one or more multiply defined symbols found Debug\EXEMODEL1.exe
Error error LNK2005: _for_close already defined in libifcoremdd.lib(libifcoremdd.dll) libifcoremt.lib(for_close.obj)
Error error LNK2005: _for_emit_diagnostic already defined in libifcoremdd.lib(libifcoremdd.dll) libifcoremt.lib(for_diags_intel.obj)
Error error LNK2005: _for_open already defined in libifcoremdd.lib(libifcoremdd.dll) libifcoremt.lib(for_open.obj)
Error error LNK2005: _for_set_reentrancy already defined in libifcoremdd.lib(libifcoremdd.dll) libifcoremt.lib(for_reentrancy.obj)
Warning warning LNK4098: defaultlib 'LIBCMT' conflicts with use of other libs; use /NODEFAULTLIB:library LINK
I did try the warning suggestion, but it resulted in many missing references !
I've searched for libifcoremdd but can find no relevant articles.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Your library and your executable project were built with different settings for the run-time library to use. One was set to use the static, non-debug library (libifcoremt.lib), one was set to use the DLL debug library (libifcoremdd.lib). The ideal solution is to set the library project property "Fortran > Libraries > Disable default library search rules" to Yes, then rebuild it. This will then make the choice of library dependent on the executable project.
If you can't do that, then change the property Fortran > Libraries > Use Runtime Library to match that of the .LIB you are linking to. I recommend against using /NODEFAULTLIB as a solution here.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Your library and your executable project were built with different settings for the run-time library to use. One was set to use the static, non-debug library (libifcoremt.lib), one was set to use the DLL debug library (libifcoremdd.lib). The ideal solution is to set the library project property "Fortran > Libraries > Disable default library search rules" to Yes, then rebuild it. This will then make the choice of library dependent on the executable project.
If you can't do that, then change the property Fortran > Libraries > Use Runtime Library to match that of the .LIB you are linking to. I recommend against using /NODEFAULTLIB as a solution here.

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page