Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The package 'toolchain-gccarmlinuxgnueabi' is not available #2

Open
ivankravets opened this issue Nov 27, 2016 · 14 comments
Open

The package 'toolchain-gccarmlinuxgnueabi' is not available #2

ivankravets opened this issue Nov 27, 2016 · 14 comments

Comments

@ivankravets
Copy link
Member

ivankravets commented Nov 27, 2016

Temporary solution

PlatformIO currently does not support cross-compilation for RaspberryPi and similar boards.
Please use one of:

a) PlatformIO Core directly on a target device
b) PIO Remote and work with your hardware from anywhere in the world.


Attempt to use the arm / raspberrypi platform. gets the error.
Error: The package 'toolchain-gccarmlinuxgnueabi' is not available for your system 'linux_x86_64'

Also had this error under 64 bit windows.


Configuration

Operating system: Linux, x86_64 x-ubuntu

PlatformIO Version (platformio --version):
PlatformIO, version 2.8.5

Description of problem

Steps to Reproduce

  1. Using the IDE, Initalise new project
  2. Select "Raspberry Pi 1 Model B"
  3. Click Initalize

Actual Results

PlaftormIO: Failed to initialize PlatformIO project!
Error: The package 'toolchain-gccarmlinuxgnueabi' is not available for your system 'linux_x86_64'

Expected Results

I would expect to be able to cross compile to arm from 64 bit linux..


Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

@ivankravets
Copy link
Member Author

Temporary solution is http://docs.platformio.org/en/latest/plus/pio-remote.html

@hoosierEE
Copy link

Another data point.
I see a similar error on Ubuntu aarch64:

lx@~/Downloads/blinky-light-strip/pio[master !?*] platformio --version
PlatformIO, version 3.3.0
lx@~/Downloads/blinky-light-strip/pio[master !?*] pio run -t build
[Thu Apr  6 19:38:47 2017] Processing teensylc (platform: teensy, board: teensy35, framework: arduino)
--------------------------------------------------------------------------------------------------------------------------------------------
PackageManager: Installing toolchain-gccarmnoneeabi @ >=1.40803.0,<1.40805.0
Error: Could not find a version that satisfies the requirement '>=1.40803.0,<1.40805.0' for your system 'linux_aarch64'

@ivankravets
Copy link
Member Author

@hoosierEE your issue has been fixed bc5f23c

Could you re-test?

  1. pio platform uninstall linux_arm
  2. pio platform install https://github.com/platformio/platform-linux_arm.git

@hoosierEE
Copy link

hoosierEE commented Apr 7, 2017

Re-tested, no change.

To be clear, the target device which I want to program is a Teensy 3.5, the host machine (which runs PlatformIO) is Linux ARM aarch64.

[EDIT]
I did another test, changing the platform to atmelavr and board to nanoatmega328, and got a similar failure message:

PackageManager: Installing toolchain-atmelavr @ ~1.40902.0
Error: Could not find a version that satisfies the requirement '~1.40902.0' for your system 'linux_aarch64'

@zgoda
Copy link

zgoda commented Jun 19, 2017

FYI, at least on Debian derivatives there is a system package crossbuild-essential-{arm64|armel|armhf} which installs ready toolchain system wide:

$ arm-linux-gnueabihf-gcc --version
arm-linux-gnueabihf-gcc (Ubuntu/Linaro 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

$ apt-cache show crossbuild-essential-armhf
Package: crossbuild-essential-armhf
Priority: optional
Section: devel
Installed-Size: 15
Maintainer: Ubuntu Developers <[email protected]>
Original-Maintainer: Matthias Klose <[email protected]>
Architecture: all
Source: build-essential
Version: 12.1ubuntu2
Depends: gcc-arm-linux-gnueabihf (>= 5.2), g++-arm-linux-gnueabihf (>= 5.2), dpkg-cross
Filename: pool/main/b/build-essential/crossbuild-essential-armhf_12.1ubuntu2_all.deb

Since the toolchain is rather large, I'd suggest to fall back to download only if it is not already present.

@poelzi
Copy link

poelzi commented Dec 18, 2017

I seriously can't understand why the toolchain for linux_arm does only exist for darwin but not linux platforms. I was not able to find it, only for darwin. As this causes a but every 2 weeks, can you please add the proper entry and toolchain, please. It is obviously a wanted target.

  "toolchain-gccarmlinuxgnueabi": [
    {
      "sha1": "4606ce747ee2a59497e4859e6b22fce0c6df5904", 
      "system": [
        "darwin_x86_64", 
        "darwin_i386"
      ], 
      "url": "http://dl.platformio.org/packages/toolchain-gccarmlinuxgnueabi-darwin_x86_64-1.40802.0.tar.gz", 
      "version": "1.40802.0"
    }
  ], 

@ivankravets
Copy link
Member Author

We don't have toolchains for Linux which allow building source code for ARM GNU EABI. We have all toolchains for NONE EABI.

@ivankravets ivankravets changed the title The package 'toolchain-gccarmlinuxgnueabi' is not available for your system 'linux_x86_64' The package 'toolchain-gccarmlinuxgnueabi' is not available Jul 11, 2018
@shaman7036
Copy link

а это вообще будет работать???))))

@JonnyTech
Copy link

Is it possible to cross-compile yet (from Linux 64bit desktop for Linux ARM Raspberry Pi)? I cannot access my device with PIO Remote and do not have a similar device with me. I just want to be able to compile the source to a binary format and send it to my non-technical colleagues to test. Is there any way to build the output file at all? Even if the process is very tedious, I am willing to do it. Thanks.

@sergerold
Copy link

agreed, would be fantastic to cross-compile for the rpi. is it an IP issue?

@twischer
Copy link

On Linux using qemu binfmt to emulate ARM build environment might be another workaround:
On Debian based system (on e.g. x86 machine) you have to do the following:

sudo apt install qemu binfmt-support qemu-user-static
wget https://github.com/debuerreotype/docker-debian-artifacts/raw/dist-arm32v7/buster/slim/rootfs.tar.xz
unp -u rootfs.tar.xz
cd rootfs
sudo mount -o bind /sys ./sys
sudo mount -o bind /proc ./proc
sudo chroot ./
apt install python3-pip
pip3 install platformio

In this ARM based change root file system you can use any platformio command to compile the binary for your raspberry.
E.g. download the examples from https://github.com/platformio/platform-linux_arm/tree/master/examples/wiringpi-blink, copy it to the newly created root file system and execute pio run in the project directory.

I have not yet tested it completely but so far it seems to work.

@maxgerhardt
Copy link

This was asked again at https://community.platformio.org/t/raspbberry-pi-4-create-project-problem/22314/, official support would be good :(

@techdragon
Copy link

Ok... so 5 years have passed... is this still "temporary" half a decade later? or has this just become an accepted limitation that will never be resolved?

Personal Note: This is deeply frustrating to me (and I'm probably not the only one that finds it frustrating), the whole reason I read up on PlatformIO and bothered to install it in the first place was to simplify dealing with cross-compiling C/C++ (Honestly I'd rather just use rust where this is is a solved problem with zero issues cross compiling, but I have a whole C SDK I need to use on a project, so I'm stuck dealing with c/c++ cross compile toolchains)

@sebeaumont
Copy link

@techdragon I couldn't agree more as indeed I just went thorough that same loop. Another hour of my life wasted. Grr.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests