-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathqemu-gdb
executable file
·30 lines (25 loc) · 933 Bytes
/
qemu-gdb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#!/bin/bash
#=================================================================================
# Copyright (C) Andrzej Adamczyk (at https://blackdev.org/). All rights reserved.
#=================================================================================
clear
# default CPUs amount: 2
SMP="${1}"
if [ -z "${SMP}" ]; then SMP="2"; fi
# default Memory size: 64 MiB
MEM="${2}"
if [ -z "${MEM}" ]; then MEM="64"; fi
qemu-system-x86_64 \
-S -s \
--enable-kvm \
-cpu max \
-smp ${SMP} \
-m ${MEM} \
-cdrom build/foton.iso \
-rtc base=localtime \
-audio driver=alsa,model=sb16,id=7 \
-serial stdio \
-usb \
-device usb-kbd,bus=usb-bus.0,port=1 \
-device usb-mouse,bus=usb-bus.0,port=2 &
../gf/gf2 -ex "target remote :1234" -ex "set disassembly-flavor intel" -ex "symbol-file build/kernel" -ex "c"