prof and valgrind options added to Makefile
authorPatrik Gornicz <Gornicz.P@gmail.com>
Thu, 17 Jul 2008 02:45:37 +0000 (22:45 -0400)
committerPatrik Gornicz <Gornicz.P@gmail.com>
Thu, 17 Jul 2008 02:45:37 +0000 (22:45 -0400)
src/Makefile

index 1d89438..915e4ed 100644 (file)
@@ -56,7 +56,7 @@ depend: ${SRCS}
 
 .PHONY: clean
 clean:
-       rm -f ${OBJS} ${TARGET} *~
+       rm -f ${OBJS} ${TARGET} *~ prof gmon.out
 
 .PHONY: distclean
 distclean: clean
@@ -67,12 +67,21 @@ tags: ${SRCS}
        ctags $^
 
 tar: clean
-       cd ..; tar -cjf bluestar.tar.bz2 images/ source/
+       cd ..; tar -cjf physics.tar.bz2 src/
 
 
 .PHONY: run
 run: all
        ${TARGET}
 
-include ${DEPEND}
+.PHONY: val
+val: all
+       valgrind ${TARGET}
+
+.PHONY: prof
+prof: all
+       ${TARGET}
+       gprof -b ${TARGET} > prof
+       kprof -f prof
 
+include ${DEPEND}