💾 Archived View for bbs.geminispace.org › s › Levior › 17350 captured on 2024-07-09 at 02:34:08. Gemini links have been rewritten to link to archived content

View Raw

More Information

⬅️ Previous capture (2024-06-16)

➡️ Next capture (2024-08-18)

🚧 View Differences

-=-=-=-=-=-=-

is it feasible to get rid of rust dependency?

it makes building levior hard on

Posted in: s/Levior

🐙 norayr

May 27 · 6 weeks ago

14 Comments ↓

🐙 norayr [OP] · May 27 at 12:08:

on pinebook gentoo it's not hard anymore, it's impossible as well, since some point rust is not possible to build on it.

😺 gemalaya [mod] · May 27 at 17:54:

@norayr Hello :) There is no direct dependency on rust. But it's possible that one of the dependencies depends on something that requires rust, and if you're building on a platform that has a python wheel available from pypi, then it fetches it from pypi and you don't need rust ...

I'll try to find which dependency (indirectly) requires rust.

😺 gemalaya [mod] · May 27 at 18:01:

I've looked at the dependency tree but ... If you have the build error log then you must see which package fails when looking for rust ?

😺 gemalaya [mod] · May 27 at 19:04:

I think it's the cryptography package which requires rust-bin to build. aiogemini requires "cryptography". I found a comment on stackoverflow that suggests that cryptography < 35.0 can be built without rust by setting CRYPTOGRAPHY_DONT_BUILD_RUST=1. However cryptography 35.0 is an almost 3 years old release so ...

Can you try adding "cryptography==3.4.8" in pyproject.toml's "dependencies" array and try to build with this command ?

CRYPTOGRAPHY_DONT_BUILD_RUST=1 pip install .

aiogemini's dependency spec for cryptography is ">= 3.2,< 42.0" so that could work.

😺 gemalaya [mod] · May 27 at 19:07:

Weird cause, i installed levior on a rpi3+, aarch64, and i didn't have any issues, works fine.

😺 gemalaya [mod] · May 27 at 20:07:

— https://lwn.net/Articles/845535/

😺 gemalaya [mod] · May 27 at 20:13:

Also, be sure to run "pip install -U pip", that could be the issue. I see that there are aarch64 wheels for "cryptography" so building on aarch64 without rust is definitely possible.

— https://stackoverflow.com/questions/66118337/how-to-get-rid-of-cryptography-build-error

🚀 stack · May 27 at 20:41:

Why can't people just write god-damned C code? Only half joking :)

🐙 norayr [OP] · May 28 at 00:57:

Can you try adding "cryptography==3.4.8" in pyproject.toml's "dependencies" array and try to build with this command ?
CRYPTOGRAPHY_DONT_BUILD_RUST=1 pip install .

it works, i was able to build it, thank you!

😺 gemalaya [mod] · May 28 at 09:35:

@norayr Nice ! No issues with TLS connections ?

😺 gemalaya [mod] · May 28 at 09:44:

I'll try to provide an appimage for aarch64 as well.

😺 gemalaya [mod] · May 28 at 10:17:

Actually there's no aarch64 dist for python-appimage so that's a problem ...

— https://github.com/niess/python-appimage

For now I'll just add a section in the README to explain how to build it on aarch64.

🐙 norayr [OP] · May 29 at 00:28:

thank you, but for me, sincerely, don't bother. i prefer to build software myself, appimages feel like black boxes.

🐙 norayr [OP] · May 29 at 00:30:

also yes, i think no issues. it works well. thank you!