Closed Lzzzzzt closed 3 months ago
It seems test failed for i686 and aarch64...
the problem in aarch64 may fixed, but the i686's i don't know why this would happen, maybe disable the statx in i686?
the error happen due to the cross's bug, i have test in newest cross version, it works fine.
and the run.sh is
#!/bin/bash
# Define the list of architectures to test
architectures=(
"x86_64-unknown-linux-gnu"
"i686-unknown-linux-gnu"
"aarch64-unknown-linux-gnu"
"armv7-unknown-linux-gnueabihf"
"riscv64gc-unknown-linux-gnu"
"s390x-unknown-linux-gnu"
"x86_64-apple-darwin"
"aarch64-apple-darwin"
)
# Loop through each architecture and run the tests
for arch in "${architectures[@]}"; do
cross test --lib --bins --tests --target "$arch" --no-default-features --features "async-cancel,bytes,legacy,macros,utils" > /dev/null 2>&1
if [ $? -eq 0 ]; then
echo "Success for $arch"
else
echo "Failure for $arch"
fi
done
the failure of riscv is #1423
Add
statx
support for monoioAdd
Statx<T>
struct to support Op, just implement forSharedFd
andCString
to support different use cases.So there are two types:
FdStatx
andPathStatx
, both of them are implementOpAble
Trait.Currently, they can work on linux with
iouring
andlegacy
feature, and not support macos and windows, due to these two platforms don't have thestatx
syscall, it may use thestat
syscall and transform the result to thestatx
Also, to test the
Statx<T>
work correctly, I add some new struct to fs module likeMetadata
,Permissions
andFileType
.There is another reason to add these struct, I can't transform the
statx
struct to theMetadata
and other types instd::fs
.So these struct provide nearly the same API like
std::fs
'sI also add some basic test in tests dir.
Currently, all these changes above only work on linux