Blame SPECS/papi.spec

dfaf77
%bcond_with bundled_libpfm
dfaf77
Summary: Performance Application Programming Interface
dfaf77
Name: papi
dfaf77
Version: 5.2.0
dfaf77
Release: 26%{?dist}
dfaf77
License: BSD
dfaf77
Group: Development/System
dfaf77
URL: http://icl.cs.utk.edu/papi/
dfaf77
Source0: http://icl.cs.utk.edu/projects/papi/downloads/%{name}-%{version}.tar.gz
dfaf77
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
dfaf77
Patch100: papi-intel.patch
dfaf77
Patch200: papi-aarch64.patch
dfaf77
Patch201: papi-xgene.patch
dfaf77
Patch300: papi-coverity.patch
dfaf77
Patch400: papi-hsw_ep.patch
dfaf77
Patch401: papi-kvmrapl.patch
dfaf77
Patch500: papi-sys_mem_info.patch
dfaf77
Patch700: papi-krentel.patch
dfaf77
Patch900: papi-inficonst.patch
dfaf77
Patch1000: papi-bz1263666.patch
dfaf77
Patch1001: papi-bz1326977.patch
dfaf77
Patch1002: papi-bz1277931.patch
dfaf77
Patch1003: papi-bz1313088.patch
dfaf77
Patch1004: papi-postfixcalc.patch
dfaf77
Patch1005: papi-errmsg.patch
dfaf77
Patch1006: papi-schedule.patch
dfaf77
Patch1010: papi-rhbz1362591.patch
dfaf77
Patch1011: papi-ppc64_cache.patch
dfaf77
Patch1012: papi-intel_knl.patch
dfaf77
Patch2000: papi-avoid_libpfm_enum.patch
dfaf77
Patch2001: papi-power9.patch
dfaf77
Patch2002: papi-p9_presets.patch
dfaf77
Patch2003: papi-lmsensors.patch
dfaf77
Patch2004: papi-powernv.patch
dfaf77
BuildRequires: autoconf
dfaf77
BuildRequires: doxygen
dfaf77
BuildRequires: ncurses-devel
dfaf77
BuildRequires: gcc-gfortran
dfaf77
BuildRequires: kernel-headers >= 2.6.32
dfaf77
BuildRequires: chrpath
dfaf77
BuildRequires: lm_sensors-devel
dfaf77
%if %{without bundled_libpfm}
dfaf77
BuildRequires: libpfm-devel >= 4.4.0-9
dfaf77
BuildRequires: libpfm-static >= 4.4.0-9
dfaf77
%endif
dfaf77
# Following required for net component
dfaf77
BuildRequires: net-tools
dfaf77
# Following required for inifiband component
dfaf77
BuildRequires: libibmad-devel
dfaf77
#Right now libpfm does not know anything about s390 and will fail
dfaf77
ExcludeArch: s390 s390x
dfaf77
dfaf77
%description
dfaf77
PAPI provides a programmer interface to monitor the performance of
dfaf77
running programs.
dfaf77
dfaf77
%package devel
dfaf77
Summary: Header files for the compiling programs with PAPI
dfaf77
Group: Development/System
dfaf77
Requires: papi = %{version}-%{release}
dfaf77
%description devel
dfaf77
PAPI-devel includes the C header files that specify the PAPI user-space
dfaf77
libraries and interfaces. This is required for rebuilding any program
dfaf77
that uses PAPI.
dfaf77
dfaf77
%package testsuite
dfaf77
Summary: Set of tests for checking PAPI functionality
dfaf77
Group: Development/System
dfaf77
Requires: papi = %{version}-%{release}
dfaf77
%description testsuite
dfaf77
PAPI-testuiste includes compiled versions of papi tests to ensure
dfaf77
that PAPI functions on particular hardware.
dfaf77
dfaf77
%package static
dfaf77
Summary: Static libraries for the compiling programs with PAPI
dfaf77
Group: Development/System
dfaf77
Requires: papi = %{version}-%{release}
dfaf77
%description static
dfaf77
PAPI-static includes the static versions of the library files for
dfaf77
the PAPI user-space libraries and interfaces.
dfaf77
dfaf77
%prep
dfaf77
%setup -q
dfaf77
%patch100 -p1
dfaf77
%patch200 -p1
dfaf77
%patch201 -p1
dfaf77
%patch300 -p1
dfaf77
%patch400 -p1
dfaf77
%patch401 -p1
dfaf77
%patch500 -p1
dfaf77
%patch700 -p1
dfaf77
%patch900 -p1
dfaf77
%patch1000 -p1
dfaf77
%patch1001 -p1
dfaf77
%patch1002 -p1
dfaf77
%patch1003 -p1
dfaf77
%patch1004 -p1
dfaf77
%patch1005 -p1
dfaf77
%patch1006 -p1
dfaf77
%patch1010 -p1 -b .rhbz1362591
dfaf77
%patch1011 -p1 -b .ppc64cache
dfaf77
%patch1012 -p1 -b .knl
dfaf77
%patch2000 -p1 -b .max
dfaf77
%patch2001 -p1 -b .power9
dfaf77
%patch2002 -p1 -b .power9a
dfaf77
%patch2003 -p1 -b .lm_dyn
dfaf77
%patch2004 -p1 -b .powernv
dfaf77
dfaf77
%build
dfaf77
%if %{without bundled_libpfm}
dfaf77
# Build our own copy of libpfm.
dfaf77
%global libpfm_config --with-pfm-incdir=%{_includedir} --with-pfm-libdir=%{_libdir}
dfaf77
%endif
dfaf77
dfaf77
cd src
dfaf77
autoconf
dfaf77
%configure --with-perf-events \
dfaf77
%{?libpfm_config} \
dfaf77
--with-static-lib=yes --with-shared-lib=yes --with-shlib \
dfaf77
--with-components="appio coretemp example lmsensors lustre micpower mx net rapl stealtime"
dfaf77
# implicit enabled components: perf_event perf_event_uncore
dfaf77
#components currently left out because of build configure/build issues
dfaf77
# --with-components="bgpm coretemp_freebsd cuda host_micpower nvml vmware"
dfaf77
dfaf77
pushd components
dfaf77
#pushd cuda; ./configure; popd
dfaf77
#pushd host_micpower; ./configure; popd
dfaf77
#pushd infiniband; ./configure; popd
dfaf77
pushd lmsensors; \
dfaf77
 %configure --with-sensors_incdir=/usr/include/sensors \
