From df76c54fc251904c2eaf4cc9354ed8726336c289 Mon Sep 17 00:00:00 2001 From: Takashi Kokubun Date: Mon, 9 Jan 2023 16:45:11 -0800 Subject: Allow overriding a gdb command on `make gdb` With --enable-yjit, you see an annoying warning like this: warning: Missing auto-load script at offset 0 in section .debug_gdb_scripts of file /home/k0kubun/src/github.com/ruby/ruby/.ruby/miniruby. Use `info auto-load python-scripts [REGEXP]' to list them. Using `rust-gdb` instead fixes it. I use this like `make gdb GDB=rust-gdb`. --- common.mk | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'common.mk') diff --git a/common.mk b/common.mk index 39b3aec0a6..0d230dd70b 100644 --- a/common.mk +++ b/common.mk @@ -1321,9 +1321,10 @@ run.gdb: echo ' quit' >> run.gdb echo end >> run.gdb +GDB = gdb gdb: miniruby$(EXEEXT) run.gdb PHONY - gdb -x run.gdb --quiet --args $(MINIRUBY) $(RUNOPT0) $(TESTRUN_SCRIPT) $(RUNOPT) + $(GDB) -x run.gdb --quiet --args $(MINIRUBY) $(RUNOPT0) $(TESTRUN_SCRIPT) $(RUNOPT) gdb-ruby: $(PROGRAM) run.gdb PHONY $(Q) $(RUNRUBY_COMMAND) $(RUNRUBY_DEBUGGER) -- $(RUNOPT0) $(TESTRUN_SCRIPT) $(RUNOPT) -- cgit v1.2.3