tarka / xcp

An extended `cp`
GNU General Public License v3.0
746 stars 24 forks source link

0.14.0: error[E0308]: mismatched types #40

Closed yurivict closed 11 months ago

yurivict commented 11 months ago

Build fails:

error[E0308]: mismatched types
   --> libfs/src/common.rs:193:37         
    |     
193 |     mknodat(CWD, dest, ftype, mode, dev)?;
    |     -------                         ^^^ expected `u32`, found `u64`
    |     |
    |     arguments to this function are incorrect
    |
note: function defined here
   --> /wrkdirs/usr/ports/sysutils/xcp/work/xcp-0.14.0/cargo-crates/rustix-0.38.26/src/fs/at.rs:438:8
    | 
438 | pub fn mknodat<P: path::Arg, Fd: AsFd>(
    |        ^^^^^^^
help: you can convert a `u64` to a `u32` and panic if the converted value doesn't fit
    |
193 |     mknodat(CWD, dest, ftype, mode, dev.try_into().unwrap())?;
    |                                        ++++++++++++++++++++

rust-1.73.0 FreeBSD 13.2

tarka commented 11 months ago

v0.15.0 should fix this. However there is a failing test with FreeBSD ATM, I'll take a look at it.

tarka commented 11 months ago

OK, it looks like FreeBSD doesn't really support copying sockets for users which is why the tests are failing. I'll tweak that in a future release.

I really need to setup CI for FreeBSD, any suggestions for who supports it?

tarka commented 11 months ago

0.15.2 is out; xcp will now just warn about sockets on *BSD.

yurivict commented 11 months ago

@tarka

I really need to setup CI for FreeBSD, any suggestions for who supports it?

Cirrus CI supports FreeBSD: https://cirrus-ci.org/guide/FreeBSD/

GitHub CI in FreeBSD: https://github.com/marketplace/actions/freebsd-vm

Example: https://github.com/jcelerier/libremidi/actions/runs/5649349837/