]> git.pld-linux.org Git - packages/LeakTracer.git/blame - LeakTracer.spec
- fix behaviour on 64-bit platofrms.
[packages/LeakTracer.git] / LeakTracer.spec
CommitLineData
96e48a11
PS
1Summary: A tool for trace and analyze memory leaks in C++ programs
2Name: LeakTracer
3Version: 2.3
4Release: 1
5License: Public Domain
6Group: Applications
e23bdcbe 7Source0: http://www.andreasen.org/LeakTracer/LeakTracer.tar.gz
96e48a11
PS
8# Source0-md5: e1cf9d03c12a45d39f253e558d231438
9Patch0: %{name}-Makefile.patch
10URL: http://www.andreasen.org/LeakTracer/
11BuildRequires: sed >= 4.0
12Requires: gdb
13BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
14
15%description
16LeakTracer is a small tool for checking a C++ program for memory
17leaks. To use LeakTracer, run your program using the provided
18LeakCheck script. It uses the LD_PRELOAD feature to "overlay" some
19functions on top of your functions (no recompile needed). leak-anlyze
20uses gdb to print out the exact line where the memory was allocated
21and not freed - this of course means you have to free all dynamically
22allocated data. LeakTracer also overrides the global operator new and
23operator delete - this will give problems if you override them as
24well. LeakTracer traces only new/new[] and delete calls - it does not
25look at malloc/free/realloc.
26
27%prep
28%setup -q -n %{name}
29%patch0 -p1
30
31%build
32sed -i "s:SHLIB=.*:SHLIB=%{_libdir}/LeakTracer.so:" LeakCheck
33
34%{__make} \
35 CXX="%{__cxx}" \
dc4b537c 36 CXXFLAGS="%{rpmcxxflags} -nodefaultlibs"
96e48a11
PS
37
38%install
39rm -rf $RPM_BUILD_ROOT
40install -d $RPM_BUILD_ROOT{%{_bindir},%{_libdir}}
41
42install leak-analyze $RPM_BUILD_ROOT%{_bindir}
43install LeakCheck $RPM_BUILD_ROOT%{_bindir}
44install LeakTracer.so $RPM_BUILD_ROOT%{_libdir}
45
46%clean
47rm -rf $RPM_BUILD_ROOT
48
49%post -p /sbin/ldconfig
50%postun -p /sbin/ldconfig
51
52%files
53%defattr(644,root,root,755)
54%doc README
55%attr(755,root,root) %{_bindir}/*
56%attr(755,root,root) %{_libdir}/*.so
This page took 0.060754 seconds and 4 git commands to generate.