summaryrefslogtreecommitdiff
path: root/Makefile.SH
diff options
context:
space:
mode:
authorJarkko Hietaniemi <jhi@iki.fi>2001-07-13 22:48:47 +0000
committerJarkko Hietaniemi <jhi@iki.fi>2001-07-13 22:48:47 +0000
commit51a35ef15409e6e7977aa76e82c32623afd8b3ae (patch)
tree8b1e41b482a9243300019a90b6cb14ead4049068 /Makefile.SH
parent6391fff28eaddf20fd92139d36a56795a3e7f59d (diff)
downloadperl-51a35ef15409e6e7977aa76e82c32623afd8b3ae.tar.gz
Add information about gcc 3.0 basic block profiling.
p4raw-id: //depot/perl@11366
Diffstat (limited to 'Makefile.SH')
-rw-r--r--Makefile.SH21
1 files changed, 19 insertions, 2 deletions
diff --git a/Makefile.SH b/Makefile.SH
index 80bcc3405d..2df7ac8c6d 100644
--- a/Makefile.SH
+++ b/Makefile.SH
@@ -504,7 +504,7 @@ miniperl: $& miniperlmain$(OBJ_EXT) $(LIBPERL) opmini$(OBJ_EXT)
perl: $& perlmain$(OBJ_EXT) $(LIBPERL) $(DYNALOADER) $(static_ext) ext.libs $(PERLEXPORT)
-@rm -f miniperl.xok
- $(SHRPENV) $(LDLIBPTH) $(CC) -o perl$(PERL_SUFFIX) $(PERL_PROFILING) $(CLDFLAGS) $(CCDLFLAGS) perlmain$(OBJ_EXT) $(DYNALOADER) $(static_ext) $(LLIBPERL) `cat ext.libs` $(libs)
+ $(SHRPENV) $(LDLIBPTH) $(CC) -o perl$(PERL_SUFFIX) $(PERL_PROFILE_LDFLAGS) $(CLDFLAGS) $(CCDLFLAGS) perlmain$(OBJ_EXT) $(DYNALOADER) $(static_ext) $(LLIBPERL) `cat ext.libs` $(libs)
# Purify/Quantify Perls.
@@ -568,9 +568,26 @@ perl.gprof.config: config.sh
perl.gprof: /usr/bin/gprof perl.gprof.config
@-rm -f perl
- $(MAKE) PERL_SUFFIX=.gprof PERL_PROFILING=-pg perl
+ $(MAKE) PERL_SUFFIX=.gprof PERL_PROFILE_LDFLAGS=-pg perl
@echo "Now you may run perl.gprof and then run gprof perl.gprof."
+# Gcov Perl
+
+perl.config.gcov:
+ @echo "To build perl.gcov you must use gcc 3.0 or newer, checking..."
+ @echo "Checking gccversion in config.sh..."
+ @grep "^gccversion=" config.sh
+ @grep "^gccversion='[3-9]\." config.sh >/dev/null || exit 1
+ @echo "To build perl.gcov you must Configure -Dccflags=-fprofile-arcs -ftest-coverage, checking..."
+ @echo "Checking ccflags='-fprofile-arcs -ftest-coverage' in config.sh..."
+ @grep "^ccflags=" config.sh
+ @grep "^ccflags='.*-fprofile-arcs -ftest-coverage.*'" config.sh >/dev/null || exit 1
+
+perl.gcov: perl.config.gcov
+ @-rm -f perl
+ $(MAKE) PERL_SUFFIX=.gcov PERL_PROFILE_LDFLAGS='' perl
+ @echo "Now you may run perl.gcov and then run gcov some.c."
+
# Microperl. This is just a convenience thing if one happens to
# build also the full Perl and therefore the real big Makefile:
# usually one should manually explicitly issue the below command.