libpfm-vl.spec 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179
  1. %bcond_without python
  2. %if %{with python}
  3. %define python_sitearch %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")
  4. %define python_prefix %(python -c "import sys; print sys.prefix")
  5. %{?filter_setup:
  6. %filter_provides_in %{python_sitearch}/perfmon/.*\.so$
  7. %filter_setup
  8. }
  9. %endif
  10. Name: libpfm
  11. Version: 4.6.0
  12. Release: 1%{?_dist_release}
  13. Summary: Library to encode performance events for use by perf tool
  14. Summary(ja): プロファイラが用いるパフォーマンスイベントをエンコードするライブラリ
  15. Group: System Environment/Libraries
  16. License: MIT
  17. URL: http://perfmon2.sourceforge.net/
  18. Source0: http://sourceforge.net/projects/perfmon2/files/libpfm4/%{name}-%{version}.tar.gz
  19. %if %{with python}
  20. BuildRequires: python-devel
  21. BuildRequires: python-setuptools
  22. BuildRequires: swig
  23. %endif
  24. %description
  25. libpfm4 is a library to help encode events for use with operating system
  26. kernels performance monitoring interfaces. The current version provides support
  27. for the perf_events interface available in upstream Linux kernels since v2.6.31.
  28. %package devel
  29. Summary: Development library to encode performance events for perf_events based tools
  30. Summary(ja): パフォーマンスイベントをエンコードするための開発用ライブラリ
  31. Group: Development/Libraries
  32. Requires: %{name} = %{version}-%{release}
  33. %description devel
  34. Development library and header files to create performance monitoring
  35. applications for the perf_events interface.
  36. %package static
  37. Summary: Static library to encode performance events for perf_events based tools
  38. Summary(ja): パフォーマンスイベントをエンコードするための静的ライブラリ
  39. Group: Development/Libraries
  40. Requires: %{name}-devel = %{version}-%{release}
  41. %description static
  42. Static version of the libpfm library for performance monitoring
  43. applications for the perf_events interface.
  44. %if %{with python}
  45. %package python
  46. Summary: Python bindings for libpfm and perf_event_open system call
  47. Group: Development/Libraries
  48. Requires: %{name} = %{version}-%{release}
  49. %description python
  50. Python bindings for libpfm4 and perf_event_open system call.
  51. %endif
  52. %prep
  53. %setup -q
  54. %build
  55. %if %{with python}
  56. %global python_config CONFIG_PFMLIB_NOPYTHON=n
  57. %else
  58. %global python_config CONFIG_PFMLIB_NOPYTHON=y
  59. %endif
  60. make %{python_config} %{?_smp_mflags}
  61. %install
  62. rm -rf $RPM_BUILD_ROOT
  63. %if %{with python}
  64. %global python_config CONFIG_PFMLIB_NOPYTHON=n PYTHON_PREFIX=$RPM_BUILD_ROOT/%{python_prefix}
  65. %else
  66. %global python_config CONFIG_PFMLIB_NOPYTHON=y
  67. %endif
  68. make \
  69. PREFIX=$RPM_BUILD_ROOT%{_prefix} \
  70. LIBDIR=$RPM_BUILD_ROOT%{_libdir} \
  71. %{python_config} \
  72. LDCONFIG=/bin/true \
  73. install
  74. %clean
  75. rm -rf $RPM_BUILD_ROOT
  76. %post -p /sbin/ldconfig
  77. %postun -p /sbin/ldconfig
  78. %files
  79. %doc README
  80. %{_libdir}/lib*.so.*
  81. %files devel
  82. %{_includedir}/*
  83. %{_mandir}/man3/*
  84. %{_libdir}/lib*.so
  85. %files static
  86. %{_libdir}/lib*.a
  87. %if %{with python}
  88. %files python
  89. %{python_sitearch}/*
  90. %endif
  91. %changelog
  92. * Wed Mar 11 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 4.6.0-1
  93. - new upstream release
  94. * Fri Feb 6 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 4.5.0-6
  95. - initial build for Vine Linux
  96. * Sun Aug 17 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.5.0-5
  97. - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
  98. * Mon Jun 30 2014 Toshio Kuratomi <toshio@fedoraproject.org> - 4.5.0-4
  99. - Replace python-setuptools-devel BR with python-setuptools
  100. * Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.5.0-3
  101. - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
  102. * Fri May 23 2014 William Cohen <wcohen@redhat.com> 4.5.0-2
  103. - Add cortex a53 support.
  104. * Fri May 23 2014 William Cohen <wcohen@redhat.com> 4.5.0-1
  105. - Rebase on libpfm-4.5.0.
  106. * Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.4.0-3
  107. - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
  108. * Fri Jul 19 2013 William Cohen <wcohen@redhat.com> 4.4.0-2
  109. - Add IBM power 8 support.
  110. * Mon Jun 17 2013 William Cohen <wcohen@redhat.com> 4.4.0-1
  111. - Rebase on libpfm-4.4.0.
  112. * Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.3.0-3
  113. - Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
  114. * Tue Aug 28 2012 William Cohen <wcohen@redhat.com> 4.3.0-2
  115. - Turn off LDCONFIG and remove patch.
  116. * Tue Aug 28 2012 William Cohen <wcohen@redhat.com> 4.3.0-1
  117. - Rebase on libpfm-4.3.0.
  118. * Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.2.0-8
  119. - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
  120. * Fri Jun 8 2012 William Cohen <wcohen@redhat.com> 4.2.0-7
  121. - Eliminate swig error.
  122. * Thu Jun 7 2012 William Cohen <wcohen@redhat.com> 4.2.0-6
  123. - Eliminate rpm_build_root macro in build section.
  124. - Correct location of shared library files.
  125. * Thu Jun 7 2012 William Cohen <wcohen@redhat.com> 4.2.0-5
  126. - Use siginfo_t for some examples.
  127. * Mon Jun 4 2012 William Cohen <wcohen@redhat.com> 4.2.0-4
  128. - Correct python files.
  129. * Wed Mar 28 2012 William Cohen <wcohen@redhat.com> 4.2.0-3
  130. - Additional spec file fixup for rhbz804666.
  131. * Wed Mar 14 2012 William Cohen <wcohen@redhat.com> 4.2.0-2
  132. - Some spec file fixup.
  133. * Wed Jan 12 2011 Arun Sharma <asharma@fb.com> 4.2.0-0
  134. Initial revision