LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL'

robagar
Posts: 48
Joined: Fri May 21, 2010 1:49 am

LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL'

Post by robagar »

Anyone know how to fix this linker error when compiling my project in VS2010? Apparently it's something to do with automatically disabling some run time checks on stl operations in release builds, but I'm getting it compiling a debug build & linking to debug bullet libs :( Release builds work fine.

Code: Select all

1>ReefClientLib_d.lib(btRigidBody.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in Main.obj
+ 52 more identical errors
robagar
Posts: 48
Joined: Fri May 21, 2010 1:49 am

Re: LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL'

Post by robagar »

it's ok, clean + full rebuild fixed it. yay!
Yadu
Posts: 1
Joined: Fri Feb 11, 2011 2:11 pm

Re: LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL'

Post by Yadu »

go to Build/Configuration Manager and make sure all the projects are built in the same configuration you're building the solution.
This happens if certain projects are built in unicode debug and the solution is built for unicode release or vice versa.
RaenirSalazar
Posts: 5
Joined: Fri Apr 25, 2014 4:22 pm

Re: LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL'

Post by RaenirSalazar »

I'm having this same problem but for relealse, the above advice to check configuration settings didn't reveal any issues.