Below is a (human-written) transcript of how to to get the Linux kernel building with `make defconfig`. It works on Claude's the development machine but I have not tested it on any other machine. cargo build --release wget https://cdn.kernel.org/pub/linux/kernel/v6.x/linux-6.9.tar.xz xz -d linux-6.9.tar.xz tar -xf linux-6.9.tar cd linux-6.9/ make ARCH=riscv CC=/workspace/code/target/release/ccc-riscv HOSTCC=/workspace/code/target/release/ccc-x86 CROSS_COMPILE=riscv64-linux-gnu- defconfig make ARCH=riscv CC=/workspace/code/target/release/ccc-riscv HOSTCC=/workspace/code/target/release/ccc-x86 CROSS_COMPILE=riscv64-linux-gnu- -j$(nproc) Image # 4. Create the init script cat > basic-init <<'EOF' #!/bin/busybox sh /bin/busybox mkdir -p /dev /etc /proc /sys /bin /sbin /usr/bin/games /usr/sbin /bin/busybox mount -t proc proc /proc /bin/busybox mount -t sysfs sys /sys /bin/busybox mount -t devtmpfs dev /dev /bin/busybox --install -s 2>/dev/null export TERM=linux export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/bin/games echo 1 > /proc/sys/kernel/printk sleep 0.2 exec /bin/busybox setsid /bin/busybox cttyhack /bin/sh EOF wget https://busybox.net/downloads/busybox-1.36.1.tar.bz2 tar xf busybox-1.36.1.tar.bz2 cd busybox-1.36.1 # Configure make ARCH=riscv CROSS_COMPILE=riscv64-linux-gnu- defconfig sed -i 's/# CONFIG_STATIC is not set/CONFIG_STATIC=y/' .config sed -i 's/CONFIG_TC=y/# CONFIG_TC is not set/' .config make ARCH=riscv CROSS_COMPILE=riscv64-linux-gnu- -j$(nproc) cd .. # 5. Create the initramfs list cat > initramfs.list <<'EOF' dir /dev 0755 0 0 nod /dev/console 0600 0 0 c 5 1 nod /dev/tty 0666 0 0 c 5 0 nod /dev/null 0666 0 0 c 1 3 dir /proc 0755 0 0 dir /sys 0755 0 0 dir /root 0700 0 0 dir /bin 0755 0 0 dir /sbin 0755 0 0 dir /usr 0755 0 0 dir /usr/bin 0755 0 0 dir /usr/bin/games 0755 0 0 file /init ./basic-init 0755 0 0 file /bin/busybox busybox-1.36.1/busybox 0755 0 0 EOF # 6. Generate the initramfs usr/gen_init_cpio initramfs.list | gzip -9 > initramfs.cpio.gz qemu-system-riscv64 -M virt -m 512 \ -kernel arch/riscv/boot/Image \ -initrd ./initramfs.cpio.gz \ -append "console=ttyS0" \ -nographic \ -no-reboot # dmesg | head -n 1 [ 0.000000] Linux version 6.9.0 (appuser@3e854e88ac71) (ccc (Claude's C Compiler, GCC-compatible) 14.2.0, GNU ld (GNU Binutils for Ubuntu) 2.42) #1 SMP Thu Feb 5 16:59:16 UTC 2026