Skip to content

The filename or extension is too long #2368

Open
@luftaquila

Description

@luftaquila

Describe the problem

In Windows, I cannot compile a sketch with a following error.

Used platform Version Path
esp32:esp32   2.0.14  C:\Users\LUFT-AQUILA\local\workspace\monolith\builder\toolchain\arduino\data\packages\esp32\hardware\esp32\2.0.14
Error during build: fork/exec C:\Users\LUFT-AQUILA\local\workspace\monolith\builder\toolchain\arduino\data\packages\esp32\tools\xtensa-esp32-elf-gcc\esp-2021r2-patch5-8.4.0/bin/xtensa-esp32-elf-g++.exe: The filename or extension is too long.

It seems like that xtensa-esp32-elf-g++.exe: The filename or extension is too long. is the problem.

I found some related issues #839 and #961.

I think this problem is fixed at around 0.14 according to the issues above, but I'm experiencing the problem in 0.34.

platform.local.txt at #839 (comment) did not worked.

To reproduce

arduino-cli --config-file ./config/arduino-cli.yaml compile --board-options LoopCore=0 -e --fqbn esp32:esp32:esp32 -v ../device/telemetry/telemetry.ino

The default ESP32 example sketches instead of mine have same problem, too.

arduino-cli.yaml

board_manager:
  additional_urls:
  - https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json
build_cache:
  compilations_before_purge: 10
  ttl: 720h0m0s
daemon:
  port: "50051"
directories:
  data: ./toolchain/arduino\data
  downloads: ./toolchain/arduino\downloads
  user: ./toolchain/arduino\user
library:
  enable_unsafe_install: false
logging:
  file: ""
  format: text
  level: info
metrics:
  addr: :9090
  enabled: true
output:
  no_color: false
sketch:
  always_export_binaries: false
updater:
  enable_notification: true

Expected behavior

A normal compilation as IDE does, instead of The filename or extension is too long error.

Arduino IDE 2.2.1 compile output

arduino-cli 0.34 compile output

Arduino CLI version

arduino-cli.exe Version: nightly-20231013 Commit: 3a2f9f1 Date: 2023-10-13T01:28:47Z

Operating system

Windows

Operating system version

Windows 11 Pro 22H2

Additional context

No response

Issue checklist

  • I searched for previous reports in the issue tracker
  • I verified the problem still occurs when using the nightly build
  • My report contains all necessary details

Metadata

Metadata

Assignees

No one assigned

    Labels

    os: windowsSpecific to Windows operating systemtype: imperfectionPerceived defect in any part of project

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions