-
Notifications
You must be signed in to change notification settings - Fork 34
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
Using pack manager on arm-based system #108
Comments
Sorry for bothering, i found how to build it by myself. Problem solved. |
Actually, I would like to look into this. |
Dang, not super easy... pypa/manylinux#84 |
Also, the code in PEP 571 returns false for non-x86 platforms |
After some tries with compiling (needed to underclock orangepi because of overheating) finally i "finished" compiling a library. Unfortunately, after few hours (idk how long, i left it for night to compile) an error appears:
I hoped i can make it works, but now i know, i cant. Maybe someone, who have more knowledge than me can do it. Edit#1: grammatical editing :) |
@theotherjimmy I assume the effect of this would be not being able to install pyocd on beagle bone black, nor raspberry pi? @Team-EmbeddedPlanet often uses BBB industrial as gdb servers. We are about to switch back to using pyOCD from jlinkgdb server. |
Update: When i downgrade Rust to version nightly from 2018-11-06, I've finally managed to "succesfully" build CPM. Problem is, every compilation gives CPM v0.1.1, not downloaded v0.2.6. |
Maybe it-s important, i don't completely restart compilation from beginning, but i retype same command '''python setup.py -v install''' i've used earlier. |
@40Grit Thanks for the update on EmbeddedPlanet. I think it's becoming a good time to get some sort of pip-installable, arm thing available. @harrrson That looks like OOM (out of memory), and restarting the build after the OS recollects the memory from the dead process can help. For the "v0.1.1" issue, |
@theotherjimmy that sounds logic. On the morning (7:30 pm atm of writing this post) i'd started the compilation with source code from latest release (tar.gz file), but unfornatunately, my orangepi stops responding to vnc remote access. When i retrieve access to it, i'll tell you if it works, or not. |
We are also working on that (end-user build with |
Sadly, when i restarted compilation of CPM, it starts to "overload" at exactly the same packages (one of them was syn). Because of that i can't connect remotely (again) to orangepi, and needed to restar it manually. Later i tried to compile library on my computer, i had installed |
Hey @harrrson please follow the Build on FreeBSD thread provided above (#97).. when that works it should work on any other Open-Source platform :-) Except for some Python PIP dependencies, you will also need to have
You may want to give a try to FreeBSD port to ARM from https://www.freebsd.org/where.html? :-) |
@cederom I think the issue is that @harrrson I'll look into building an arm binary wheel with rust cross-compilation from a large x86_64 box Tuesday or Wednesday. |
Sometimes I just wonder.. how did we make it through the 80s with 8-bit machines and 64K of RAM :-) :-) :-) I missed the instructions link, sorry :-) Looks like something sends SIGKILL to the build process, maybe some sort of timeout/watchdog from build system configuration that can be tuned? Looks like cross-compilation from PC to ARM could be aletrnative solution? I am sure that if we make CPM build on FreeBSD it will work everywhere just with |
@cederom Agreed, we're in a crazy world now. I'm thinking that the Linux kernel is sending that SIGKILL, due to the fact that the RPI ran out of memory, and that's why it stops at a specific point: when we encounter a particularly big crate. Yes, we could probably cross-compile and skip this problem on ARM, or other small computers. |
I have managed to build On Linux some additional development dependencies are required in order to build https://asciinema.org/a/MeYMuwJkUxAFhMG5WwVjJ5aZP Here is build on Here is full reference: pyocd/pyOCD#699 |
Ooph, an hour to build is pretty bad. I hope to have some form of cross compile at some point. |
Hi, is there any solution to this problem available at current time? I need support for STM32F303ZETx which is not supported by the pyocd by default, so on my pc I am using the cmsis packet for it. Now I am trying to port my scripts for automatic flashing to rpi and got stuck at this problem ... |
Hi @IzidorM, I don't have a solution to the OOM in syn just yet. Perhaps you could try building with a cross rustc and copying the built artifacts over? |
@IzidorM You can manually download the STM32F303 pack and use the |
Thanks both for your help. I went with the flit recommendation and updated my script with: self.session = Session(self.probe, options={"pack":"/home/pi/flasher/Keil.STM32F3xx_DFP.2.1.0.pack"}, target_override="STM32F303CCTx") |
Hmm, I think I should have a binary built somewhere for ARM Pi, will share during weekend, maybe that helps :-) |
That sounds great. I think I should be looking into the aarch64 travis instances. |
Not sure what specific files are required so I have packed all my virtualenv. python3.7 rpi. hope that helps :-) https://drive.google.com/drive/folders/1eknI93IztWi5Eoarcl145HfnDilVBucn |
Still an issue 2 years later? :( Trying to use
I have tried downloading the pack file and passing --pack as suggested in this thread, but I get:
|
Hey @towen you seems to have missing dependency @flit is it possible to create ARM Linux and FreeBSD CI build hosts so the binary packages are distributed directly with @flit usually there was the |
Thanks @cederom - I worked around this in the end with Also fyi, I installed cargo and tried to upgrade pyocd again via pip. It got much further but still failed:
|
This looks like a problem with Also let us know how much RAM do you have on the build ARM machine. Not enough RAM with no Swap can also result in build errors.. |
This is a Raspberry Pi with 4GB RAM, 70MB of which is 'used' (it's not running X11 etc) and it has 100MB of swap, apparently. I have now upgraded to raspbian bullseye, and my rustc is now 1.48.0 however when I try Thanks for your help anyway :) |
Hi all! For AArch64, as of a few days ago, we released a new version 0.3.0 of cmsis-pack-manager (CPM) that has binary wheels on PyPI for Linux and includes AArch64, as well as pyocd version 0.32.0 that requires this version of CPM. For Raspberry Pi, the Bullseye prerelease of Raspberry Pi OS (which is 32-bit, except for a beta 64-bit release) with Python 3.9 should install the cmsis-pack-manager binary wheel. Unfortunately the version of Rust available in Buster is too old to work, and the piwheels folks won't install anything but the Rust Debian package If you aren't using RPi OS Bullseye, you need a modern Rust toolchain installed, preferably via rustup. I will also add the CPM wheel for Python 3.7 (RPi OS Buster) to the CPM release on GitHub. This will have to be manually installed though, prior to installing pyocd. (You can see the piwheels FAQ, as well as their blog, for some more answers about why Linux armv6/7 wheels shouldn't be used on Raspberry Pi and thus why piwheels.org was created.) I'm testing everything myself as I get time this week, and will try to get the readme and docs updated shortly with the how-to for Raspberry Pi. It wouldn't hurt if you felt like commenting on the CPM issue for piwheels about uploading the wheel for Buster 😉. |
@towen Swap is recommended to have 2 * RAM size.. 1 * RAM at least. This is because when OS runs out of RAM it can still operate. You may try 0.5 * RAM size. The bigger the better because when you want to do some development you may come into a situation where large and memory hungry stuff jumps in like now with rust. You may not need it for "using" the software but for "building" the software RAM can speed things up a bit (CPU is most important here) or return error when compiler / OS runs out of memory. I can tell because on FreeBSD almost no one provides packages (even for pip) so I have to build most of the stuff on my own :-) Thanks @flit :-) Can you drop me a hint on the CI build so I could setup FreeBSD host for CPM and pyPCD ? This way we could provide out of the box pyOCD and CPM packages to pip :-) |
@cederom we are using GitHub Actions (https://github.com/pyocd/cmsis-pack-manager/tree/main/.github/workflows), that does not support FreeBSD. There is this project https://github.com/marketplace/actions/freebsd-vm that you could possibly use. |
I've tried to install newest pyocd version on armbian, but when trying to install it even with pip, every time installed version of pack manager is 0.1. Is it possible to install newest version of pack manager on arm-based system? sorry for newbie question, but i've tried to google it, without any results.
The text was updated successfully, but these errors were encountered: