fix(makefile): Enhance run-gui with explicit std VGA and add run-vnc target for headless/remote display

This commit is contained in:
subhobhai943 committed 2026-08-21 02:56:53 +05:30
1 parent 109472816c
commit 81a17aae37
1 file changed
+14 -3
+14 -3
View File
@@ -405,11 +405,22 @@ run-gui: $(TARGET)
ifeq ($(ARCH), x86_64)
qemu-system-x86_64 -drive format=raw,file=$(IMAGE) \
-netdev user,id=net0,hostfwd=tcp::2222-:22,hostfwd=tcp::8080-:80 \
-device e1000,netdev=net0 -serial stdio
-device e1000,netdev=net0 -vga std -serial stdio
else ifneq ($(filter $(ARCH), aarch64 arm64),)
qemu-system-aarch64 -M virt -cpu cortex-a57 -m 128M -kernel $(BUILD_DIR)/kernel.elf -serial stdio
qemu-system-aarch64 -M virt -cpu cortex-a57 -m 128M -kernel $(BUILD_DIR)/kernel.elf -device virtio-gpu-pci -serial stdio
else
qemu-system-arm -M virt -cpu cortex-a15 -m 128M -kernel $(BUILD_DIR)/kernel.elf -serial stdio
qemu-system-arm -M virt -cpu cortex-a15 -m 128M -kernel $(BUILD_DIR)/kernel.elf -device virtio-gpu-pci -serial stdio
endif
run-vnc: $(TARGET)
ifeq ($(ARCH), x86_64)
@echo "=== [QEMU VNC Server running at localhost:5900 (VNC Display :0)] ==="
qemu-system-x86_64 -drive format=raw,file=$(IMAGE) \
-netdev user,id=net0,hostfwd=tcp::2222-:22,hostfwd=tcp::8080-:80 \
-device e1000,netdev=net0 -vga std -vnc :0 -serial stdio
else
@echo "=== [QEMU VNC Server running at localhost:5900 (VNC Display :0)] ==="
qemu-system-aarch64 -M virt -cpu cortex-a57 -m 128M -kernel $(BUILD_DIR)/kernel.elf -device virtio-gpu-pci -vnc :0 -serial stdio
endif
run-server: $(IMAGE)