Now I have to figure out how to make ureq in this RSS reader use the proxy set with environmental variables. It looks trivial to accomplish: a matter of implementing the Default trait, which is now derived, for the structure (which would be an object in classic object oriented language) that is used as HTTP client.
Some problems arise from software relying on atomics (thread-safe types) from the standard library, which aren't portable — luckily, there is portable-atomic crate: https://github.com/taiki-e/portable-atomic
Replacing atomics from standard library with the ones from portable-atomic IS straightforward, but in my case it was a dependency of a dependency using it, so building the RSS reader involved adding a [patch.crates-io] section to Cargo.toml to use a local patched version of crate.
In case some of the crates use C code and build something themselves, like ring crate does, you have to point cargo to the right tools using the environment variables, but in a lot of cases it figures everything out on its own.
Also rust crate version 0.16 didn't support 32-bit PowerPC properly so to port TUI RSS reader here https://github.com/veeso/tuifeed I had to update a few dependencies to use newer ring 0.17
It appears that cross-compiling with Rust is rather straightforward: just install the target you're… hmm, targeting with "rutsup target add <target>", and use "cargo build --target <target> --release" — not much harder than it is with Go.
Considering that your target is available via rustup — mine, PowerPC MUSL system wasn't and I had to build natively, I'll figure out how to add my own targets later. But building for my old ARM machine went without a hitch — and, surprisingly, the binary works😂
I have sussexfully updated rust (and cargo) to 1.79 on my PowerPC MUSL machine running Void.
xbps-src makes cross-building software so easy, in absolute most cases you only have to specify the target architecture and here we go — although it fails to produce a working dynamically-linked Python for PowerPC, but it looks like a bug in libffi. In any case you only have to worry about platform-specific workarounds, most of other stuff is done for you — and it just works!
@nina_kali_nina @kirtai Wow, MicroWeb makes DOS look like quite the limited OS! Yet they got something working, despite needing to implement the whole networking stack themselves!
@ajroach42 you might be interested? https://github.com/jhhoward/MicroWeb
LOL, on orders from Russia’s GenPro, Vkontakte blocks popular account of “Z-poet Gennady Rakitin” that was actually Nazi poems translated by antiwar activists trying to show invasion supporters that their "patriotism" is simpatico with 1930s–40s Germany. https://t.me/sotaproject/83006
A FUSE filesystem and dungeon crawling adventure game engine? What's this madness?
Rossiyskaya Gazeta, Russia’s official govt newspaper, publishes an essay by lawyer Ilya Rusyaev where he says the verdict against the Nevzorovs should be a model for outlawing more “extremist families” and various “small social groups.” Truly demented. https://rg.ru/2024/07/03/reg-szfo/iurist-rusiaev-konfiskovannyj-penthaus-nevzorova-s-cherepami-budet-slozhno-prodat.html
It's always tempting to allocate objects on the stack, but there's a good reason why you shouldn't allocate large ones if you care about your application's memory footprint: the stack space you use is used forever, even if you don't need it anymore.
Now you might be wondering, wait a sec, I thought that stack variables are freed when they go out of scope, right? Well, yes and no. Let's talk about this. 🧵 1/8
None
Just in case: DMs/PMs simply don't exist on this instance as concept — don't use them, use the other instance if you absolutely have to, or send an email to any address at m0xEE.Net or .Com or .Org, but I prefer keep most communication public.