I’ve used setup.py to set environment variables. They are correct, because I can use build_native.py from terminal and build the project just fine. If I then immediately run it in Eclipse, it transfers and runs on my device as expected.
However, if I try to build from within Eclipse after making a change, I get this error:
python /Users/lindsay/Cocos/TutorialV3CPP/proj.android/build_native.py all NDK_ROOT not defined. Please define NDK_ROOT in your environment
Is this something I can fix, or do I always have to build from the command line?
Because NDK_ROOT is set in ~/.bash_profile or something else, this mean that it will take effect in terminal. But Eclipse doesn’t setup a terminal, so it doesn’t take effect.
So may be you should define the variable in Eclipse itself to if you want to use Eclipse to build cpp codes.
How do you do that? I’ve recently installed cocos2dx 3.3 and Eclipse Juno on my Yosemite. and it says NDK_ROOT not defined. Need to setup environemt variables