3 %bcond_without xed # ptxed utility
4 %bcond_without tests # unit tests
5 %bcond_without ghc # man pages (requires ghc-dependent pandoc)
7 Summary: Intel Processor Trace Decoder Library
8 Summary(pl.UTF-8): Biblioteka dekodera Intel PT (śladów procesora Intel)
14 #Source0Download: https://github.com/intel/libipt/tags
15 Source0: https://github.com/intel/libipt/archive/v%{version}/%{name}-%{version}.tar.gz
16 # Source0-md5: 064e0d369bd30f78ec771a10c88a71ef
17 Patch0: %{name}-uninitialized.patch
18 Patch1: %{name}-intel-xed.patch
19 URL: https://github.com/intel/libipt
20 BuildRequires: cmake >= 3.1
21 %{?with_xed:BuildRequires: intel-xed-devel}
22 # C++ is required only for -DPTUNIT test "ptunit-cpp".
23 %{?with_tests:BuildRequires: libstdc++-devel}
24 %{?with_ghc:BuildRequires: pandoc}
25 ExclusiveArch: %{ix86} %{x8664} x32
26 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
29 The Intel Processor Trace (Intel PT) Decoder Library is Intel's
30 reference implementation for decoding Intel PT. It can be used as a
31 standalone library or it can be partially or fully integrated into
34 %description -l pl.UTF-8
35 Biblioteka Intel PT (Intel Processor Trace - śladów procesora Intel)
36 to wzorcowa implementacja Intela do dekodowania Intel PT. Może służyć
37 jako biblioteka samodzielna lub zintegrowana we własne narzędzia.
40 Summary: Header files for Intel Processor Trace Decoder Library
41 Summary(pl.UTF-8): Pliki nagłówkowe biblioteki dekodera Intel PT
42 Group: Development/Libraries
43 Requires: %{name} = %{version}-%{release}
46 This package contains the header files needed to develop programs that
47 use the Intel Processor Trace (Intel PT) Decoder Library.
49 %description devel -l pl.UTF-8
50 Ten pakiet zawiera pliki nagłówkowe potrzebne do tworzenia programów
51 wykorzystujących bibliotekę dekodera Intel PT (śladów procesora
55 Summary: Intel Processor Trace tools
56 Summary(pl.UTF-8): Narzędzia Intel PT
57 Group: Development/Tools
58 Requires: %{name} = %{version}-%{release}
61 Intel Processor Trace tools.
63 %description tools -l pl.UTF-8
76 -DFEATURE_ELF:BOOL=ON \
77 %{?with_ghc:-DMAN:BOOL=ON} \
80 %{?with_tests:-DPTUNIT:BOOL=ON} \
81 %{?with_xed:-DPTXED:BOOL=ON -DXED_INCLUDE=%{_includedir}/xed} \
87 rm -rf $RPM_BUILD_ROOT
89 %{__make} -C build install \
90 DESTDIR=$RPM_BUILD_ROOT
92 # not installed by cmake
93 cp -a build/lib/libipt-sb.so* $RPM_BUILD_ROOT%{_libdir}
95 install -d $RPM_BUILD_ROOT%{_bindir}
96 install build/bin/ptdump $RPM_BUILD_ROOT%{_bindir}
98 install build/bin/ptxed $RPM_BUILD_ROOT%{_bindir}
102 rm -rf $RPM_BUILD_ROOT
104 %post -p /sbin/ldconfig
105 %postun -p /sbin/ldconfig
108 %defattr(644,root,root,755)
110 %attr(755,root,root) %{_libdir}/libipt.so.*.*
111 %attr(755,root,root) %ghost %{_libdir}/libipt.so.2
112 %attr(755,root,root) %{_libdir}/libipt-sb.so.*.*
113 %attr(755,root,root) %ghost %{_libdir}/libipt-sb.so.2
116 %defattr(644,root,root,755)
117 %doc doc/{getting_started,howto_capture,howto_libipt}.md
118 %attr(755,root,root) %{_libdir}/libipt.so
119 %attr(755,root,root) %{_libdir}/libipt-sb.so
120 %{_includedir}/intel-pt.h
122 %{_mandir}/man3/pt_*.3*
126 %defattr(644,root,root,755)
127 %attr(755,root,root) %{_bindir}/ptdump
129 %attr(755,root,root) %{_bindir}/ptxed