Created attachment 250737 [details] Use -Wno-format for zfs_module.c When compiling with -DEFI_DEBUG, stand/efi/boot1/zfs_module.c needs the same -Wno-format flag as ufs_module.c. Otherwise, /usr/src/stand/efi/boot1/zfs_module.c:155:22: error: format specifies type 'wchar_t *' (aka 'int *') but the argument has type 'CHAR16 *' (aka 'unsigned short *') [-Werror,-Wformat] 154 | DPRINTF("load: '%s' spa: '%s', devpath: %S\n", filepath, | ~~ 155 | spa->spa_name, text); | ^~~~ /usr/home/15/src/stand/efi/boot1/boot_module.h:37:45: note: expanded from macro 'DPRINTF' 37 | #define DPRINTF(fmt, args...) printf(fmt, ##args) | ~~~ ^~~~ 1 error generated. *** [zfs_module.o] Error code 1 Fix attached. The comment in stand/efi/boot1/Makefile says this is platform-dependent. I was cross-compiling aarch64 to riscv64.
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=cadc9c7db780877396da23f3683a8c69c9b1c01e commit cadc9c7db780877396da23f3683a8c69c9b1c01e Author: John F. Carr <jfc@mit.edu> AuthorDate: 2024-06-14 17:06:03 +0000 Commit: Warner Losh <imp@FreeBSD.org> CommitDate: 2024-06-14 17:11:05 +0000 boot/efi: Fix warning for non-standard formats when debugging Add -Wno-format for zfs_module and regroup. This fixes warnings when EFI_DEBUG is defined. PR: 279071 Reviewed-by: imp stand/efi/boot1/Makefile | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-)
Committed. It would make things go smoother in the future if you either (a) used git format-patch for the patches you submit, or (b) submitted this as a pull request. Generally, pull requests will land faster as they are more visible.
Do pull requests go to https://github.com/freebsd/freebsd-src?
(In reply to John F. Carr from comment #3) > Do pull requests go to https://github.com/freebsd/freebsd-src? Yes.