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

Linker unable to find functions in object

The project is cobbled together, but starts from TWIsensor in the SDK 14 examples. The project is compiled with the gcc toolchain which has not given me any trouble. The project compiles but the linker is unable to find functions within the object file which is my GPIO.c file. The _build has a GPIO.c.o and it is populated but the linker can not find the functions. The make file is cobbled together as well but has started from the TWIsensor as well, the make file seems to have many of the same src and folders as the example gpiote. 

Any suggestions would be appreciated.

  • FormerMember
    +1 FormerMember

    If you are using some modules/drivers from the SDK, they need to be enabled in sdk_config.h. Could you double check that the modules/drivers have been enabled?

     

    Since the project is building, I would assume that you have added the path to GPIO.c in the makefile?

    # Source files common to all targets
    SRC_FILES += \
      $(SDK_ROOT)/components/libraries/experimental_log/src/nrf_log_frontend.c \
      $(SDK_ROOT)/components/boards/boards.c \
      $(SDK_ROOT)/components/libraries/util/app_error.c \
      $(SDK_ROOT)/components/libraries/util/app_error_weak.c \
      $(SDK_ROOT)/components/libraries/util/app_util_platform.c \
      ..
      $(SDK_ROOT)/path_to_custom_gpio_file/GPIO.c \

  • Kristin,

    Way to go genius, that was it! Thank you!

Related