VS-CODE: build hangs: "Found GnuLd: ld.bfd..."

I am having a recurring problem with NFC-CONNECT: build action. It hangs when building. Gets stuck with the following message in lower-right hand corner of screen:

The procedure I've found to get around this is to cancel the build, and then open a shell in the app directory and do the following:

% rm -rf build*
% export ZEPHYR_BASE=/opt/nordic/ncs/v2.6.0/zephyr
% west build -b nrf52840dk_nrf52840 -p

I can then use the build & build pristine actions.

It might be my environment is not fully supported. The `app` is stand-alone. There is an out-of-the tree module with source i reference with the following CMakeLists.txt fragment:

cmake_minimum_required(VERSION 3.20.0)

set(my-module "${CMAKE_CURRENT_SOURCE_DIR}/../my-module")
set(EXTRA_ZEPHYR_MODULES ${my-module})

find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})

This module includes (via settings) board_root, dts_root, & soc_root,  as well as source, library, and include trees picked up from cmake + kconfig variables.

The build environment: Apple M1 Mac, MacOS: 12.6.7 (Monterey), VS-Code: v1.88.1, NRF-Connect: v2024.3.25

The Welcome tab shows SDK + Toolchain: v2.6.0. (I also use stock Zephyr to compile for non-Nordic boards, but am selecting proper SDK + toolchain, and have even removed `.west` directory for stock zephyr installation). 

Sorry to keep complaining about a great tool, but it's frustrating when it stops working.

Thanks. Kent

