2022-08-05 17:18:20 +00:00
|
|
|
%global mainlibsover 10
|
|
|
|
%global addrlibsover 3
|
2022-05-12 00:34:22 +00:00
|
|
|
|
2021-04-05 02:23:40 +00:00
|
|
|
Name: libkdumpfile
|
2023-11-28 04:28:08 +00:00
|
|
|
Version: 0.5.4
|
2022-04-21 22:16:12 +00:00
|
|
|
Release: %autorelease
|
2021-04-05 02:23:40 +00:00
|
|
|
Summary: Kernel coredump file access
|
|
|
|
|
2023-07-26 03:13:31 +00:00
|
|
|
License: LGPL-3.0-or-later OR GPL-2.0-or-later
|
2021-04-05 02:23:40 +00:00
|
|
|
URL: https://github.com/ptesarik/libkdumpfile
|
2022-08-15 01:44:55 +00:00
|
|
|
Source: %{url}/releases/download/v%{version}/%{name}-%{version}.tar.gz
|
2024-01-04 11:42:04 +00:00
|
|
|
Patch0: libkdumpfile-c99.patch
|
2021-04-05 02:23:40 +00:00
|
|
|
|
|
|
|
BuildRequires: gcc-c++
|
|
|
|
BuildRequires: doxygen
|
|
|
|
BuildRequires: make
|
|
|
|
BuildRequires: sed
|
2022-08-05 17:18:20 +00:00
|
|
|
BuildRequires: libzstd-devel
|
2021-04-05 02:23:40 +00:00
|
|
|
BuildRequires: lzo-devel
|
|
|
|
BuildRequires: python3-devel
|
2023-01-20 20:21:52 +00:00
|
|
|
BuildRequires: python3-setuptools
|
2021-04-05 02:23:40 +00:00
|
|
|
BuildRequires: snappy-devel
|
|
|
|
BuildRequires: zlib-devel
|
|
|
|
|
2022-04-21 22:17:27 +00:00
|
|
|
%global _description %{expand:
|
|
|
|
libkdumpfile is a library to read kdump-compressed kernel core dumps.}
|
|
|
|
|
|
|
|
%description %{_description}
|
2021-04-05 02:23:40 +00:00
|
|
|
|
|
|
|
%package devel
|
|
|
|
Summary: Development files for %{name}
|
|
|
|
Requires: %{name}%{?_isa} = %{version}-%{release}
|
|
|
|
|
2022-04-21 22:17:27 +00:00
|
|
|
%description devel %{_description}
|
|
|
|
|
2021-04-05 02:23:40 +00:00
|
|
|
The %{name}-devel package contains libraries and header files for
|
|
|
|
developing applications that use %{name}.
|
|
|
|
|
|
|
|
%package doc
|
|
|
|
Summary: Documentation for %{name}
|
2023-07-26 03:13:31 +00:00
|
|
|
BuildArch: noarch
|
|
|
|
# keep this until F38 is EOL (so Fedora < 41) as 0.5.1 was not noarch due to
|
|
|
|
# doxygen being run *after* rather than *before* build so it indexes "built"
|
|
|
|
# Python sources too
|
|
|
|
# likewise, EPEL 8 and 9 are affected
|
|
|
|
%if (0%{?fedora} && 0%{?fedora} < 41) || (0%{?rhel} && 0%{?rhel} < 10)
|
|
|
|
Obsoletes: %{name}-doc < 0.5.2-1
|
|
|
|
%endif
|
2021-04-05 02:23:40 +00:00
|
|
|
|
2022-04-21 22:17:27 +00:00
|
|
|
%description doc %{_description}
|
|
|
|
|
2021-04-05 02:23:40 +00:00
|
|
|
The %{name}-doc package contains documentation for %{name}.
|
|
|
|
|
2022-04-12 20:54:08 +00:00
|
|
|
%package -n python3-%{name}
|
2021-04-05 02:23:40 +00:00
|
|
|
Summary: Python bindings for %{name}
|
2022-04-21 22:17:27 +00:00
|
|
|
Obsoletes: %{name}-python < 0.4.0-6
|
2022-04-12 20:54:08 +00:00
|
|
|
Provides: %{name}-python = %{version}-%{release}
|
|
|
|
Provides: %{name}-python%{?_isa} = %{version}-%{release}
|
2021-04-05 02:23:40 +00:00
|
|
|
Requires: %{name}%{?_isa} = %{version}-%{release}
|
|
|
|
|
2022-04-21 22:17:27 +00:00
|
|
|
%description -n python3-%{name} %{_description}
|
|
|
|
|
2022-04-12 20:54:08 +00:00
|
|
|
The python3-%{name} package contains Python bindings for %{name}.
|
2021-04-05 02:23:40 +00:00
|
|
|
|
|
|
|
%package util
|
|
|
|
Summary: Utilities to read kernel core dumps
|
|
|
|
Requires: %{name}%{?_isa} = %{version}-%{release}
|
|
|
|
|
2022-04-21 22:17:27 +00:00
|
|
|
%description util %{_description}
|
2021-04-05 02:23:40 +00:00
|
|
|
The %{name}-devel package contains misc utilities built with %{name}.
|
|
|
|
|
2022-04-21 22:17:27 +00:00
|
|
|
|
2021-04-05 02:23:40 +00:00
|
|
|
%prep
|
2022-08-15 01:44:55 +00:00
|
|
|
%autosetup -p1
|
2021-04-05 02:23:40 +00:00
|
|
|
# Remove unneeded shebang
|
|
|
|
sed -e "\|#!/usr/bin/env python|d" -i python/*/*.py
|
|
|
|
|
2022-04-21 22:17:27 +00:00
|
|
|
|
2021-04-05 02:23:40 +00:00
|
|
|
%build
|
2022-05-11 18:56:40 +00:00
|
|
|
%configure
|
2021-04-05 02:23:40 +00:00
|
|
|
%{__make} doxygen-doc
|
2023-07-26 03:13:31 +00:00
|
|
|
%make_build
|
2021-04-05 02:23:40 +00:00
|
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
%make_install
|
|
|
|
find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';'
|
2022-05-11 18:56:40 +00:00
|
|
|
# static artifacts are needed to run tests, but we don't
|
|
|
|
# want to ship them
|
|
|
|
find $RPM_BUILD_ROOT -name '*.a' -exec rm -f {} ';'
|
|
|
|
|
|
|
|
|
|
|
|
%check
|
2022-05-12 00:34:22 +00:00
|
|
|
%make_build check
|
2021-04-05 02:23:40 +00:00
|
|
|
|
2022-04-21 22:17:27 +00:00
|
|
|
|
2021-04-05 02:23:40 +00:00
|
|
|
%files
|
|
|
|
%license COPYING COPYING.GPLv2 COPYING.GPLv3 COPYING.LGPLv3
|
2022-04-12 20:54:08 +00:00
|
|
|
%doc README.md NEWS
|
2022-04-21 22:17:27 +00:00
|
|
|
%{_libdir}/libaddrxlat.so.%{addrlibsover}{,.*}
|
|
|
|
%{_libdir}/libkdumpfile.so.%{mainlibsover}{,.*}
|
2021-04-05 02:23:40 +00:00
|
|
|
|
|
|
|
%files devel
|
2022-04-12 20:54:08 +00:00
|
|
|
%{_includedir}/%{name}/
|
|
|
|
%{_libdir}/libaddrxlat.so
|
|
|
|
%{_libdir}/libkdumpfile.so
|
2021-04-05 02:23:40 +00:00
|
|
|
%{_libdir}/pkgconfig/libaddrxlat.pc
|
|
|
|
%{_libdir}/pkgconfig/libkdumpfile.pc
|
|
|
|
|
|
|
|
%files doc
|
|
|
|
%license COPYING COPYING.GPLv2 COPYING.GPLv3 COPYING.LGPLv3
|
|
|
|
%doc doc/html
|
|
|
|
|
2022-04-12 20:54:08 +00:00
|
|
|
%files -n python3-%{name}
|
2022-08-15 01:44:55 +00:00
|
|
|
%{python3_sitearch}/%{name}-%{version}-*.egg-info
|
2022-04-21 22:17:27 +00:00
|
|
|
%{python3_sitearch}/addrxlat/
|
|
|
|
%{python3_sitearch}/_addrxlat.*.so
|
|
|
|
%{python3_sitearch}/kdumpfile/
|
|
|
|
%{python3_sitearch}/_kdumpfile.*.so
|
2021-04-05 02:23:40 +00:00
|
|
|
|
|
|
|
%files util
|
2022-04-12 20:54:08 +00:00
|
|
|
%{_bindir}/dumpattr
|
|
|
|
%{_bindir}/listxendoms
|
|
|
|
%{_bindir}/showxlat
|
2021-04-05 02:23:40 +00:00
|
|
|
|
|
|
|
%changelog
|
2022-04-21 22:16:12 +00:00
|
|
|
%autochangelog
|