summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRegia König2022-04-11 14:01:56 +0200
committerRegia König2022-04-11 14:01:56 +0200
commit6d56ffea5c83cb6a5dd961f41d72831a47d73335 (patch)
tree1339923d5008af0738ad073548c0920c7637a551
parentasd (diff)
downloadmemtest86-6d56ffea5c83cb6a5dd961f41d72831a47d73335.tar.gz
memtest86-6d56ffea5c83cb6a5dd961f41d72831a47d73335.tar.xz
memtest86-6d56ffea5c83cb6a5dd961f41d72831a47d73335.zip
Add README about how to use gdb
-rw-r--r--efi_memtest/Makefile2
-rw-r--r--test_code/README17
2 files changed, 18 insertions, 1 deletions
diff --git a/efi_memtest/Makefile b/efi_memtest/Makefile
index 7447e2c..70c9ed1 100644
--- a/efi_memtest/Makefile
+++ b/efi_memtest/Makefile
@@ -89,7 +89,7 @@ LIBRARIES=MemtestEfi.lib
debug: CFLAGS += -g3
debug: CFLAGS += -fstack-usage # emit .su (stack usage) files for each c file you compile
debug: CFLAGS += -Wstack-usage=255
-debug: CFLAGS += -Werror
+#debug: CFLAGS += -Werror
debug: all
release: #CFLAGS += -flto
diff --git a/test_code/README b/test_code/README
new file mode 100644
index 0000000..048c893
--- /dev/null
+++ b/test_code/README
@@ -0,0 +1,17 @@
+https://retrage.github.io/2019/12/05/debugging-ovmf-en.html
+
+How to debug with gdb:
+
+1. make run
+
+2. ./gen_symbol_offets.sh > gdbscript
+
+3. make debug
+
+4. open second terminal. Type gdb
+
+5. In second terminal:
+ (gdb) source gdbscript
+ (gdb) b CoreHandleProtocol
+ (gdb) target remote localhost:1234
+ (gdb) c