Defining Macro depending on Build Profile

Hello,
I want to define macros during compile time depending on Build Profile. For example I select debug as build mode it should define macro as debug. How to achieve this. What changes should be done in mbed_app.json.