rpm.spec 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. %define RELEASE 1
  2. %define rel %{?CUSTOM_RELEASE} %{!?CUSTOM_RELEASE:%RELEASE}
  3. %define prefix /usr
  4. Name: %NAME
  5. Summary: Performance tools for C++
  6. Version: %VERSION
  7. Release: %rel
  8. Group: Development/Libraries
  9. URL: http://code.google.com/p/gperftools/
  10. License: BSD
  11. Vendor: gperftools Contributors
  12. Packager: gperftools Contributors <[email protected]>
  13. Source: http://%{NAME}.googlecode.com/files/%{NAME}-%{VERSION}.tar.gz
  14. Distribution: Redhat 7 and above.
  15. Buildroot: %{_tmppath}/%{name}-root
  16. Prefix: %prefix
  17. %description
  18. The %name packages contains some utilities to improve and analyze the
  19. performance of C++ programs. This includes an optimized thread-caching
  20. malloc() and cpu and heap profiling utilities.
  21. %package devel
  22. Summary: Performance tools for C++
  23. Group: Development/Libraries
  24. Requires: %{NAME} = %{VERSION}
  25. %description devel
  26. The %name-devel package contains static and debug libraries and header
  27. files for developing applications that use the %name package.
  28. %changelog
  29. * Mon Apr 20 2009 <[email protected]>
  30. - Change build rule to use a configure line more like '%configure'
  31. - Change install to use DESTDIR instead of prefix for configure
  32. - Use wildcards for doc/ and lib/ directories
  33. * Fri Mar 11 2005 <[email protected]>
  34. - First draft
  35. %prep
  36. %setup
  37. %build
  38. # I can't use '% configure', because it defines -m32 which breaks some
  39. # of the low-level atomicops files in this package. But I do take
  40. # as much from % configure (in /usr/lib/rpm/macros) as I can.
  41. ./configure --prefix=%{_prefix} --exec-prefix=%{_exec_prefix} --bindir=%{_bindir} --sbindir=%{_sbindir} --sysconfdir=%{_sysconfdir} --datadir=%{_datadir} --includedir=%{_includedir} --libdir=%{_libdir} --libexecdir=%{_libexecdir} --localstatedir=%{_localstatedir} --sharedstatedir=%{_sharedstatedir} --mandir=%{_mandir} --infodir=%{_infodir}
  42. make
  43. %install
  44. rm -rf $RPM_BUILD_ROOT
  45. make DESTDIR=$RPM_BUILD_ROOT install
  46. %clean
  47. rm -rf $RPM_BUILD_ROOT
  48. %files
  49. %defattr(-,root,root)
  50. %docdir %{prefix}/share/doc/%{NAME}-%{VERSION}
  51. %{prefix}/share/doc/%{NAME}-%{VERSION}/*
  52. %{_libdir}/*.so.*
  53. %{_bindir}/pprof
  54. %{_mandir}/man1/pprof.1*
  55. %files devel
  56. %defattr(-,root,root)
  57. %{_includedir}/google
  58. %{_includedir}/gperftools
  59. %{_libdir}/*.a
  60. %{_libdir}/*.la
  61. %{_libdir}/*.so
  62. %{_libdir}/pkgconfig/*.pc