| 27 Apr 2025 |
@awwpotato:envs.net | https://nix.dev/ is best resource to start with | 19:00:32 |
Ilan Joselevich (Kranzes) | Not sure if it teaches flakes | 19:00:57 |
@curid:matrix.org | don't i need to learn what a function is first? | 19:00:58 |
Ilan Joselevich (Kranzes) | In reply to @curid:matrix.org don't i need to learn what a function is first? x: x + 1 | 19:01:25 |
@awwpotato:envs.net | it only mentions them | 19:01:45 |
Ilan Joselevich (Kranzes) | * (x: x + 1) 3 | 19:01:45 |
@curid:matrix.org | how would one find documentation for the pkgs.writeScriptBin function for example? | 19:04:31 |
Adam Neverwas | Learn whats documentation first | 19:05:27 |
@awwpotato:envs.net | https://nixos.org/manual/nixpkgs/unstable/#trivial-builder-writeScriptBin | 19:05:40 |
Ilan Joselevich (Kranzes) | https://noogle.dev | 19:07:00 |
| n8henrie joined the room. | 23:11:04 |
| 28 Apr 2025 |
| chvp left the room. | 14:30:22 |
| 29 Apr 2025 |
| @yaya:uwu.is left the room. | 11:21:45 |
| @federicodschonborn:matrix.org changed their display name from This LEGO® Worm™ is licensed under the terms of the he/him or they/them pronouns, at your choice to This legally distinct plastic brick is licensed under the terms of the he/him or they/them pronouns, at your choice. | 14:41:15 |
| @anjix:matrix.org joined the room. | 19:11:31 |
n8henrie | Didn't get any bites in the main channel --
I've been hoping to get this PR working for darwin -- a python / rust (via maturin / PyO3) project that I think just needs to enable the system feature of the libffi-sys crate (same fix as https://github.com/NixOS/nixpkgs/pull/368102).
Unfortunately in this case the libffi-sys crate is a few dependencies deep, and the parent packages don't expose any feature flags to enable libffi/system (which enables libffi-sys/system):
$ cargo tree -i libffi-sys
libffi-sys v3.2.0
├── deno_ffi v0.190.0
│ └── deno_runtime v0.211.0
│ └── vl-convert-rs v1.7.0 (/private/tmp/nix-build-python3.12-vl-convert-python-1.7.0.drv-0/source/vl-convert-rs)
│ ├── vl-convert v1.7.0 (/private/tmp/nix-build-python3.12-vl-convert-python-1.7.0.drv-0/source/vl-convert)
│ └── vl-convert-python v1.7.0 (/private/tmp/nix-build-python3.12-vl-convert-python-1.7.0.drv-0/source/vl-convert-python)
└── libffi v4.0.0
└── deno_ffi v0.190.0 (*)
Any suggestions for enabling this feature flag a few dependency layers deep?
| 19:41:12 |
Alyssa Ross | I think you can do it by setting it in the top level Cargo.toml | 19:42:59 |
@r522:matrix.org | if it's not exposed, you can take a dep on libffi-sys directly yourself, and set the feature there
(that's more fragile since you need to use the same version as exists in the dependency, ideally the dependencies would let you pass the system feature)
| 20:52:24 |
n8henrie | In reply to @qyliss:fairydust.space I think you can do it by setting it in the top level Cargo.toml I'll try, thanks! | 21:53:39 |
n8henrie | In reply to @r522:matrix.org
if it's not exposed, you can take a dep on libffi-sys directly yourself, and set the feature there
(that's more fragile since you need to use the same version as exists in the dependency, ideally the dependencies would let you pass the system feature)
Do you mean a nix dependency? Or in cargo.toml as suggested by Alyssa Ross? | 21:54:32 |
@r522:matrix.org | in cargo.toml, yeah | 21:54:58 |
| 30 Apr 2025 |
Randy Eckenrode | Can you modify the crate source in rustPlatform.fetchCargoVendor? | 00:26:52 |
Randy Eckenrode | * Can you modify the crate source in rustPlatform.fetchCargoVendor to enable the feature? | 00:26:59 |
n8henrie | In reply to @reckenrode:matrix.org Can you modify the crate source in rustPlatform.fetchCargoVendor? I tried tinkering around in the vendor directory but it made cargo in my nix-shell unhappy. I will try again, and see if I can find examples of this approach. | 01:02:08 |
| sheeldotme joined the room. | 14:20:07 |
| @saiko:knifepoint.net changed their profile picture. | 16:18:19 |
n8henrie | Alyssa Ross 522 Randy Eckenrode think I got it! Thanks for the pointers. https://github.com/NixOS/nixpkgs/pull/397233#issuecomment-2843354952 | 21:46:48 |
| 1 May 2025 |
Toma | https://github.com/NixOS/nixpkgs/pull/373541
Anyone have anything against this PR? | 00:25:44 |
| jaen joined the room. | 14:17:29 |
jaen | Hello, anybody knows if there's a way with Crane (or anything else, really, it's just what I started out with) to have two separate Crago projects, repos/dep and repos/app and have it somehow provide dep to app when doing cargo build without having to change it to a path dependency in Cargo.toml? I've seen something about registry injection in the docs, but it seems that only works for actual, hosted registries and I don't see a way to inject a dependency built separately that way. And so far haven't found anything promising other than that yet. I'm basically trying to see if I can develop two (or more) things side-by-side without forcing any of the projects to be aware of the other at Rust level (my nix setup is external to the projects), so I don't have to worry about accidentally sending some local changes upstream. | 14:17:58 |