[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Prompt presented to Google Gemini about compiling Rust in GNU/Hurd



Jose Luis Alarcon Sanchez, le lun. 27 oct. 2025 22:00:12 +0100, a ecrit:
> El lun, 27-10-2025 a las 19:13 +0100, Samuel Thibault escribió:
> > Jose Luis Alarcon Sanchez, le lun. 27 oct. 2025 18:30:14 +0100, a
> > ecrit:
> >
> > But possibly it's actually the bsd version that you want.
> 
> There's certainly a good chance you're right, Samuel, but the patch
> Gemini suggested is only applicable to matching Hurd to Unix. And
> although I've spent a while testing to try to make the code see Hurd as
> BSD and not Unix,

In my previous mails, I meant that it already *does*, see the actual
compilation output:

error[E0428]: the name `UserExtras` is defined multiple times
    --> /home/jose/.cargo/registry/src/index.crates.io-
1949cf8c6b5b557f/uzers-0.12.1/src/base.rs:1366:5
     |
1354 |     pub type UserExtras = bsd::UserExtras;
     |     -------------------------------------- previous definition
of the type `UserExtras` here
...
1366 |     pub type UserExtras = unix::UserExtras;
     |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ `UserExtras`
redefined here
     |
     = note: `UserExtras` must be defined only once in the type
namespace of this module

It's trying to compile both the bsd version and the Linux version.


But I'm not saying either that it's the BSD version that you want, I
don't know without actually doing the work of checking.

What Gemini *completely* misses is that first and foremost, you should
check that this is all about: the passwd C structure. And the corollary
is very simple: check the C headers to see if the hurd's version is like
the Linux version or the BSD version, and enable that part of the code.

Samuel


Reply to: