| 8 Feb 2025 |
Niklas Korz | so arguably eBPF could be added here too | 15:14:42 |
Niklas Korz | or more specifically, bpfel-unknown-none and bpfeb-unknown-none | 15:15:28 |
Niklas Korz | Maybe only when targeting Linux, and only one of the two endians depending on arch | 15:19:30 |
Niklas Korz | Might take a shot at an exemplary staging PR later, gonna go for a walk now | 15:24:06 |
ghpzin | If it can get away with not building on hydra, then you can probably do cross with toolchain.
Iirc there is something in nixpkgs that does it. | 17:36:40 |
Alyssa Ross | In reply to @niklaskorz:korz.dev Maybe only when targeting Linux, and only one of the two endians depending on arch IMO more rustc targets we can build into a single compiler, the better | 17:50:21 |
Alyssa Ross | the reason we only have wasm in there atm is that it was the only once i could get to build | 17:51:42 |
Alyssa Ross | if more can be built in now let's add them in every situation we can | 17:51:58 |
| @marcel:envs.net joined the room. | 20:25:55 |
Niklas Korz | I see 💯 will give it a shot for the bpf targets | 20:52:21 |
Niklas Korz | hm so that's mainly beind hindered by BPF only supporting no_std, gotta look tomorrow if there is something like --target for only building core, not std | 23:18:35 |
| 9 Feb 2025 |
Alyssa Ross | I remember the main problem with adding no_std was that it would try to build non-existent std documentation. That probably needs fixing upstream. | 07:11:30 |
Niklas Korz | I see, so odds are that you can't build that a documented yet. I'll ask for clarification on the pending docs PR for the BPF targets. | 09:26:48 |
Niklas Korz | * I see, so odds are that you can't build that as documented yet. I'll ask for clarification on the pending docs PR for the BPF targets. | 09:26:52 |
Alyssa Ross | You can, but you can't do it if you're also building targets that have std, I think | 09:29:49 |
Alyssa Ross | something like that | 09:29:50 |
Niklas Korz | so the solution would be to do something like we did before with rustc-wasm32? | 09:31:25 |
Niklas Korz | as that also disabled building docs | 09:31:29 |
Alyssa Ross | No, please no more Rust compilers | 09:31:47 |
Alyssa Ross | The solution is for Rust's build system to be fixed. | 09:31:54 |
Niklas Korz | ok, I'll raise it on the docs PR after all then, at the very least to get that behavior documented | 09:32:34 |
Alyssa Ross | try adding the bpf target to Nixpkgs' rustc if you haven't already first though, just in case this has been fixed since last timme | 09:33:49 |
Alyssa Ross | * | 09:34:00 |
Alyssa Ross | or in case it's now broken for some other reason | 09:34:07 |
Niklas Korz | yeah I did that, and ended up with errors in std related to atomic types | 09:34:28 |
Alyssa Ross | oh! then it might be even more broken than just the docs problem | 09:34:50 |
Niklas Korz | brb checking at which stage it failed | 09:53:46 |
Sandro 🐧 | So
diff --git a/pkgs/development/compilers/rust/rustc.nix b/pkgs/development/compilers/rust/rustc.nix
index d7a1ee625f9c..92e0997a3e19 100644
--- a/pkgs/development/compilers/rust/rustc.nix
+++ b/pkgs/development/compilers/rust/rustc.nix
@@ -161,6 +161,7 @@
# Other targets that don't need any extra dependencies to build.
]
++ optionals (!fastCross) [
+ "bpfel-unknown-none"
"wasm32-unknown-unknown"
# (build!=target): When cross-building a compiler we need to add
diff --git a/pkgs/development/python-modules/mitmproxy-linux/default.nix b/pkgs/development/python-modules/mitmproxy-linux/default.nix
index 01bacdb002ed..0ee05f35dcb4 100644
--- a/pkgs/development/python-modules/mitmproxy-linux/default.nix
+++ b/pkgs/development/python-modules/mitmproxy-linux/default.nix
@@ -18,6 +18,13 @@
tag = "v${version}";
hash = "sha256-lWUHdS+AkMnIg+1SR+9fC+YjcyLK80UknwGablniLSg=";
};
+
+ postPatch = ''
+ substituteInPlace mitmproxy-linux/build.rs \
+ --replace-fail '"-Z",' "" \
+ --replace-fail '"build-std=core",' ""
+ '';
+
cargoDeps = rustPlatform.fetchCargoVendor {
inherit pname version src;
hash = "sha256-ihbVh73eulqFyKC49KfsCFJqahr3nWVFFc97iFFf3Nk=";
will not just work?
| 16:59:25 |
Niklas Korz | rustc> Documenting stage2 library {alloc, core, panic_abort, panic_unwind, proc_macro, std, sysroot, test, unwind} in HTML format (aarch64-apple-darwin -> bpfel-unknown-none)
so it's the docs after all
| 09:54:33 |
Sandro 🐧 | yep, the build just failed with those 😕 | 17:05:55 |