Parents
  • This problem was gone for me for a few months but has reappeared in the last 2 weeks. Quitting and reopening VS Code is the only solution I've found, which is quite an inconvenience.

  • Hi

    The working theory as to why we haven't been able to reproduce this is that there is an incorrect version of the VS Code extensions or J-Link on your computer. Uninstalling the SDK and toolchain and reinstalling again should work AFAIK.

    Best regards,

    Simon

  • We think this might be due to a mismatch between the VS Code extension version and J-Link versions installed on your computer, since we still have not been able to reproduce this on our end. Can you share exactly what version of the extension and J-Link firmware installed & used on your computer with these issues.

    Also, what kind of computer are you working on, Apple or Intel based? On Apple devices, you should install the universal version of VS Code from VS Code's pages, as the Toolchain Manager in the nRF Connect for Desktop app installs an Intel based toolchain by default if I recall correctly.

    Best regards,

    Simon

  • Was gone now for couple of weeks with the 2.9.0 again here. 
    is there an export where i can summaries my current workspace setup easy and send you ?

  • You can generate support information in VS Code by pressing this button in the nRF Connect extension. That might be helpful for us.

    Best regards,

    Simon

  • // IMPORTANT: The following data can contain sensitive or confidential information about your environment.
    // If you do not want others to see this information, make sure to remove it before sharing the data.
    
    // For help and support, visit Nordic Semiconductor's DevZone at https://devzone.nordicsemi.com/.
    
    {
      "platform": {
        "os": "darwin",
        "osVersion": "Darwin Kernel Version 22.5.0: Mon Apr 24 20:52:43 PDT 2023; root:xnu-8796.121.2~5/RELEASE_ARM64_T8112",
        "osKernel": "22.5.0",
        "vscode": "1.96.3",
        "electron": "32.2.6",
        "node": "v20.18.1"
      },
      "system": {
        "date": "2025-01-15T16:38:36.686Z",
        "vscodeRoot": "/Applications/Visual Studio Code.app/Contents/Resources/app",
        "nrfConnectForDesktopInstalled": true,
        "vscodeUptime": "06:50:44",
        "osUptime": "06:51:25",
        "cpu": "Apple M2"
      },
      "workspace": {
        "name": "trailpulse-edge",
        "workspaceFile": null,
        "folders": [
          "/Users/sh/dev/git/trailpulse-edge"
        ]
      },
      "sdks": [
        {
          "version": "v2.9.0",
          "path": "/opt/nordic/ncs/v2.9.0"
        },
        {
          "version": "v2.7.0",
          "path": "/opt/nordic/ncs/v2.7.0"
        },
        {
          "version": "v2.6.1",
          "path": "/opt/nordic/ncs/v2.6.1"
        },
        {
          "version": "v2.5.2",
          "path": "/opt/nordic/ncs/v2.5.2"
        }
      ],
      "apps": [
        {
          "workspace": "/Users/sh/dev/git/trailpulse-edge",
          "uri": "/Users/sh/dev/git/trailpulse-edge",
          "buildConfigurations": []
        }
      ],
      "toolchains": [
        {
          "version": "2.9.0",
          "path": "/opt/nordic/ncs/toolchains/b8efef2ad5"
        },
        {
          "version": "2.8.0",
          "path": "/opt/nordic/ncs/toolchains/15b490767d"
        },
        {
          "version": "2.7.0",
          "path": "/opt/nordic/ncs/toolchains/f8037e9b83"
        },
        {
          "version": "2.6.2",
          "path": "/opt/nordic/ncs/toolchains/580e4ef81c"
        },
        {
          "version": "2.6.1",
          "path": "/opt/nordic/ncs/toolchains/580e4ef81c"
        },
        {
          "version": "2.6.0",
          "path": "/opt/nordic/ncs/toolchains/580e4ef81c"
        },
        {
          "version": "2.5.2",
          "path": "/opt/nordic/ncs/toolchains/20d68df7e5"
        }
      ],
      "connectedDevices": [
        {
          "serialNumber": "001050238934"
        }
      ],
      "tools": {
        "/opt/nordic/ncs/toolchains/580e4ef81c/opt/zephyr-sdk/arm-zephyr-eabi/bin/arm-zephyr-eabi-gcc": "0.16.5 (arm64)",
        "/Applications/SEGGER/JLink/JLinkExe": "8.12a (x64,arm64)",
        "/usr/local/bin/nrfjprog": "10.24.0 (x64,arm64)",
        "/opt/nordic/ncs/toolchains/580e4ef81c/bin/cmake": "3.21.0 (arm64)",
        "/opt/nordic/ncs/toolchains/580e4ef81c/bin/west": "1.2.0",
        "/opt/nordic/ncs/toolchains/580e4ef81c/bin/python3": "3.9.6 (arm64)",
        "/opt/nordic/ncs/toolchains/580e4ef81c/bin/ninja": "1.10.2 (arm64)",
        "/opt/nordic/ncs/toolchains/580e4ef81c/bin/gperf": "3.1 (arm64)",
        "/opt/nordic/ncs/toolchains/580e4ef81c/bin/dtc": "1.6.1 (arm64)",
        "/opt/nordic/ncs/toolchains/580e4ef81c/bin/gn": "2154 (arm64)",
        "/opt/nordic/ncs/toolchains/580e4ef81c/bin/git": "2.37.3 (arm64)",
        "arm-gdbPath": "/opt/nordic/ncs/toolchains/580e4ef81c/opt/zephyr-sdk/arm-zephyr-eabi/bin/arm-zephyr-eabi-gdb",
        "riscv-gdbPath": "/opt/nordic/ncs/toolchains/580e4ef81c/opt/zephyr-sdk/riscv64-zephyr-elf/bin/riscv64-zephyr-elf-gdb"
      },
      "nrfutil": {
        "nrfutil-device": {
          "version": "2.7.2",
          "binPath": "/Users/sh/.vscode/extensions/nordic-semiconductor.nrf-connect-2024.12.55-darwin-arm64/platform/nrfutil/bin/nrfutil-device",
          "jlinkInfo": {
            "description": "This version of SEGGER J-Link is different from the J-Link version that was used to test nrfutil device commands",
            "expectedVersion": {
              "version": "JLink_V7.94i",
              "versionFormat": "string"
            },
            "name": "JlinkARM",
            "version": "JLink_V8.12a",
            "versionFormat": "string"
          }
        },
        "nrfutil-toolchain-manager": {
          "version": "0.14.4",
          "binPath": "/Users/sh/.vscode/extensions/nordic-semiconductor.nrf-connect-2024.12.55-darwin-arm64/platform/nrfutil/bin/nrfutil-toolchain-manager"
        }
      },
      "environment": {
        "westEnv": {
          "GIT_EXEC_PATH": "/opt/nordic/ncs/toolchains/580e4ef81c/Cellar/git/2.37.3/libexec/git-core",
          "HOME": "/Users/sh",
          "PATH": "/opt/nordic/ncs/toolchains/580e4ef81c/bin:/opt/nordic/ncs/toolchains/580e4ef81c/usr/bin:/opt/nordic/ncs/toolchains/580e4ef81c/usr/local/bin:/opt/nordic/ncs/toolchains/580e4ef81c/opt/bin:/opt/nordic/ncs/toolchains/580e4ef81c/opt/nanopb/generator-bin:/opt/nordic/ncs/toolchains/580e4ef81c/opt/zephyr-sdk/aarch64-zephyr-elf/bin:/opt/nordic/ncs/toolchains/580e4ef81c/opt/zephyr-sdk/x86_64-zephyr-elf/bin:/opt/nordic/ncs/toolchains/580e4ef81c/opt/zephyr-sdk/arm-zephyr-eabi/bin:/opt/nordic/ncs/toolchains/580e4ef81c/opt/zephyr-sdk/riscv64-zephyr-elf/bin:/opt/homebrew/bin:/opt/homebrew/sbin:/Library/Frameworks/Python.framework/Versions/3.12/bin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/opt/homebrew/bin:/opt/homebrew/sbin:/Library/Frameworks/Python.framework/Versions/3.12/bin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin",
          "ZEPHYR_BASE": "/opt/nordic/ncs/v2.6.1/zephyr",
          "ZEPHYR_TOOLCHAIN_VARIANT": "zephyr",
          "ZEPHYR_SDK_INSTALL_DIR": "/opt/nordic/ncs/toolchains/580e4ef81c/opt/zephyr-sdk",
          "USER": "sh"
        },
        "inherited": {
          "ELECTRON_RUN_AS_NODE": "1",
          "HOME": "/Users/sh",
          "PATH": "/opt/homebrew/bin:/opt/homebrew/sbin:/Library/Frameworks/Python.framework/Versions/3.12/bin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin",
          "USER": "sh"
        }
      },
      "terminal": {
        "defaultProfile": null
      },
      "config": {
        "nordic-semiconductor.nrf-connect": {
          "topdir": "${nrf-connect.sdk:2.6.1}",
          "toolchain": {
            "path": "${nrf-connect.toolchain:2.6.1}"
          },
          "ozonePath": "",
          "applications": [],
          "applicationOptions": {},
          "kconfig": {
            "interface": "kconfig"
          },
          "west": {
            "env": {
              "$base": "terminal"
            }
          },
          "boardRoots": [],
          "taskBindings": {},
          "buildTerminal": {
            "condensedProgress": true
          },
          "debugging": {
            "flash": true,
            "bindings": {},
            "justMyCode": false
          },
          "activeAppFollowActiveEditor": true,
          "flash": {
            "softreset": false,
            "erase": false,
            "recover": false
          },
          "enableTelemetry": true,
          "thirdpartyIntegration": {},
          "toolchainManager": {
            "indexURL": null,
            "installDirectory": null
          },
          "nrfutil": {
            "home": null
          },
          "defaultOpenAction": "ask",
          "terminalProfile": {
            "shell": null
          }
        },
        "nordic-semiconductor.nrf-terminal": {
          "terminalMode": "character"
        }
      },
      "extensions": {
        "internal": {
          "nordic-semiconductor.nrf-connect": {
            "version": "2024.12.55",
            "path": "/Users/sh/.vscode/extensions/nordic-semiconductor.nrf-connect-2024.12.55-darwin-arm64",
            "isActive": true
          },
          "nordic-semiconductor.nrf-terminal": {
            "version": "2024.9.14",
            "path": "/Users/sh/.vscode/extensions/nordic-semiconductor.nrf-terminal-2024.9.14",
            "isActive": true
          },
          "nordic-semiconductor.nrf-devicetree": {
            "version": "2024.12.15",
            "path": "/Users/sh/.vscode/extensions/nordic-semiconductor.nrf-devicetree-2024.12.15",
            "isActive": true
          },
          "nordic-semiconductor.nrf-kconfig": {
            "version": "2024.12.13",
            "path": "/Users/sh/.vscode/extensions/nordic-semiconductor.nrf-kconfig-2024.12.13",
            "isActive": true
          }
        },
        "external": {
          "marus25.cortex-debug": null,
          "ms-vscode.cpptools": "1.22.11",
          "ms-vscode.js-debug": "1.96.0",
          "ms-vscode.js-debug-companion": "1.1.3",
          "ms-vscode.vscode-js-profile-table": "1.0.10",
          "alexnesnes.teleplot": "1.1.4",
          "bierner.markdown-mermaid": "1.27.0",
          "Continue.continue": "0.8.66",
          "ms-python.debugpy": "2024.14.0",
          "ms-python.python": "2024.22.2",
          "ms-python.vscode-pylance": "2024.12.1",
          "ms-vscode-remote.remote-containers": "0.394.0",
          "ms-vscode.cmake-tools": "1.19.52",
          "ms-vscode.cpptools-extension-pack": "1.3.0",
          "ms-vscode.cpptools-themes": "2.0.0",
          "ms-vscode.hexeditor": "1.11.1",
          "platformio.platformio-ide": "3.3.4",
          "TabNine.tabnine-vscode": "3.223.0",
          "trond-snekvik.gnu-mapfiles": "1.1.0",
          "twxs.cmake": "0.0.17"
        }
      }
    }
    
    

    here pls
    thanks in advanced simon

  • Thanks Sebastian. I've forwarded the support info to the internal ticket and we'll get back to you if we find something useful.

    Best regards,

    Simon

Reply Children
No Data
Related