Toolchain manager issues: Cleaning the build files / moving code to another folder

I'm using NCS 1.9.1 and Segger SES

Following Nordic's recommendation I first made a copy of BLE/peripheral_uart in order to preserve the original code and then used the toolchain manager to open the project. I selected nrf52DK_52832 as target and so far, things are working not bad.

1.) when the code is properly built, the project folder contains approx 1600 files with 40 MB size - my actual code is less than 30 kB. It is not clear to me which files can easily be deleted because they are rebuilt - I tried once to delete "build_nrf52dk_nrf52832" which is a most stupid idea, because all my project settings regarding BLE GATT were gone.

"Clean Zephyr" or "clean solution" does not really help too much, still 37 MB and if even fails with
"...ncs/v1.9.1/nrf/samples/bluetooth/peripheral_uart/build_nrf52dk_nrf52832/zephyr/dev_handles.c does not exist."

I find it very strange that I'm not able to peroperly clean a project, get rid of temprorary files - and I found no documentation so far on the Nordic system.

2.) the other issue is the location of sources: it seems that the full path to all files goes somewhere into the build process, which means, I'm not able to rename my project folder or move it to another location / harddisk / server and build there.

Is there any strategy how to handle this ?

As example lets look at c:/ncs/v1.9.1/nrf/samples/bluetooth/peripheral_uart - this is the sample I'm referring to. What is necessary to move this to : f:\customerXYZ\BLE-development\product1

thanks, Matthias

Parents
  • I'm not talking about a copy of the whole NCS folder sub-structure, I'm referring to one single project. Also, I dont want to "create" a project - I already have a project, but I want to copy it to another destination on my harddisk.

    When I'm developing (other) code I very often have parallel project folders like "test-v1" and "test-v2" etc - which is sort of versioning system as long as I work with code. For Microsoft tools (eg VS/C++) or code which relies on GNU-makefiles the folder name and location doesn't matter, as long as the content and subdirs are ok I can put the folders wherever I like and it compiles without any trouble - this seems not to work with NCS. It appears to me as if the NCS folder structure forces me to store my project files in a particular place because of the stored paths.

    The whole NCS build process only seems to work when I start SES via "nRF connect for desktop / toolchain manager". This seems to limit me to use only projects which are stored under "samples/bluetooth" - I'm not able to navigate to another folder.

    Although there is an .emProject-File in the project's build folder, this SES project file will open the project, but I'm not able to compile the code because it results in errors.

    You say I can copy config files outside the build folder : how would I know which config files I need ? and what I needs to be changed or configured then in order to match the new location ?

Reply
  • I'm not talking about a copy of the whole NCS folder sub-structure, I'm referring to one single project. Also, I dont want to "create" a project - I already have a project, but I want to copy it to another destination on my harddisk.

    When I'm developing (other) code I very often have parallel project folders like "test-v1" and "test-v2" etc - which is sort of versioning system as long as I work with code. For Microsoft tools (eg VS/C++) or code which relies on GNU-makefiles the folder name and location doesn't matter, as long as the content and subdirs are ok I can put the folders wherever I like and it compiles without any trouble - this seems not to work with NCS. It appears to me as if the NCS folder structure forces me to store my project files in a particular place because of the stored paths.

    The whole NCS build process only seems to work when I start SES via "nRF connect for desktop / toolchain manager". This seems to limit me to use only projects which are stored under "samples/bluetooth" - I'm not able to navigate to another folder.

    Although there is an .emProject-File in the project's build folder, this SES project file will open the project, but I'm not able to compile the code because it results in errors.

    You say I can copy config files outside the build folder : how would I know which config files I need ? and what I needs to be changed or configured then in order to match the new location ?

Children
No Data
Related