Allright this one is remarkably hard to reproduce and also happening that often that it is being a real pain to deal with and needs solving, yet I can offer no fool proof repro steps, but generally the issue shows when you switch back and forth debug and release modes in visual studio (aka getting actual work done).
In a multi target cmake generator (problem found on VS, but i suspect XCode may run into this as well)
The debug and release mode share the generated code files in the bf_rna project.
Now sometimes, and I'm unsure what triggers this you end up with RNA code generated in debug mode being compiled and linked in release mode
and you end up with this build error:
------ Build started: Project: bf_rna, Configuration: Release x64 ------ rna_object_gen.c K:\BlenderGit\build_windows_Release_x64_vc16_Release\source\blender\makesrna\intern\rna_object_gen.c(3501,25): error C4013: 'rna_Object_me_eval_info' undefined; assuming extern returning int K:\BlenderGit\build_windows_Release_x64_vc16_Release\source\blender\makesrna\intern\rna_object_gen.c(3608,6): error C2371: 'rna_Object_me_eval_info': redefinition; different basic types Done building project "bf_rna.vcxproj" -- FAILED.
Force rebuilding makesrna fixes it, but for less experienced (or even experienced) developers this solution is not entirely obvious.
This root cause is
- rna_Object_me_eval_info being defined only in debug mode with an #ifndef NDEBUG guard.
- some code gets generated in debug mode that references it
- in release mode this function is omitted, but the code that uses it is still there.
This patch 'fixes' the issue by supplying an empty stub for release mode.
wish I had a better fix or repro case but this sadly will have to do, since it is still better than what we have now.