2007-02-05 15:40:30 +01:00
|
|
|
#
|
2011-11-02 23:55:52 +01:00
|
|
|
# spec file for package makedumpfile
|
2007-02-05 15:40:30 +01:00
|
|
|
#
|
2022-02-11 15:16:05 +01:00
|
|
|
# Copyright (c) 2022 SUSE LLC
|
2007-02-05 15:40:30 +01:00
|
|
|
#
|
2008-08-16 01:01:39 +02:00
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
2019-08-14 16:18:37 +02:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2007-02-05 15:40:30 +01:00
|
|
|
#
|
|
|
|
|
2008-03-28 16:58:26 +01:00
|
|
|
|
2014-03-21 11:38:26 +01:00
|
|
|
%if 0%{!?have_snappy:1}
|
|
|
|
%if 0%{?suse_version} >= 1310
|
|
|
|
%define have_snappy 1
|
|
|
|
%else
|
|
|
|
%define have_snappy 0
|
|
|
|
%endif
|
|
|
|
%endif
|
2016-07-12 16:24:05 +02:00
|
|
|
|
2021-11-19 11:56:30 +01:00
|
|
|
%if 0%{!?have_zstd:1}
|
2022-02-11 15:16:05 +01:00
|
|
|
%if 0%{?sle_version} >= 150200 || 0%{?suse_version} > 1500
|
2021-11-19 11:56:30 +01:00
|
|
|
%define have_zstd 1
|
|
|
|
%else
|
|
|
|
%define have_zstd 0
|
|
|
|
%endif
|
|
|
|
%endif
|
|
|
|
|
2019-01-24 14:32:07 +01:00
|
|
|
# Compatibility cruft
|
2021-07-21 09:43:06 +02:00
|
|
|
# there is no separate -ltinfo until openSUSE 13.1 / SLE 12
|
2016-07-13 12:39:45 +02:00
|
|
|
%if 0%{?suse_version} < 1310 && 0%{?sles_version} < 12
|
2016-07-12 16:24:05 +02:00
|
|
|
%define ncurses_make_opts TINFOLIB=-lncurses
|
|
|
|
%endif
|
2019-01-24 14:32:07 +01:00
|
|
|
# End of compatibility cruft
|
2016-07-12 16:24:05 +02:00
|
|
|
|
2007-02-05 15:40:30 +01:00
|
|
|
Name: makedumpfile
|
2021-11-18 17:16:40 +01:00
|
|
|
Version: 1.7.0
|
2016-04-02 10:27:28 +02:00
|
|
|
Release: 0
|
|
|
|
Summary: Partial kernel dump
|
2018-03-27 09:24:39 +02:00
|
|
|
License: GPL-2.0-only
|
2016-04-02 10:27:28 +02:00
|
|
|
Group: System/Kernel
|
2021-04-04 15:14:15 +02:00
|
|
|
URL: https://github.com/makedumpfile/makedumpfile
|
|
|
|
Source: https://github.com/makedumpfile/makedumpfile/releases/download/%{version}/%{name}-%{version}.tar.gz
|
2016-07-12 16:24:05 +02:00
|
|
|
Source99: %{name}-rpmlintrc
|
2021-07-21 09:43:06 +02:00
|
|
|
Patch0: %{name}-override-libtinfo.patch
|
|
|
|
Patch1: %{name}-ppc64-VA-range-SUSE.patch
|
|
|
|
Patch2: %{name}-PN_XNUM.patch
|
2022-03-21 12:37:34 +01:00
|
|
|
Patch3: %{name}-sadump-kaslr-fix-kaslr_offset-calculation.patch
|
2021-11-19 11:56:30 +01:00
|
|
|
BuildRequires: libbz2-devel
|
2012-06-18 19:10:04 +02:00
|
|
|
BuildRequires: libdw-devel
|
|
|
|
BuildRequires: libelf-devel
|
2016-07-12 16:24:05 +02:00
|
|
|
BuildRequires: libeppic-devel
|
2016-04-02 10:27:28 +02:00
|
|
|
BuildRequires: lzo-devel
|
2016-07-12 16:24:05 +02:00
|
|
|
BuildRequires: ncurses-devel
|
2016-04-02 10:27:28 +02:00
|
|
|
BuildRequires: xz-devel
|
2012-06-18 19:10:04 +02:00
|
|
|
BuildRequires: zlib-devel
|
2016-04-02 10:27:28 +02:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
2016-07-12 17:57:21 +02:00
|
|
|
ExclusiveArch: %{ix86} x86_64 ia64 ppc ppc64 ppc64le s390x %{arm} aarch64
|
2014-03-21 11:38:26 +01:00
|
|
|
%if %{have_snappy}
|
|
|
|
BuildRequires: snappy-devel
|
|
|
|
%endif
|
2021-11-19 11:56:30 +01:00
|
|
|
%if %{have_zstd}
|
|
|
|
BuildRequires: libzstd-devel
|
|
|
|
%endif
|
2007-02-05 15:40:30 +01:00
|
|
|
|
|
|
|
%description
|
|
|
|
makedumpfile is a dump program to shorten the size of dump file. It
|
|
|
|
copies only the necessary pages for analysis with various dump levels,
|
|
|
|
and can compress the page data. The obtained dump file can by analyzed
|
|
|
|
via gdb or crash utility.
|
|
|
|
|
|
|
|
%prep
|
2008-09-09 22:14:10 +02:00
|
|
|
%setup -q
|
2021-07-21 09:43:06 +02:00
|
|
|
%patch0 -p1
|
|
|
|
%patch1 -p1
|
|
|
|
%patch2 -p1
|
2022-03-21 12:37:34 +01:00
|
|
|
%patch3 -p1
|
2007-02-05 15:40:30 +01:00
|
|
|
|
|
|
|
%build
|
2020-04-07 10:24:11 +02:00
|
|
|
export CFLAGS="%{optflags} -fcommon"
|
2014-03-21 11:38:26 +01:00
|
|
|
%if %{have_snappy}
|
|
|
|
export USESNAPPY=on
|
|
|
|
%endif
|
2021-11-19 11:56:30 +01:00
|
|
|
%if %{have_zstd}
|
|
|
|
export USEZSTD=on
|
|
|
|
%endif
|
2016-07-12 16:24:05 +02:00
|
|
|
export USELZO=on
|
|
|
|
export LINKTYPE=dynamic
|
2019-09-05 21:05:44 +02:00
|
|
|
make %{?_smp_mflags} LDFLAGS="-Wl,-rpath,%{_libdir}/%{name}-%{version}"
|
|
|
|
make %{?_smp_mflags} eppic_makedumpfile.so %{?ncurses_make_opts}
|
2007-02-05 15:40:30 +01:00
|
|
|
|
|
|
|
%install
|
2016-04-02 10:27:28 +02:00
|
|
|
install -D -m 0755 makedumpfile %{buildroot}%{_bindir}/makedumpfile
|
|
|
|
install -D -m 0755 makedumpfile-R.pl %{buildroot}%{_bindir}/makedumpfile-R.pl
|
|
|
|
install -D -m 0644 makedumpfile.8 %{buildroot}%{_mandir}/man8/makedumpfile.8
|
|
|
|
install -D -m 0644 makedumpfile.conf.5 %{buildroot}%{_mandir}/man5/makedumpfile.conf.5
|
2016-07-12 16:24:05 +02:00
|
|
|
install -D -m 0755 eppic_makedumpfile.so %{buildroot}%{_libdir}/%{name}-%{version}/eppic_makedumpfile.so
|
2016-04-02 10:27:28 +02:00
|
|
|
install -d -m 0755 %{buildroot}%{_datadir}/%{name}-%{version}/eppic_scripts
|
|
|
|
install -m 0644 -t %{buildroot}%{_datadir}/%{name}-%{version}/eppic_scripts/ eppic_scripts/*
|
2007-02-05 15:40:30 +01:00
|
|
|
|
2019-01-24 14:32:07 +01:00
|
|
|
# Compatibility cruft
|
2021-07-21 09:43:06 +02:00
|
|
|
# there is no %%license prior to SLE12
|
2019-01-24 14:32:07 +01:00
|
|
|
%if %{undefined _defaultlicensedir}
|
|
|
|
%define license %doc
|
|
|
|
%else
|
|
|
|
# filesystem before SLE12 SP3 lacks /usr/share/licenses
|
2018-08-24 15:42:30 +02:00
|
|
|
%if 0%(test ! -d %{_defaultlicensedir} && echo 1)
|
|
|
|
%define _defaultlicensedir %_defaultdocdir
|
|
|
|
%endif
|
|
|
|
%endif
|
2019-01-24 14:32:07 +01:00
|
|
|
# End of compatibility cruft
|
2018-08-24 15:42:30 +02:00
|
|
|
|
2007-02-05 15:40:30 +01:00
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
2018-03-27 09:24:39 +02:00
|
|
|
%license COPYING
|
|
|
|
%doc README IMPLEMENTATION
|
2016-04-02 10:27:28 +02:00
|
|
|
%{_mandir}/man?/*
|
2014-09-23 19:29:37 +02:00
|
|
|
%{_bindir}/*
|
2016-07-12 16:24:05 +02:00
|
|
|
%dir %{_libdir}/%{name}-%{version}
|
|
|
|
%{_libdir}/%{name}-%{version}/eppic_makedumpfile.so
|
2014-05-07 18:36:19 +02:00
|
|
|
%dir %{_datadir}/%{name}-%{version}
|
|
|
|
%{_datadir}/%{name}-%{version}/eppic_scripts/
|
2007-11-29 18:24:38 +01:00
|
|
|
|
2007-03-11 00:02:29 +01:00
|
|
|
%changelog
|