@jgmills Your problem is that you are importing some Pylon headers in the wrong order/missing some include.
Basler suggest importing first the #include <pylon/PylonIncludes.h> and after all the others needed in your headers file.
Checking the latter include you can find a comment:
// PylonPlatform.h must be included before including any GenICam/GenApi header files,
// to ensure that the GENICAM_COMPILER_STR macro used by GenICam/GenApi is set properly
#include <pylon/Platform.h>
#include <pylon/PylonLinkage.h>
That macro next enables the definition of GENICAM_USER_ALWAYS_LINK_RELEASE. This definition tells the compiler to link the library with the MD specification also in debug mode.
Concluding, to be able to work in debug mode you can choose between:
In your headers that need some pylon include, add as first the #include <pylon/PylonIncludes.h>
If you want to avoid all the inclusion made by the latter, in your headers that need some pylon include, add as first the #include <pylon/Platform.h> and the #include <pylon/PylonLinkage.h>