solo5
solo5 copied to clipboard
support FreeBSD14 in hvt
The API around VM_RUN changed. With this change, all tests pass. The first commit is to avoid the clang warning:
# cc -MT hvt/hvt_main.o -MMD -MP -MF hvt/hvt_main.Td -fstack-protector-strong -Wall -Werror -std=c11 -O2 -g -I/.opam/4.13.1/.opam-switch/build/solo5.0.8.0/include -c hvt/hvt_main.c -o hvt/hvt_main.o
# hvt/hvt_main.c:156:9: error: variable 'argc1' set but not used [-Werror,-Wunused-but-set-variable]
# int argc1 = argc;
# ^
# 1 error generated.
I'm still dubious whether shipping releases of solo5 with -Werror
is a good idea. IMHO it is nice for development, but since C compilers add new warnings in every release, it breaks the software.
FWIW, considering releases -- I'm still using the 0.7 series of solo5, and would appreciate a release in that series if possible. I have a branch (hannesm fork, FreeBSD14-0.7) that includes exactly these two patches, and it would be great to have them merged after review. If you could create a 0.7 branch (off of the v0.7.5 tag), I can open a separate PR.
The above patches make the tests pass on my FreeBSD 14. Maybe @sg2342 is up for a review of the latter commit (I'm not a seasoned C programmer, and may have forgot stuff that should be done) -- and he has FreeBSD knowledge?
Thanks @hannesm . I'm also in favor of removing
-Werror
(and dealing with every warning during the dev process).
I'd be in favour to add this to the release script, i.e. before/when building the tarball temporarily remove the -Werror
.
We probably should add a new CI for FreeBSD 14. At least, this PR looks correct for FreeBSD 12.
Ok, the FreeBSD 14 was added into the CI, thanks for your patch, we are ready to cut a release. However, it seems that we have an issue with grub2-bhyve
on FreeBSD14, the CI does an infinite loop. I will make an issue to track that but I decided to not test Solo5 virtio
on FreeBSD 14.