Skip to content

Darwin/amd64 installs wrong tools (darwin/amd64) #751

Closed
@umbynos

Description

@umbynos

Describe the problem

Running the getting started on MacOS with Amd64 architecture causes the agent to download the wrong tool system (when multiple macOS systems are available for a tool) an example of this is the arduino-fwuploader which is available both for amd64 and arm64.

To reproduce

Connect a board with an old fw (for example Nina 1.4.3) to the PC and add a new device in Arduino IoT Cloud. Perform the getting started. It should fail trying to run the arduino-fwuploader with an error similar to Bad CPU type in executable.

(The problem is that the agent has downloaded the arm64 binary instead of the amd64 one)

Expected behavior

The agent should download the correct binary

Arduino Create Agent version

1.2.7

Operating system

macOS

Operating system version

N/A

Browser

N/A

Browser version

N/A

Additional context

The problem should be fixed in

var systems = map[string]string{
"linuxamd64": "x86_64-linux-gnu",
"linux386": "i686-linux-gnu",
"darwinamd64": "apple-darwin",
"windows386": "i686-mingw32",
"windowsamd64": "i686-mingw32",
"linuxarm": "arm-linux-gnueabihf",
}

Even better would be to use the Arduino CLI way of detecting and downloading a tool: https://github.com/arduino/arduino-cli/blob/08d746dd9c31ce75b94a2c3caced3e34b6687f6a/arduino/cores/tools.go#L126-L213

Issue checklist

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

Metadata

Metadata

Assignees

Labels

architecture: armSpecific to ARM host architectureos: macosSpecific to macOS operating systempriority: highResolution is a high prioritytype: 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