This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

PROCESSOR-SDK-J721S2: How to change Compile Mode from release to debug?

Part Number: PROCESSOR-SDK-J721S2

Deer Sir / Madam

    We want to debug it by XDS, so i want to change compile mode from RELEASE to DEBUG.

    Now we change some parmas in .mak, the output file path change from release/ to debug/. But it seems that the output file doesn't link the lib we put in lib/xxxx/debug. I find that there is a params NO_OPTIMIZE, if set NO_OPTIMIZE=1, the $(TARGET_BUILD) will = debug. So i want to know if i should set NO_OPTIMIZE=1 in somewhere, or compile it by "make sdk NO_OPTIMIZE=1" is okay?

    Looking forward to your reply, thanks alot,

    Lepus.

  • Hi Lepus,

    Can you please mention which SDK you are using and what command are you using to build?

    Regards,
    Parth

  • Hi Parth

    We are using J721S2 8.6. Building comman is `make sdk`. I have set the $(PRO_FILE) ?= debug. It will create the debug output path by itself, but the output files seem like not correct. As a test, I put an error lib in debug lib path, but there is no calling error in building, but it will call error when i put it in release lib path. The build lib path depends on $(TARGET_BUILD), the TARGET_BUILD should be set to 'debug'. And the TARGET_BUILD depends on $(NO_OPTIMIZE), as the picture i put under. 

    How can I set NO_OPTIMIZE=1? Should use building command like: `make sdk NO_OPTIMIZE=1`?

  • Hi, 

    The PROFILE = debug should set the TARGET_BUILD also to debug as per the TARGET_COMBOS created in the Makefile of TIOVX.

    As a test, I put an error lib in debug lib path, but there is no calling error in building, but it will call error when i put it in release lib path.

    Could you provide this step so that I could check this at my end?

    Regards,

    nikhil