[packages/libipt] - updated to 2.0.1 - added -tools subpackage
qboosh
qboosh at pld-linux.org
Sun Sep 22 19:43:20 CEST 2019
commit 436c5e6e8c37c80e6768c72c750fd860ee90ff56
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date: Sun Sep 22 19:46:25 2019 +0200
- updated to 2.0.1
- added -tools subpackage
libipt.spec | 101 ++++++++++++++++++++++++++++++++++++++++++++----------------
1 file changed, 74 insertions(+), 27 deletions(-)
---
diff --git a/libipt.spec b/libipt.spec
index 938ba57..dc083cd 100644
--- a/libipt.spec
+++ b/libipt.spec
@@ -1,18 +1,27 @@
+#
+# Conditional build:
+%bcond_without xed # ptxed utility
+%bcond_without tests # unit tests
+
Summary: Intel Processor Trace Decoder Library
+Summary(pl.UTF-8): Biblioteka dekodera Intel PT (śladów procesora Intel)
Name: libipt
-Version: 2.0
+Version: 2.0.1
Release: 1
License: BSD
Group: Libraries
-URL: https://github.com/01org/processor-trace
-Source0: https://github.com/01org/processor-trace/archive/v%{version}.tar.gz
-# Source0-md5: d7cc87d42479d41870056a99591096cd
-# c++ is required only for -DPTUNIT test "ptunit-cpp".
-# pandoc is for -DMAN.
-BuildRequires: cmake
-BuildRequires: libstdc++-devel
+#Source0Download: https://github.com/intel/libipt/releases
+Source0: https://github.com/intel/libipt/archive/v%{version}/%{name}-%{version}.tar.gz
+# Source0-md5: bae11676b72d341ecb9b33b9add84be8
+URL: https://github.com/intel/libipt
+BuildRequires: cmake >= 2.8.6
+%{?with_xed:BuildRequires: intel-xed-devel}
+# C++ is required only for -DPTUNIT test "ptunit-cpp".
+%{?with_tests:BuildRequires: libstdc++-devel}
+# pandoc for -DMAN
BuildRequires: pandoc
-ExclusiveArch: %{ix86} %{x8664}
+ExclusiveArch: %{ix86} %{x8664} x32
+BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
The Intel Processor Trace (Intel PT) Decoder Library is Intel's
@@ -20,28 +29,53 @@ reference implementation for decoding Intel PT. It can be used as a
standalone library or it can be partially or fully integrated into
your tool.
+%description -l pl.UTF-8
+Biblioteka Intel PT (Intel Processor Trace - śladów procesora Intel)
+to wzorcowa implementacja Intela do dekodowania Intel PT. Może służyć
+jako biblioteka samodzielna lub zintegrowana we własne narzędzia.
+
%package devel
-Summary: Header files and libraries for Intel Processor Trace Decoder Library
+Summary: Header files for Intel Processor Trace Decoder Library
+Summary(pl.UTF-8): Pliki nagłówkowe biblioteki dekodera Intel PT
Group: Development/Libraries
Requires: %{name} = %{version}-%{release}
-ExclusiveArch: %{ix86} %{x8664}
%description devel
-The %{name}-devel package contains the header files and libraries
-needed to develop programs that use the Intel Processor Trace (Intel
-PT) Decoder Library.
+This package contains the header files needed to develop programs that
+use the Intel Processor Trace (Intel PT) Decoder Library.
+
+%description devel -l pl.UTF-8
+Ten pakiet zawiera pliki nagłówkowe potrzebne do tworzenia programów
+wykorzystujących bibliotekę dekodera Intel PT (śladów procesora
+Intel).
+
+%package tools
+Summary: Intel Processor Trace tools
+Summary(pl.UTF-8): Narzędzia Intel PT
+Group: Development/Tools
+Requires: %{name} = %{version}-%{release}
+
+%description tools
+Intel Processor Trace tools.
+
+%description tools -l pl.UTF-8
+Narzędzia Intel PT.
%prep
-%setup -q -n processor-trace-%{version}
+%setup -q
%build
install -d build
cd build
-%cmake \
- -DPTUNIT:BOOL=ON \
- -DMAN:BOOL=ON \
+%cmake .. \
-DDEVBUILD:BOOL=ON \
- ..
+ -DFEATURE_ELF:BOOL=ON \
+ -DMAN:BOOL=ON \
+ -DPEVENT:BOOL=ON \
+ -DPTDUMP:BOOL=ON \
+ %{?with_tests:-DPTUNIT:BOOL=ON} \
+ %{?with_xed:-DPTXED:BOOL=ON -DXED_INCLUDE=%{_includedir}/xed}
+# -DSIDEBAND:BOOL=ON not yet: not installed, binaries depend on it
%{__make}
@@ -49,23 +83,36 @@ cd build
rm -rf $RPM_BUILD_ROOT
%{__make} -C build install \
- DESTDIR=$RPM_BUILD_ROOT
+ DESTDIR=$RPM_BUILD_ROOT
+
+install -d $RPM_BUILD_ROOT%{_bindir}
+install build/bin/ptdump $RPM_BUILD_ROOT%{_bindir}
+%if %{with xed}
+install build/bin/ptxed $RPM_BUILD_ROOT%{_bindir}
+%endif
%clean
rm -rf $RPM_BUILD_ROOT
-%post -p /sbin/ldconfig
-%postun -p /sbin/ldconfig
+%post -p /sbin/ldconfig
+%postun -p /sbin/ldconfig
%files
%defattr(644,root,root,755)
-%doc README
-%attr(755,root,root) %ghost %{_libdir}/%{name}.so.2
-%attr(755,root,root) %{_libdir}/%{name}.so.*.*
+%doc LICENSE README
+%attr(755,root,root) %{_libdir}/libipt.so.*.*
+%attr(755,root,root) %ghost %{_libdir}/libipt.so.2
%files devel
%defattr(644,root,root,755)
-%doc doc/{getting_started,howto_libipt}.md
+%doc doc/{getting_started,howto_capture,howto_libipt}.md
+%attr(755,root,root) %{_libdir}/libipt.so
%{_includedir}/intel-pt.h
-%attr(755,root,root) %{_libdir}/%{name}.so
%{_mandir}/man3/pt_*.3*
+
+%files tools
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_bindir}/ptdump
+%if %{with xed}
+%attr(755,root,root) %{_bindir}/ptxed
+%endif
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/libipt.git/commitdiff/436c5e6e8c37c80e6768c72c750fd860ee90ff56
More information about the pld-cvs-commit
mailing list