projects
/
centaur.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
66665f1
)
Makefile: debug option - attach to running instance
author
norly
<ny-git@enpas.org>
Mon, 11 Feb 2013 01:08:31 +0000
(
01:08
+0000)
committer
norly
<ny-git@enpas.org>
Mon, 11 Feb 2013 01:24:36 +0000
(
01:24
+0000)
Makefile
patch
|
blob
|
history
diff --git
a/Makefile
b/Makefile
index df5f59fc4e95f672bdfc7ba4ca52ea4433d5b21f..726b92af7935ac51716def9c993676bf0b522457 100644
(file)
--- a/
Makefile
+++ b/
Makefile
@@
-21,6
+21,10
@@
LDFLAGS := -lelf
default: $(EXE)
+.PHONY: debug
+debug: $(EXE)
+ gdb $(EXE) $(shell ps -e | sed "s/^ *\([0-9]\+\) .*$(PROJ).*$$/\1/g;te;d;:e")
+
$(EXE): $(OBJS)
@if [ ! -d $(BUILDDIR) ] ; then echo "Error: Build dir '$(BUILDDIR)' does not exist." ; false ; fi