Failure to build with LLVM for the Wii

Christophe Leroy (CS GROUP) chleroy at kernel.org
Thu Jan 29 22:11:12 AEDT 2026



Le 29/01/2026 à 11:55, Link Mauve a écrit :
> [Vous ne recevez pas souvent de courriers de linkmauve at linkmauve.fr. Découvrez pourquoi ceci est important à https://aka.ms/LearnAboutSenderIdentification ]
> 
> Hi,
> 
> I’m trying to build the kernel for the Nintendo Wii, using LLVM instead
> of gcc, in order to bring Rust support to this architecture (and also
> because my distribution doesn’t ship a cross-compiling gcc), but I get
> this build issue near the end:
> ```
> % make O=wii LLVM=1 ARCH=powerpc -j1
> make[1]: Entering directory '/home/linkmauve/dev/linux/wii'
>    GEN     Makefile
>    CALL    ../scripts/checksyscalls.sh
>    DESCEND objtool
>    INSTALL libsubcmd_headers
>    WRAP    arch/powerpc/boot/dtbImage.wii
> objcopy: Unable to recognise the format of the input file `vmlinux'
> make[3]: *** [../arch/powerpc/boot/Makefile:394: arch/powerpc/boot/dtbImage.wii] Error 1
> make[2]: *** [../arch/powerpc/Makefile:236: zImage] Error 2
> make[1]: *** [/home/linkmauve/dev/linux/Makefile:248: __sub-make] Error 2
> make[1]: Leaving directory '/home/linkmauve/dev/linux/wii'
> make: *** [Makefile:248: __sub-make] Error 2
> ```
> 
> I believe it should use $(OBJCOPY) instead of objcopy, which is set to
> llvm-objcopy, but couldn’t figure out where it is misconfigured.

Must be here I guess:

arch/powerpc/boot/wrapper:${CROSS}objcopy $objflags "$kernel" "$vmz.$$"
arch/powerpc/boot/wrapper:    ${CROSS}objcopy $4 $1 \
arch/powerpc/boot/wrapper:    ${CROSS}objcopy -O binary "$ofile".elf 
"$ofile"
arch/powerpc/boot/wrapper:    ${CROSS}objcopy -O aixcoff-rs6000 
--set-start "$entry" "$ofile"
arch/powerpc/boot/wrapper:    ${CROSS}objcopy -O binary "$ofile" 
"$ofile.bin"



More information about the Linuxppc-dev mailing list