-
-
Save nathanchance/e331a237f855cf1db632466ba6967a19 to your computer and use it in GitHub Desktop.
BR2_aarch64=y | |
BR2_cortex_a57=y | |
BR2_OPTIMIZE_3=y | |
BR2_TOOLCHAIN_EXTERNAL=y | |
BR2_TARGET_GENERIC_ROOT_PASSWD="root" | |
BR2_TARGET_GENERIC_GETTY_PORT="ttyAMA0" | |
BR2_PACKAGE_BUSYBOX_SHOW_OTHERS=y | |
BR2_PACKAGE_BASH=y | |
BR2_PACKAGE_HTOP=y | |
BR2_PACKAGE_VIM=y | |
BR2_TARGET_ROOTFS_CPIO=y | |
# BR2_TARGET_ROOTFS_TAR is not set |
Why doesn't GitHub notify of gist comments...?
I actually never looked into it for buildroot because I wasn't able to find anything for debootstrap for x86. However, I just found this that I should try later: https://unix.stackexchange.com/questions/299408/how-to-login-automatically-without-typing-the-root-username-or-password-in-build
I think these defconfigs are the way to go, and would prefer having those to fetching Guenter's images. As in build the image immediately then boot it. What's the procedure for using these defconfigs in buildroot?
This is the document I was following for buildroot, as per our dynamic tools team:
https://github.com/google/syzkaller/blob/master/docs/linux/setup_linux-host_qemu-vm_arm64-kernel.md
Thanks for the link @nathanchance, that worked.
$ cd buildroot
$ mkdir -p overlays/etc/
$ cp output/target/etc/inittab overlays/etc/.
$ vim overlays/etc/inittab
-console::respawn:/sbin/getty -L console 0 vt100
+::respawn:-/bin/sh
$ make menuconfig
System configuration > Root filesystem overlay directories set to overlays
$ make
$ cd ~/linux
$ qemu-system-aarch64 -kernel arch/arm64/boot/Image.gz -machine virt -cpu cortex-a57 -m 2048 -append "console=ttyAMA0 root=/dev/vda" -nographic -hda ~/buildroot/output/images/rootfs.ext2 -no-reboot
$ make savedefconfig
doesn't create a defconfig
file for me, though. Am I holding it wrong? 🐈
Am I holding it wrong?
[Yes] 🌵
$ make savedefconfig BR2_DEFCONFIG=path/to/save/defconfig
Is there any way to remove the root password? I was getting stuck trying to make an image that would log in automatically. Guenter Roeck's rootfs images boot without a password, but I'm not sure how to control that in Linux.