File google-perftools.spec of Package google-perftools
#
# spec file for package google-perftools (Version 0.98)
#
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
# needsrootforbuild
Name: google-perftools
Version: 0.98
Release: 1
Group: System/Libraries
License: BSD 3-Clause
Url: http://goog-perftools.sourceforge.net
Source0: %{name}-%{version}.tar.bz2
# Source1: google.m4
# Patch0: %{name}_fix_random_returns.patch
# Patch1: %{name}_fix_syscalls.patch
# Patch2: %{name}_build_on_s390.patch
# Patch3: %{name}_fix_string_compare.patch
Patch4: %{name}-fix_docdir.patch
# Patch5: %{name}_libunwind_for_x86-64.patch
# Patch6: %{name}_fix_memset_call_in_test_progs.patch
Patch7: %{name}-memcmp_from_string_h.patch
# Patch8: %{name}_stacktrace_env.patch
Patch9: %{name}-fix_dirent_header.patch
Patch10: %{name}-ppc_asm_stat_h.patch
BuildRequires: gcc-c++
# Can't use libunwind. See bnc#393927 and bnc#395623
%ifarch x86_64 ia64 ppc ppc64 s390 s390x
%define no_libunwind_on_64 "-DNO_TCMALLOC_SAMPLES"
%define no_libunwind_on_64_config "--enable-frame-pointers"
%else
%define no_libunwind_on_64 ""
%define no_libunwind_on_64_config ""
%endif
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Summary: Performance Tools for C++
%description
The google-perftools packages contain some utilities to improve and
analyze the performance of C++ programs. This includes an optimized
thread-caching malloc() and cpu and heap profiling utilities.
%package devel
License: BSD 3-Clause
Group: System/Libraries
Summary: Performance tools for C++
Requires: libstdc++-devel, google-perftools = %{version}
%description devel
The google-perftools-devel package contains static and debug libraries
and header files for developing applications that use the
google-perftools package.
%prep
%setup
#patch0 -p1
#patch1 -p1
#patch2 -p1
#patch3 -p1
%patch4 -p1
#patch5 -p1
#patch6 -p1
%patch7 -p1
#patch8 -p1
%patch9 -p1
%patch10 -p1
# install -d aclocal/
# install %{SOURCE1} aclocal/
# rm libtool
%build
autoreconf -fi
./configure CXXFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing %no_libunwind_on_64" \
CFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing %no_libunwind_on_64" \
--libdir=%_libdir \
--mandir=%_mandir \
--prefix=%_prefix \
--with-gnu-ld --with-pic %no_libunwind_on_64_config
make
%install
make DESTDIR=$RPM_BUILD_ROOT install
%clean
make DESTDIR=$RPM_BUILD_ROOT clean
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files
%defattr(-,root,root)
/usr/bin/pprof
%_libdir/libprofiler.so.0*
# %_libdir/libstacktrace.so.0* # libstacktrace.so got removed in 0.96
%_libdir/libtcmalloc.so.0*
%_libdir/libtcmalloc_minimal.so.0*
%_mandir/man1/pprof.1.gz
%dir %attr(775,root,root) /usr/share/doc/packages/%{name}
/usr/share/doc/packages/%{name}/AUTHORS
/usr/share/doc/packages/%{name}/COPYING
/usr/share/doc/packages/%{name}/ChangeLog
/usr/share/doc/packages/%{name}/INSTALL
/usr/share/doc/packages/%{name}/NEWS
/usr/share/doc/packages/%{name}/README
/usr/share/doc/packages/%{name}/TODO
/usr/share/doc/packages/%{name}/README.windows
/usr/share/doc/packages/%{name}/cpuprofile.html
/usr/share/doc/packages/%{name}/cpuprofile-fileformat.html
/usr/share/doc/packages/%{name}/designstyle.css
/usr/share/doc/packages/%{name}/heapprofile.html
/usr/share/doc/packages/%{name}/pprof_remote_servers.html
/usr/share/doc/packages/%{name}/heap-example1.png
/usr/share/doc/packages/%{name}/heap_checker.html
/usr/share/doc/packages/%{name}/index.html
/usr/share/doc/packages/%{name}/overview.dot
/usr/share/doc/packages/%{name}/overview.gif
/usr/share/doc/packages/%{name}/pageheap.dot
/usr/share/doc/packages/%{name}/pageheap.gif
/usr/share/doc/packages/%{name}/pprof-test-big.gif
/usr/share/doc/packages/%{name}/pprof-test.gif
/usr/share/doc/packages/%{name}/pprof-vsnprintf-big.gif
/usr/share/doc/packages/%{name}/pprof-vsnprintf.gif
/usr/share/doc/packages/%{name}/spanmap.dot
/usr/share/doc/packages/%{name}/spanmap.gif
/usr/share/doc/packages/%{name}/t-test1.times.txt
/usr/share/doc/packages/%{name}/tcmalloc-opspercpusec.vs.threads.1024.bytes.png
/usr/share/doc/packages/%{name}/tcmalloc-opspercpusec.vs.threads.128.bytes.png
/usr/share/doc/packages/%{name}/tcmalloc-opspercpusec.vs.threads.131072.bytes.png
/usr/share/doc/packages/%{name}/tcmalloc-opspercpusec.vs.threads.16384.bytes.png
/usr/share/doc/packages/%{name}/tcmalloc-opspercpusec.vs.threads.2048.bytes.png
/usr/share/doc/packages/%{name}/tcmalloc-opspercpusec.vs.threads.256.bytes.png
/usr/share/doc/packages/%{name}/tcmalloc-opspercpusec.vs.threads.32768.bytes.png
/usr/share/doc/packages/%{name}/tcmalloc-opspercpusec.vs.threads.4096.bytes.png
/usr/share/doc/packages/%{name}/tcmalloc-opspercpusec.vs.threads.512.bytes.png
/usr/share/doc/packages/%{name}/tcmalloc-opspercpusec.vs.threads.64.bytes.png
/usr/share/doc/packages/%{name}/tcmalloc-opspercpusec.vs.threads.65536.bytes.png
/usr/share/doc/packages/%{name}/tcmalloc-opspercpusec.vs.threads.8192.bytes.png
/usr/share/doc/packages/%{name}/tcmalloc-opspersec.vs.size.1.threads.png
/usr/share/doc/packages/%{name}/tcmalloc-opspersec.vs.size.12.threads.png
/usr/share/doc/packages/%{name}/tcmalloc-opspersec.vs.size.16.threads.png
/usr/share/doc/packages/%{name}/tcmalloc-opspersec.vs.size.2.threads.png
/usr/share/doc/packages/%{name}/tcmalloc-opspersec.vs.size.20.threads.png
/usr/share/doc/packages/%{name}/tcmalloc-opspersec.vs.size.3.threads.png
/usr/share/doc/packages/%{name}/tcmalloc-opspersec.vs.size.4.threads.png
/usr/share/doc/packages/%{name}/tcmalloc-opspersec.vs.size.5.threads.png
/usr/share/doc/packages/%{name}/tcmalloc-opspersec.vs.size.8.threads.png
/usr/share/doc/packages/%{name}/tcmalloc.html
/usr/share/doc/packages/%{name}/threadheap.dot
/usr/share/doc/packages/%{name}/threadheap.gif
%files devel
%defattr(-,root,root)
%dir %attr(775,root,root) /usr/include/google
/usr/include/google/heap-checker.h
/usr/include/google/heap-profiler.h
/usr/include/google/malloc_extension.h
/usr/include/google/malloc_hook.h
/usr/include/google/profiler.h
/usr/include/google/stacktrace.h
%_libdir/libprofiler.*a
%_libdir/libprofiler.so
# %_libdir/libstacktrace.*a # libstacktrace.so got removed in 0.96
# %_libdir/libstacktrace.so # libstacktrace.so got removed in 0.96
%_libdir/libtcmalloc.*a
%_libdir/libtcmalloc.so
%_libdir/libtcmalloc_minimal.*a
%_libdir/libtcmalloc_minimal.so
%changelog
* Fri Sep 19 2008 cgardner@suse.de
- Update to 0.98. Builds and runs only on ix86, x86_64 and ppc.
* Wed Oct 24 2007 cgardner@suse.de
- Fix memset calls in test programs for gcc 4.3
* Sun Jun 10 2007 schwab@suse.de
- Fix dependencies.
* Sat Jun 09 2007 cgardner@suse.de
- Fixed build for gcc 4.2 for x86_64.
* Wed Apr 18 2007 cgardner@suse.de
- Fixed build on s390 and s390x.
* Thu Apr 05 2007 cgardner@novell.com
- Bug#260744: Fix location of docs
* Mon Feb 26 2007 cgardner@suse.de
- Fixed errors regarding strcmp()
- Fixed warnings about strict-aliasing
- Fixed _syscallN() to build on x86_64 10.3
- Near Fix to sigcontext struct to build on s390{,x}
* Wed Feb 21 2007 cgardner@novell.com
- Initial submission of 0.8