Skip to main content
Explorer
December 4, 2020
Solved

CubeMX keeps adding non existent folders to build path

  • December 4, 2020
  • 2 replies
  • 1160 views

I originaly added the CubeMX NFC firmware module and made a few builds with that library.

Then I removed the NFC component and now every time I generate the code the folders lib_nfc\Target and lib_nfc are added to project resulting in a few warning.

I have to manualy remove the paths from build settings, but every code generation they are added again.

Someone can indicate me where I can switch off this behavior?

    This topic has been closed for replies.
    Best answer by MFerr.4

    Thank you for the answer.

    I already did some investigationbefore resorting to the forum, and unfortunately there is no mention of lib_nfc in .ioc file.

    In .cproject file there is the path actually added back during code generation.

    Non mention of lib_nfc in the registry too.

    But your suggestion made me try another more aggressive approach:

    I ran a "grep -r lib_nfc *.*" in the root folder of the project ...

    I found a mention of lib_nfc deep inside a .metadata binary file that I couldn't change.

    But also an additional reference of the lib_nfc inside the .cproject file in an obscure entry:

    <option id="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.defaults.1897218958" ...

    far to the right and several screens off side, intermixed with other (legitimate?) project folders.

    Manually removing those entries fixed the problem.

    Thank you.

    2 replies

    Super User
    December 4, 2020

    Either CubeMX is in a weird/buggy state due to you adding and then removing a component, or you're missing something within the configuration. If you can share the IOC, someone may take a look. You make be able to open the IOC itself in a text editor and see/fix the issue.

    MFerr.4AuthorAnswer
    Explorer
    December 14, 2020

    Thank you for the answer.

    I already did some investigationbefore resorting to the forum, and unfortunately there is no mention of lib_nfc in .ioc file.

    In .cproject file there is the path actually added back during code generation.

    Non mention of lib_nfc in the registry too.

    But your suggestion made me try another more aggressive approach:

    I ran a "grep -r lib_nfc *.*" in the root folder of the project ...

    I found a mention of lib_nfc deep inside a .metadata binary file that I couldn't change.

    But also an additional reference of the lib_nfc inside the .cproject file in an obscure entry:

    <option id="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.defaults.1897218958" ...

    far to the right and several screens off side, intermixed with other (legitimate?) project folders.

    Manually removing those entries fixed the problem.

    Thank you.