dfaf77
 --with-sensors_libdir=%{_libdir}; \
dfaf77
 popd
dfaf77
#pushd vmware; ./configure; popd
dfaf77
popd
dfaf77
dfaf77
#DBG workaround to make sure libpfm just uses the normal CFLAGS
dfaf77
DBG="" make %{?_smp_mflags}
dfaf77
dfaf77
#generate updated versions of the documentation
dfaf77
#DBG workaround to make sure libpfm just uses the normal CFLAGS
dfaf77
pushd ../doc
dfaf77
DBG="" make
dfaf77
DBG="" make install
dfaf77
popd
dfaf77
dfaf77
%install
dfaf77
rm -rf $RPM_BUILD_ROOT
dfaf77
cd src
dfaf77
make DESTDIR=$RPM_BUILD_ROOT LDCONFIG=/bin/true install-all
dfaf77
dfaf77
chrpath --delete $RPM_BUILD_ROOT%{_libdir}/*.so*
dfaf77
dfaf77
%post -p /sbin/ldconfig
dfaf77
%postun -p /sbin/ldconfig
dfaf77
%clean
dfaf77
rm -rf $RPM_BUILD_ROOT
dfaf77
dfaf77
%files
dfaf77
%defattr(-,root,root,-)
dfaf77
%{_bindir}/*
dfaf77
%{_libdir}/*.so.*
dfaf77
%dir /usr/share/papi
dfaf77
/usr/share/papi/papi_events.csv
dfaf77
%doc INSTALL.txt README LICENSE.txt RELEASENOTES.txt
dfaf77
%doc %{_mandir}/man1/*
dfaf77
dfaf77
%files devel
dfaf77
%defattr(-,root,root,-)
dfaf77
%{_includedir}/*.h
dfaf77
%if %{with bundled_libpfm}
dfaf77
%{_includedir}/perfmon/*.h
dfaf77
%endif
dfaf77
%{_libdir}/*.so
dfaf77
%doc %{_mandir}/man3/*
dfaf77
dfaf77
%files testsuite
dfaf77
%defattr(-,root,root,-)
dfaf77
/usr/share/papi/run_tests*
dfaf77
/usr/share/papi/ctests
dfaf77
/usr/share/papi/ftests
dfaf77
/usr/share/papi/components
dfaf77
/usr/share/papi/testlib
dfaf77
dfaf77
%files static
dfaf77
%defattr(-,root,root,-)
dfaf77
%{_libdir}/*.a
dfaf77
dfaf77
%changelog
dfaf77
* Tue Jan 30 2018 William Cohen <wcohen@redhat.com> - 5.2.0-26
dfaf77
- Recognize IBM PowerNV processors.
dfaf77
dfaf77
* Thu Nov 30 2017 William Cohen <wcohen@redhat.com> - 5.2.0-25
dfaf77
- Update IBM Power 9 events. rhbz1510684
dfaf77
- Make lmsensor dynamically size internal array. rhbz1510497
dfaf77
dfaf77
* Fri Jun 23 2017 William Cohen <wcohen@redhat.com> - 5.2.0-24
dfaf77
- Add power9 support. rhbz1368708
dfaf77
dfaf77
* Fri Jun 9 2017 William Cohen <wcohen@redhat.com> - 5.2.0-23
dfaf77
- Avoid using PFM_PMU_MAX.
dfaf77
dfaf77
* Wed Apr 26 2017 William Cohen <wcohen@redhat.com> - 5.2.0-22
dfaf77
- Disable infiniband component. rhbz1445777
dfaf77
dfaf77
* Wed Mar 22 2017 William Cohen <wcohen@redhat.com> - 5.2.0-21
dfaf77
- Correct ppc64 events. rhbz1385008
dfaf77
- Add events for Intel KNL. rhbz1412952
dfaf77
dfaf77
* Tue Mar 21 2017 William Cohen <wcohen@redhat.com> - 5.2.0-20
dfaf77
- Dynamically link the papi ctests. rhbz1362591
dfaf77
dfaf77
* Tue Aug 2 2016 William Cohen <wcohen@redhat.com> - 5.2.0-19
dfaf77
- Rebuild with libpfm-4.7.0.
dfaf77
dfaf77
* Wed Jul 27 2016 William Cohen <wcohen@redhat.com> - 5.2.0-18
dfaf77
- Check schedulability on aarch64.
dfaf77
dfaf77
* Tue Jul 26 2016 William Cohen <wcohen@redhat.com> - 5.2.0-17
dfaf77
- Eliminate possible stack smashing.
dfaf77
dfaf77
* Tue Jun 21 2016 William Cohen <wcohen@redhat.com> - 5.2.0-16
dfaf77
- Correct ftests/tenth test behavior on power. rhbz1313088
dfaf77
dfaf77
* Thu May 12 2016 William Cohen <wcohen@redhat.com> - 5.2.0-15
dfaf77
- Update papi L1 cache events on POWER7
dfaf77
- Prevent papi-testsuite segfaults
dfaf77
- Identify kernels that support rdpmc
dfaf77
- Correct papi-testsuite byte_profile and sprofile tests on ppc64le
dfaf77
- Update PAPI_L1_TCM event on Haswells
dfaf77
dfaf77
* Mon Aug 10 2015 William Cohen <wcohen@redhat.com> - 5.2.0-14
dfaf77
- Fix build for newer infiband libs. rhbz1251645
dfaf77
dfaf77
* Mon Jun 29 2015 William Cohen <wcohen@redhat.com> - 5.2.0-13
dfaf77
- Bump and rebuild.
dfaf77
dfaf77
* Fri Jun 26 2015 William Cohen <wcohen@redhat.com> - 5.2.0-12
dfaf77
- Improved check that rapl is supported. rhbz1228832
dfaf77
dfaf77
* Thu Jun 4 2015 William Cohen <wcohen@redhat.com> - 5.2.0-11
dfaf77
- Correct krentel test. rhbz1191199
dfaf77
dfaf77
* Thu Oct 16 2014 William Cohen <wcohen@redhat.com> - 5.2.0-10
dfaf77
- Bump and rebuid for chained build. rhbz1126091
dfaf77
dfaf77
* Wed Oct 15 2014 Frank Ch. Eigler <fche@redhat.com> - 5.2.0-9
dfaf77
- Make sys_mem_info size dynamic. Related rhbz1152641.
dfaf77
dfaf77
* Tue Oct 14 2014 William Cohen <wcohen@redhat.com> - 5.2.0-8
dfaf77
- Recognize hsw_ep from libpfm. Related rhbz1126090
dfaf77
dfaf77
* Thu Sep 25 2014 William Cohen <wcohen@redhat.com> - 5.2.0-7
dfaf77
- Update papi presets for Intel processors. Resolves rhbz1126090 
dfaf77
- Eliminate some errors found by coverity. Releated rhbz1057778
dfaf77
dfaf77
* Thu Sep 4 2014 William Cohen <wcohen@redhat.com> - 5.2.0-6
dfaf77
- Add ARM aarch64 (APM X-Gene and Cortex A57)  support.  Resolves rhbz963458.
dfaf77
dfaf77
* Tue Jan 14 2014 William Cohen <wcohen@redhat.com> - 5.2.0-5
dfaf77
- Add presets for Intel Silvermont.
dfaf77
dfaf77
* Mon Jan 13 2014 William Cohen <wcohen@redhat.com> - 5.2.0-4
dfaf77
- Add presets for Haswell and Ivy Bridge.
dfaf77
dfaf77
* Fri Dec 27 2013 Daniel Mach <dmach@redhat.com> - 5.2.0-3
dfaf77
- Mass rebuild 2013-12-27
dfaf77
dfaf77
* Wed Aug 14 2013 William Cohen <wcohen@redhat.com> - 5.2.0-2
dfaf77
- Enable infiniband and stealtime components.
dfaf77
dfaf77
* Wed Aug 07 2013 William Cohen <wcohen@redhat.com> - 5.2.0-1
dfaf77
- Rebase to 5.2.0
dfaf77
dfaf77
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 5.1.1-8
dfaf77
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
dfaf77
dfaf77
* Wed Jul 24 2013 William Cohen <wcohen@redhat.com> - 5.1.1-7
dfaf77
- rhbz830275 - Add support for POWER8 processor to PAPI
dfaf77
dfaf77
* Mon Jul 22 2013 William Cohen <wcohen@redhat.com> - 5.1.1-6
dfaf77
- Add autoconf buildrequires.
dfaf77
dfaf77
* Mon Jul 22 2013 William Cohen <wcohen@redhat.com> - 5.1.1-5
dfaf77
- rhbz986673 - /usr/lib64/libpapi.so is unowned
dfaf77
- Package files in /usr/share/papi only once.
dfaf77
- Avoid dependency problem with parallel make of man pages.
dfaf77
dfaf77
* Fri Jul 19 2013 William Cohen <wcohen@redhat.com> - 5.1.1-4
dfaf77
- Correct changelog.
dfaf77
dfaf77
* Fri Jul 5 2013 William Cohen <wcohen@redhat.com> - 5.1.1-3
dfaf77
- Add man page corrections/updates.
dfaf77
dfaf77
* Fri Jun 28 2013 William Cohen <wcohen@redhat.com> - 5.1.1-2
dfaf77
- Add testsuite subpackage.
dfaf77
dfaf77
* Thu May 30 2013 William Cohen <wcohen@redhat.com> - 5.1.1-1
dfaf77
- Rebase to 5.1.1
dfaf77
dfaf77
* Mon Apr 15 2013 William Cohen <wcohen@redhat.com> - 5.1.0.2-2
dfaf77
- Fix arm FTBS rhbz 951806.
dfaf77
dfaf77
* Tue Apr 9 2013 William Cohen <wcohen@redhat.com> - 5.1.0.2-1
dfaf77
- Rebase to 5.1.0.2
dfaf77
dfaf77
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 5.0.1-6
dfaf77
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
dfaf77
dfaf77
* Mon Jan 14 2013 William Cohen <wcohen@redhat.com> - 5.0.1-5
dfaf77
- Add armv7 cortex a15 presets.
dfaf77
dfaf77
* Tue Dec 04 2012 William Cohen <wcohen@redhat.com> - 5.0.1-4
dfaf77
- Disable ldconfig on install.
dfaf77
dfaf77
* Thu Nov 08 2012 William Cohen <wcohen@redhat.com> - 5.0.1-3
dfaf77
- Avoid duplicated shared library.
dfaf77
dfaf77
* Wed Oct 03 2012 William Cohen <wcohen@redhat.com> - 5.0.1-2
dfaf77
- Make sure using compatible version of libpfm.
dfaf77
dfaf77
* Thu Sep 20 2012 William Cohen <wcohen@redhat.com> - 5.0.1-1
dfaf77
- Rebase to 5.0.1.
dfaf77
dfaf77
* Mon Sep 10 2012 William Cohen <wcohen@redhat.com> - 5.0.0-6
dfaf77
- Back port fixes for Intel Ivy Bridge event presets.
dfaf77
dfaf77
* Thu Aug 30 2012 William Cohen <wcohen@redhat.com> - 5.0.0-5
dfaf77
- Fixes to make papi with unbundled libpfm.
dfaf77
dfaf77
* Mon Aug 27 2012 William Cohen <wcohen@redhat.com> - 5.0.0-2
dfaf77
- Keep libpfm unbundled.
dfaf77
dfaf77
* Fri Aug 24 2012 William Cohen <wcohen@redhat.com> - 5.0.0-1
dfaf77
- Rebase to 5.0.0.
dfaf77
dfaf77
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.4.0-5
dfaf77
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
dfaf77
dfaf77
* Mon Jun 11 2012 William Cohen <wcohen@redhat.com> - 4.4.0-4
dfaf77
- Use siginfo_t rather than struct siginfo.
dfaf77
dfaf77
* Mon Jun 11 2012 William Cohen <wcohen@redhat.com> - 4.4.0-3
dfaf77
- Correct build requires.
dfaf77
dfaf77
* Mon Jun 11 2012 William Cohen <wcohen@redhat.com> - 4.4.0-2
dfaf77
- Unbundle libpfm4 from papi.
dfaf77
- Correct description spellings.
dfaf77
- Remove unused test section.
dfaf77
dfaf77
* Fri Apr 20 2012 William Cohen <wcohen@redhat.com> - 4.4.0-1
dfaf77
- Rebase to 4.4.0.
dfaf77
dfaf77
* Fri Mar 9 2012 William Cohen <wcohen@redhat.com> - 4.2.1-2
dfaf77
- Fix overrun in lmsensor component. (rhbz797692)
dfaf77
dfaf77
* Tue Feb 14 2012 William Cohen <wcohen@redhat.com> - 4.2.1-1
dfaf77
- Rebase to 4.2.1.
dfaf77
dfaf77
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.2.0-4
dfaf77
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
dfaf77
dfaf77
* Wed Nov 02 2011 William Cohen <wcohen@redhat.com> - 4.2.0-3
dfaf77
- Remove unwanted man1/*.c.1 files. (rhbz749725)
dfaf77
dfaf77
* Mon Oct 31 2011 William Cohen <wcohen@redhat.com> - 4.2.0-2
dfaf77
- Include appropirate man pages with papi rpm. (rhbz749725)
dfaf77
- Rebase to papi-4.2.0, fixup for coretemp component. (rhbz746851)
dfaf77
dfaf77
* Thu Oct 27 2011 William Cohen <wcohen@redhat.com> - 4.2.0-1
dfaf77
- Rebase to papi-4.2.0.
dfaf77
dfaf77
* Fri Aug 12 2011 William Cohen <wcohen@redhat.com> - 4.1.3-3
dfaf77
- Provide papi-static.
dfaf77
dfaf77
* Thu May 12 2011 William Cohen <wcohen@redhat.com> - 4.1.3-2
dfaf77
- Use corrected papi-4.1.3.
dfaf77
dfaf77
* Thu May 12 2011 William Cohen <wcohen@redhat.com> - 4.1.3-1
dfaf77
- Rebase to papi-4.1.3
dfaf77
dfaf77
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.1.2.1-2
dfaf77
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
dfaf77
dfaf77
* Mon Jan 24 2011 William Cohen <wcohen@redhat.com> - 4.1.2.1-1
dfaf77
- Rebase to papi-4.1.2.1
dfaf77
dfaf77
* Fri Oct 1 2010 William Cohen <wcohen@redhat.com> - 4.1.1-1
dfaf77
- Rebase to papi-4.1.1
dfaf77
dfaf77
* Tue Jun 22 2010 William Cohen <wcohen@redhat.com> - 4.1.0-1
dfaf77
- Rebase to papi-4.1.0
dfaf77
dfaf77
* Mon May 17 2010 William Cohen <wcohen@redhat.com> - 4.0.0-5
dfaf77
- Test run with upstream cvs version.
dfaf77
dfaf77
* Wed Feb 10 2010 William Cohen <wcohen@redhat.com> - 4.0.0-4
dfaf77
- Resolves: rhbz562935 Rebase to papi-4.0.0 (correct ExcludeArch).
dfaf77
dfaf77
* Wed Feb 10 2010 William Cohen <wcohen@redhat.com> - 4.0.0-3
dfaf77
- Resolves: rhbz562935 Rebase to papi-4.0.0 (bump nvr).
dfaf77
dfaf77
* Wed Feb 10 2010 William Cohen <wcohen@redhat.com> - 4.0.0-2
dfaf77
- correct the ctests/shlib test
dfaf77
- have PAPI_set_multiplex() return proper value
dfaf77
- properly handle event unit masks
dfaf77
- correct PAPI_name_to_code() to match events
dfaf77
- Resolves: rhbz562935 Rebase to papi-4.0.0 
dfaf77
dfaf77
* Wed Jan 13 2010 William Cohen <wcohen@redhat.com> - 4.0.0-1
dfaf77
- Generate papi.spec file for papi-4.0.0.