PhysX icon indicating copy to clipboard operation
PhysX copied to clipboard

Exactly one of NDEBUG and _DEBUG needs to be defined! [new to C++][Implementing SDK into project]

Open MrMechanical opened this issue 4 years ago • 3 comments

I'm not sure if this is the right place to post this. I am struggling with this error in my custom C++ game engine's implementation's of Physx4.1 SDK. Do I Just define NDEBUG or am I doing something wrong? I apologize for my inexperience, I am very much a beginner when it comes to implementing libraries.

Thank you so much for the help, I am extremely grateful.

MrMechanical avatar May 25 '20 20:05 MrMechanical

Check your configuration pre-processor defines, there should be just one of the defines. In your project where you include physx headers, you should have one of those defines.

AlesBorovicka avatar May 26 '20 07:05 AlesBorovicka

If you are using CMake try explicitly declaring your build type, like: cmake .. -DCMAKE_BUILD_TYPE=Debug "-GUnix Makefiles"

Woking-34 avatar May 28 '20 14:05 Woking-34

I had to add it to the Preprocessor Definitions in Visual Studio when in Release Mode. There may be a better way, but I could not find any other half-decent solution. asdf

mattearly avatar Sep 06 '21 19:09 mattearly