the Fink project is an effort to port
popular Unix programs to Mac OS X
Package: fpprofiler
Version: 20110108
Revision: 3
Description: Profiler for the FreePascal compiler
Architecture: powerpc, i386, x86_64
Source: http://michael-ep3.physik.uni-halle.de/fink-sources/%n-%v.tar.bz2
Source-MD5: f798933eecda64a4a7cb9e284c862e52
Depends: fpc
Recommends: graphviz, fpprofiler-cross
License: GPL
PatchScript: <<
#!/bin/sh -ev
sed -i.bak 's|FPCallGraph;|FPCallGraph; {$mode objfpc}{$H+}|g' fppview/fpcallgraph.pas
sed -i.bak 's|{$R \*\.res}||g' fpp/fppremove.pp
cd fcl-passrc/src/
patch pscanner.pp ../../patch/pscanner.diff
<<
CompileScript: <<
#!/bin/sh -ev
cd fcl-passrc
make
cd ../fpp
fpc -Fu../fpprof -Fu../fcl-passrc/units/* fpp.pp
fpc -Fu../fpprof -Fu../fcl-passrc/units/* fppinsert.pp
fpc -Fu../fpprof -Fu../fcl-passrc/units/* fppremove.pp
cd ../fppview
fpc -Fu../fpprof -Fu../fcl-passrc/units/* fppview.pp
<<
InfoTest: <<
TestScript: <<
#!/bin/sh -ev
cd test
# patch the sources
sed -i.bak 's|runtests;|runtests; {$mode objfpc}{$H+}|g' runtests.pp
sed -i.bak 's|Crt,|Crt|g' runtests.pp
sed -i.bak 's|FileUtil||g' runtests.pp
sed -i.bak "s|GetExeExt|''|g" runtests.pp
sed -i.bak "s|Readln;||g" runtests.pp
sed -i.bak "s|fpp |./fpp |g" runtests.pp
# compile the "master runner".
fpc runtests.pp
# copy fpp from where it has been built.
cp ../fpp/fpp .
# run the test.
./runtests >runtest.log
#
# Results for each test. All should be TRUE.
#
grep -i true runtest.log
<<
TestSuiteSize: small
<<
InstallScript: <<
#!/bin/sh -ev
FPC_VERSION=`fpc -iV`
mkdir -p %i/bin
install -m 755 fpp/fpp %i/bin/fpp
install -m 755 fpp/fppinsert %i/bin/fppinsert
install -m 755 fpp/fppremove %i/bin/fppremove
install -m 755 fppview/fppview %i/bin/fppview
mkdir -p %i/lib/fpc/$FPC_VERSION/units/%m-darwin
cp -r fpprof/*.ppu %i/lib/fpc/$FPC_VERSION/units/%m-darwin
cp -r fpprof/*.o %i/lib/fpc/$FPC_VERSION/units/%m-darwin
<<
DocFiles: docs/COPYING.GPL docs/develop.txt
DescDetail: <<
Compile your program by using fpp as a replacement of fpc.
This creates a profile file (Default: fpprof.xml),
from which fppview creates output. Output in the dot language
can be converted to a graph with the program "dot" from the
package "graphviz".
More details about options can be obtained with
fpp -h
and
fppview -h
Usage Example:
fpp MyProgram.pp
fppview --format=graphviz --stat=callgraph >MyProgram.dot
dot -Tpng MyProgram.dot -o MyProgram.png
open MyProgram.png
Please check also the home page: http://wiki.lazarus.freepascal.org/FPProfiler
<<
Homepage: http://wiki.lazarus.freepascal.org/FPProfiler
Maintainer: Karl-Michael Schindler