This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Receiving error no such file for offsets.c.obj when building solution

I have updated my repos to the latest commits on master for zephyr, mcuboot, nrf, and nrfxlib. I ran `

pip3 install -r scripts\requirements.txt

and I can open the asset_tracker SDK project but when I go to build, I get this error. What would be causing this now that I've updated the codebase?

Building ‘zephyr/include/generated/driver-validation.h’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/include/generated/kobj-types-enum.h’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/include/generated/otype-to-str.h’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/misc/generated/syscalls.json’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/include/generated/syscall_list.h’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/include/generated/syscall_dispatch.c’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/include/generated/syscall_macros.h’ from solution ‘build’ in configuration ‘Common’
Building ‘zephyr/include/generated/offsets.h’ from solution ‘build’ in configuration ‘Common’
Combining ‘zephyr/include/generated/offsets.h’

/PROJECTCODE/ncs/zephyr/scripts/gen_offset_header.py", line 72, in <module>
[Errno 2] No such file or directory: 'C:/PROJECTCODE/ncs/fw-nrfconnect-nrf/applications/asset_tracker/build/zephyr/CMakeFiles/offsets.dir/arch/arm/core/offsets/offsets.c.obj'

Build failed

Parents
  • The latest master branch does not currently work with Segger Embedded Studio. If I were you, I would revert to the v0.3.0 tag. There is some documentation here that helps to clarify slightly:

    "The latest state of development is on the master branches of the fw-nrfconnect-nrf, fw-nrfconnect-mcuboot, and nrfxlib repositories and the nrf91 branch of the fw-nrfconnect-zephyr repository. Note that this might not be a stable state. Therefore, unless you are familiar with the development process, you should always work with a specific release of the nRF Connect SDK."

    You can revert to v0.3.0 by running the following commands:

  • Sorry to jump on, but I am getting the identical error (same line# in python script, same error message) trying to build an nRf52840 project with Zephyr and emStudio.  I am NOT using the asset_tracker project.  Is this related or simply a coincidence?

  • This may be related. Have you tried to use the v0.3.0 tag like mentioned in my comment? Does that work?

Reply Children
  • Perhaps I do not understand.  I thought the v0.3.0 tag referred to the asset_tracker project.  I am getting this same error while building a custom nRF52840 project.  Does v0.3.0 refer to emStudio?

  • Sorry about the misunderstanding. The v0.3.0 tag refers to a release made for the Nordic Connect SDK nRF tree (NCS). If you are using an nRF52840, it is recommended to use an nRF5 SDK example. NCS is only being supported for nRF91 devices at the moment. See the disclaimer at the bottom here. Sorry about the inconvenience.

    If you however still want to use NCS for development, it may work using the v0.3.0 tag.