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.

CCS/LAUNCHXL-CC26X2R1: CCS Release build vs Debug Build

Part Number: LAUNCHXL-CC26X2R1

Tool/software: Code Composer Studio

When I try to build my release version I get these errors:

Description Resource Path Location Type
Failed linktime optimization null: Failed linktime optimization ble5_project_zero_cc26x2r1lp_app C/C++ Problem
gmake: *** [all] Error 2 ble5_project_zero_cc26x2r1lp_app C/C++ Problem
gmake[1]: *** [ble5_project_zero_cc26x2r1lp_app_FlashROM_Release.out] Error 1 ble5_project_zero_cc26x2r1lp_app C/C++ Problem
symbol "ToggleVent_createChangeVentTask" redeclared with incompatible null: symbol "ToggleVent_createChangeVentTask" redeclared with incompatible ble5_project_zero_cc26x2r1lp_app C/C++ Problem

I've looked in the build settings and verified as much as I know how that they are the same.  I'm not sure why it builds fine in debug but won't build in release.

  • Are you building the FlashROM_Release build configuration of the unmodified example ble5_project_zero_cc26x2r1lp_app project? Or has the project been modified in some way?

    I just built the example project with CCS 8.2 and did not get any errors.To establish a baseline again, re-import the example into a new workspace, build the Release config and let us know if the error persists.

  • It is modified. I added a new device that  changes a servo’s position. How do I reload the original code without overwriting my changes?  I know it is a simple question but I know you can introduce errors by changing the name of a project. Is there a clear instruction on how to do that??  

    Thanks.

  • If it is modified then it is quite possible that the code you added is somehow causing a linktime optimization error. If that is the case we would need to reproduce the error to investigate the reason for error. The Release config, by default, is set to compile at -o4. If you are willing to live with a slightly lower optimization, try building with -o3 or -o2 and see if that is successful. The optimization setting is under Project Properties->Build->Compiler->Optimization.

    Travis Baker said:
     I know it is a simple question but I know you can introduce errors by changing the name of a project.

    Renaming a project can sometimes get tricky. Hence I would say it is safe and probably quickest to open the original example in a new workspace and keep both workspaces open side by side to compare. However, since I have verified that the original example builds fine and you confirmed that your code is modified, I would focus on getting your modified project to build. Let us know if building with lower optimization helps.

  • Thanks so much for the amazing support.  I will try this later today.  It is for a science project so I am sure the optimization issue will be fine.  I will respond by tomorrow to indicate if this works.

    Again, thank you for your patience and providing good help. 

    Travis

  • This resolved the compiling issue. However, I am still learning and the reason I was trying to load the release version is so that it would run without the computer. When I cycle the power, the program doesn't run again. I can't see the project zero on my app.
  • Glad to hear the compiling issue is resolved.

    As for running on power up I don't believe that is what differentiates the Release build from the Debug build. However, the experts in the device forum will be able to clarify that further and guide you to what needs to be done to run the code standalone. I would suggest posting that question to the Bluetooth forum. And since the original question with the build error is resolved, we will close this thread.