diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..139644f --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +SOURCES/0.1.4.tar.gz diff --git a/.paflib.metadata b/.paflib.metadata new file mode 100644 index 0000000..86a805d --- /dev/null +++ b/.paflib.metadata @@ -0,0 +1 @@ +366c4a583b058989f1639f7a30a0a1baaa35c709 SOURCES/0.1.4.tar.gz diff --git a/SOURCES/0001-Fix-error-in-libpaf-dsc-and-libpaf-ebb-man-pages-exa.patch b/SOURCES/0001-Fix-error-in-libpaf-dsc-and-libpaf-ebb-man-pages-exa.patch new file mode 100644 index 0000000..0f92690 --- /dev/null +++ b/SOURCES/0001-Fix-error-in-libpaf-dsc-and-libpaf-ebb-man-pages-exa.patch @@ -0,0 +1,105 @@ +From da3cbb29844900a132d7dfdd7012c639517b1895 Mon Sep 17 00:00:00 2001 +From: Jan Chaloupka +Date: Thu, 21 Apr 2016 00:42:10 +0530 +Subject: [PATCH] Fix error in libpaf-dsc and libpaf-ebb man pages example + +Also fix wrong formatting of libpaf-dsc man page display +with reduced terminal size on PowerPC + +Signed-off-by: Sinny Kumari +Signed-off-by: Jan Chaloupka +--- + dsc/doc/libpaf-dsc.3 | 18 ++++++------------ + ebb/doc/libpaf-ebb.3 | 4 ++-- + 2 files changed, 8 insertions(+), 14 deletions(-) + +diff --git a/dsc/doc/libpaf-dsc.3 b/dsc/doc/libpaf-dsc.3 +index 201441f..e1c4ae4 100644 +--- a/dsc/doc/libpaf-dsc.3 ++++ b/dsc/doc/libpaf-dsc.3 +@@ -52,47 +52,40 @@ available on Power Architecture. This register follows the layout specified in + the corresponding Power ISA, with the following defined flags. + + These are features supported by Power ISA 2.05: +-.TP ++.LP + .IP \[bu] 2 + .BR DSCR_SSE + Store Stream Enable. + +-.PP ++.LP + These features were added on Power ISA 2.06: +-.TP + .IP \[bu] 2 + .BR DSCR_SNSE + Stride-N Stream Enable. +-.PP ++ ++.LP + These features were added on Power ISA 2.06+: +-.TP + .IP \[bu] 2 + .BR DSCR_LSD + Load Stream Disable. + +-.PP ++.LP + These are supported only on Power ISA 2.07: +-.TP + .IP \[bu] 2 + .BR DSCR_HWUE + Hardware Unit count Enable. +-.TP + .IP \[bu] 2 + .BR DSCR_SWUE + Software Unit count Enable. +-.TP + .IP \[bu] + .BR DSCR_LTE + Load Transient Enable. +-.TP + .IP \[bu] + .BR DSCR_STE + Software Transient Enable. +-.TP + .IP \[bu] + .BR DSCR_HTE + Hardware Transient Enable. +-.TP + .IP \[bu] + .BR DSCR_SWTE + Software Transient Enable. +@@ -201,6 +194,7 @@ if the system does not support DSCR facility. + .nf + #include + #include ++#include + + int main(void) + { +diff --git a/ebb/doc/libpaf-ebb.3 b/ebb/doc/libpaf-ebb.3 +index b5c9e4e..44a0844 100644 +--- a/ebb/doc/libpaf-ebb.3 ++++ b/ebb/doc/libpaf-ebb.3 +@@ -279,7 +279,7 @@ void do_work (void) + } + } + +-int _do_ebb(void) ++int do_ebb(void) + { + ebbhandler_t handler; + ebb_handler_triggered = 0; +@@ -302,7 +302,7 @@ int _do_ebb(void) + + paf_ebb_disable_branches (); + +- printf ("Done; %d EBB interrupts handled\n", ebb_handler_triggered); ++ printf ("Done; %d EBB interrupts handled\\n", ebb_handler_triggered); + + close (ebb_fd); + +-- +2.4.11 + diff --git a/SPECS/paflib.spec b/SPECS/paflib.spec new file mode 100644 index 0000000..f447525 --- /dev/null +++ b/SPECS/paflib.spec @@ -0,0 +1,88 @@ +Name: paflib +Version: 0.1.4 +Release: 3%{?dist} +Summary: Library for accessing Power Architecture Facilities +License: MIT +URL: https://github.com/paflib/paflib +Source0: https://github.com/paflib/paflib/archive/%{version}.tar.gz +Patch0: 0001-Fix-error-in-libpaf-dsc-and-libpaf-ebb-man-pages-exa.patch + +ExclusiveArch: %{power64} +BuildRequires: libtool + +%package devel +Summary: Header files for paflib +Group: Development/Libraries +Requires: %{name}%{?_isa} = %{version}-%{release} +%description devel +Contains header files for building with paflib. + +%description +PAFLib is a IBM written library which exposes Power Architecture Facilities to +user space via an API. This includes the Data Stream Control Register Facility +(DSCR) and the Event-Based Branching facility (EBB). Linux kernel 3.9 has +exposed problem-state DSCR usage for ISA 2.06 (POWER7 – emulated) and ISA +2.07 (POWER8– in hardware). Linux 3.10 has exposed the EBB facility. + +%prep +%setup -q -n %{name}-%{version} +%patch0 -p1 -b .man + +%build +%configure --disable-static +make %{?_smp_mflags} + +%install +make install DESTDIR=$RPM_BUILD_ROOT + +%post -p /sbin/ldconfig + +%postun -p /sbin/ldconfig + +%files +%exclude %{_libdir}/libpaf-dsc.la +%{_libdir}/libpaf-ebb.so.0.0.1 +%{_libdir}/libpaf-dsc.so.0.0.1 +%{_libdir}/libpaf-dsc.so.0 +%{_libdir}/libpaf-ebb.so.0 +%exclude %{_libdir}/libpaf-ebb.la + +%doc COPYING README.md + +%files devel +%{_libdir}/libpaf-dsc.so +%{_libdir}/libpaf-ebb.so +%dir %{_includedir}/paf +%{_includedir}/paf/dsc.h +%{_includedir}/paf/ebb.h +%{_mandir}/man3/libpaf-dsc.3* +%{_mandir}/man3/libpaf-ebb.3* + +%changelog +* Tue Feb 07 2017 Sinny Kumari 0.1.4-3 +- Resolves: #1349833 - wrong display manual page for libpaf-dsc in reduced size of terminal + +* Wed Oct 01 2014 Jakub Čajka 0.1.4-2 +- Related: #989565 - removed ppc + +* Thu Sep 25 2014 Rajalakshmi S 0.1.4-1 +- Update release + +* Thu Sep 25 2014 Rajalakshmi S 0.1.4-5 +- Update next release + +* Mon Sep 15 2014 Rajalakshmi S 0.1.3-4 +- Move manual pages to devel package and remove Group tag + +* Wed Sep 10 2014 Rajalakshmi S 0.1-3 +- Various spec file fixes + +* Tue Sep 09 2014 Rajalakshmi S 0.1-2 +- Remove passing libdir and prefix to configure in spec file +- Remove RPM_BUILD_ROOT cleanup in install in spec file + +* Tue Sep 09 2014 Rajalakshmi S 0.1-1 +- Fix builddir in spec-file + +* Mon Sep 01 2014 Rajalakshmi S 0.1-1 +- Initial RPM release