2006-12-20 12:32:29 +01:00
|
|
|
#
|
2011-05-17 15:25:00 +02:00
|
|
|
# spec file for package kexec-tools
|
2006-12-20 12:32:29 +01:00
|
|
|
#
|
2017-02-22 22:34:29 +01:00
|
|
|
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
|
2006-12-20 12:32:29 +01:00
|
|
|
#
|
2008-10-09 19:20:27 +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.
|
|
|
|
|
2006-12-20 12:32:29 +01:00
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
2012-05-17 09:57:54 +02:00
|
|
|
|
2006-12-20 12:32:29 +01:00
|
|
|
Name: kexec-tools
|
2007-07-16 18:06:43 +02:00
|
|
|
%ifarch ppc
|
2011-12-07 20:27:53 +01:00
|
|
|
BuildRequires: gcc-64bit
|
|
|
|
BuildRequires: glibc-devel-64bit
|
2007-07-16 18:06:43 +02:00
|
|
|
%endif
|
2008-08-18 18:49:11 +02:00
|
|
|
Requires: perl-Bootloader
|
2015-12-15 17:26:27 +01:00
|
|
|
Requires(pre): %fillup_prereq
|
|
|
|
Requires(post): coreutils
|
|
|
|
Requires(postun): coreutils
|
2017-10-17 23:22:39 +02:00
|
|
|
Summary: Tools for loading replacement kernels into memory
|
2012-05-17 09:57:54 +02:00
|
|
|
License: GPL-2.0+
|
|
|
|
Group: System/Kernel
|
2017-05-31 22:00:34 +02:00
|
|
|
Version: 2.0.14
|
2011-12-07 20:27:53 +01:00
|
|
|
Release: 0
|
2017-05-31 22:00:34 +02:00
|
|
|
Source: https://git.kernel.org/pub/scm/utils/kernel/kexec/kexec-tools.git/snapshot/%{name}-%{version}.tar.gz
|
2008-08-18 18:49:11 +02:00
|
|
|
Source1: kexec-bootloader
|
|
|
|
Source2: kexec-bootloader.8.txt
|
2014-02-21 18:41:59 +01:00
|
|
|
Source3: kexec-load.service
|
2014-02-06 00:15:44 +01:00
|
|
|
Source4: %{name}-rpmlintrc
|
2012-10-12 02:06:56 +02:00
|
|
|
Patch1: %{name}-xen-static.patch
|
2014-01-11 14:04:44 +01:00
|
|
|
Patch2: %{name}-xen-balloon-up.patch
|
|
|
|
Patch3: %{name}-disable-test.patch
|
2017-05-31 22:00:34 +02:00
|
|
|
# upstream fixes
|
|
|
|
Patch101: 0001-kexec-tools-2.0.14.git.patch
|
|
|
|
Patch102: 0002-ppc64-Reduce-number-of-ELF-LOAD-segments.patch
|
|
|
|
Patch103: 0003-kexec-Increase-the-upper-limit-for-RAM-segments.patch
|
|
|
|
Patch104: 0004-alpha-add-missing-__NR_kexec_load-definition.patch
|
|
|
|
Patch105: 0005-kexec-implemented-XEN-KEXEC-STATUS-to-determine-if-a.patch
|
|
|
|
Patch106: 0006-kexec-Remove-redundant-space-from-help-message.patch
|
|
|
|
Patch107: 0007-purgatory-Add-purgatory.map-and-purgatory.ro.sym-to-.patch
|
|
|
|
Patch108: 0008-kexec-Add-option-to-get-crash-kernel-region-size.patch
|
|
|
|
Patch109: 0009-crashdump-arm-Add-get_crash_kernel_load_range-functi.patch
|
|
|
|
Patch110: 0010-crashdump-arm64-Add-get_crash_kernel_load_range-func.patch
|
|
|
|
Patch111: 0011-crashdump-cris-Add-get_crash_kernel_load_range-funct.patch
|
|
|
|
Patch112: 0012-crashdump-ia64-Add-get_crash_kernel_load_range-funct.patch
|
|
|
|
Patch113: 0013-crashdump-m68k-Add-get_crash_kernel_load_range-funct.patch
|
|
|
|
Patch114: 0014-crashdump-mips-Add-get_crash_kernel_load_range-funct.patch
|
|
|
|
Patch115: 0015-crashdump-ppc-Add-get_crash_kernel_load_range-functi.patch
|
|
|
|
Patch116: 0016-crashdump-ppc64-Add-get_crash_kernel_load_range-func.patch
|
|
|
|
Patch117: 0017-crashdump-s390-Add-get_crash_kernel_load_range-funct.patch
|
|
|
|
Patch118: 0018-crashdump-sh-Add-get_crash_kernel_load_range-functio.patch
|
|
|
|
Patch119: 0019-gitignore-add-two-generated-files-in-purgatory.patch
|
|
|
|
Patch120: 0020-Only-print-debug-message-when-failed-to-serach-for-k.patch
|
|
|
|
Patch121: 0021-build_mem_phdrs-check-if-p_paddr-is-invalid.patch
|
|
|
|
Patch122: 0022-uImage-fix-realloc-pointer-confusion.patch
|
|
|
|
Patch123: 0023-uImage-Fix-uImage_load-for-little-endian-machines.patch
|
|
|
|
Patch124: 0024-uImage-Add-new-IH_ARCH_xxx-definitions.patch
|
|
|
|
Patch125: 0025-uImage-use-char-instead-of-unsigned-char-for-uImage_.patch
|
|
|
|
Patch126: 0026-uImage-use-char-instead-of-unsigned-char-for-uImage_.patch
|
|
|
|
Patch127: 0027-arm64-add-uImage-support.patch
|
|
|
|
Patch128: 0028-vmcore-dmesg-Define-_GNU_SOURCE.patch
|
|
|
|
Patch129: 0029-Don-t-use-L-width-specifier-with-integer-values.patch
|
|
|
|
Patch130: 0030-x86-x86_64-Fix-format-warning-with-die.patch
|
|
|
|
Patch131: 0031-ppc-Fix-format-warning-with-die.patch
|
|
|
|
Patch132: 0032-crashdump-Remove-stray-get_crashkernel_region-declar.patch
|
|
|
|
Patch133: 0033-x86-Support-large-number-of-memory-ranges.patch
|
|
|
|
Patch134: 0034-Fix-broken-Xen-support-in-configure.ac.patch
|
|
|
|
Patch135: 0035-kexec-extend-the-semantics-of-kexec_iomem_for_each_l.patch
|
|
|
|
Patch136: 0036-kexec-generalize-and-rename-get_kernel_stext_sym.patch
|
|
|
|
Patch137: 0037-arm64-identify-PHYS_OFFSET-correctly.patch
|
|
|
|
Patch138: 0038-arm64-change-return-values-on-error-to-negative.patch
|
|
|
|
Patch139: 0039-arm64-kdump-identify-memory-regions.patch
|
|
|
|
Patch140: 0040-arm64-kdump-add-elf-core-header-segment.patch
|
|
|
|
Patch141: 0041-arm64-kdump-set-up-kernel-image-segment.patch
|
|
|
|
Patch142: 0042-arm64-kdump-set-up-other-segments.patch
|
|
|
|
Patch143: 0043-arm64-kdump-add-DT-properties-to-crash-dump-kernel-s.patch
|
|
|
|
Patch144: 0044-arm64-kdump-Add-support-for-binary-image-files.patch
|
|
|
|
Patch145: 0045-Handle-additional-e820-memmap-type-strings.patch
|
2014-07-26 20:56:01 +02:00
|
|
|
|
2011-05-17 12:23:28 +02:00
|
|
|
Url: ftp://kernel.org/pub/linux/utils/kernel/kexec/%{name}-%{version}.tar.bz2
|
2006-12-20 12:32:29 +01:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
2009-01-19 02:08:14 +01:00
|
|
|
#!BuildIgnore: fop
|
2017-02-22 22:34:29 +01:00
|
|
|
#!BuildIgnore: gcc-PIE
|
2011-12-07 20:27:53 +01:00
|
|
|
BuildRequires: asciidoc
|
2014-02-21 18:41:59 +01:00
|
|
|
BuildRequires: automake
|
2011-12-07 20:27:53 +01:00
|
|
|
BuildRequires: libxslt
|
2014-02-21 18:41:59 +01:00
|
|
|
BuildRequires: zlib-devel
|
2014-01-06 10:06:17 +01:00
|
|
|
%ifarch x86_64
|
2016-05-10 22:52:19 +02:00
|
|
|
BuildRequires: pkg-config
|
2008-11-25 15:46:57 +01:00
|
|
|
BuildRequires: xen-devel
|
|
|
|
%endif
|
2015-03-24 09:52:04 +01:00
|
|
|
ExclusiveArch: ppc64le aarch64 %ix86 x86_64 ia64 ppc ppc64 s390 s390x %arm sh mips mipsel m68k
|
2006-12-20 12:32:29 +01:00
|
|
|
|
|
|
|
%description
|
2007-06-11 18:14:03 +02:00
|
|
|
Kexec is a user space utility for loading another kernel and asking the
|
|
|
|
currently running kernel to do something with it. A currently running
|
2014-02-06 00:27:48 +01:00
|
|
|
kernel may be asked to start the loaded kernel on reboot, or to start
|
2007-06-11 18:14:03 +02:00
|
|
|
the loaded kernel after it panics.
|
2006-12-20 12:32:29 +01:00
|
|
|
|
|
|
|
%prep
|
2008-07-21 22:46:56 +02:00
|
|
|
%setup -q -n kexec-tools-%{version}
|
2017-05-31 22:00:34 +02:00
|
|
|
%patch101 -p1
|
|
|
|
%patch102 -p1
|
|
|
|
%patch103 -p1
|
|
|
|
%patch104 -p1
|
|
|
|
%patch105 -p1
|
|
|
|
%patch106 -p1
|
|
|
|
%patch107 -p1
|
|
|
|
%patch108 -p1
|
|
|
|
%patch109 -p1
|
|
|
|
%patch110 -p1
|
|
|
|
%patch111 -p1
|
|
|
|
%patch112 -p1
|
|
|
|
%patch113 -p1
|
|
|
|
%patch114 -p1
|
|
|
|
%patch115 -p1
|
|
|
|
%patch116 -p1
|
|
|
|
%patch117 -p1
|
|
|
|
%patch118 -p1
|
|
|
|
%patch119 -p1
|
|
|
|
%patch120 -p1
|
|
|
|
%patch121 -p1
|
|
|
|
%patch122 -p1
|
|
|
|
%patch123 -p1
|
|
|
|
%patch124 -p1
|
|
|
|
%patch125 -p1
|
|
|
|
%patch126 -p1
|
|
|
|
%patch127 -p1
|
|
|
|
%patch128 -p1
|
|
|
|
%patch129 -p1
|
|
|
|
%patch130 -p1
|
|
|
|
%patch131 -p1
|
|
|
|
%patch132 -p1
|
|
|
|
%patch133 -p1
|
|
|
|
%patch134 -p1
|
|
|
|
%patch135 -p1
|
|
|
|
%patch136 -p1
|
|
|
|
%patch137 -p1
|
|
|
|
%patch138 -p1
|
|
|
|
%patch139 -p1
|
|
|
|
%patch140 -p1
|
|
|
|
%patch141 -p1
|
|
|
|
%patch142 -p1
|
|
|
|
%patch143 -p1
|
|
|
|
%patch144 -p1
|
|
|
|
%patch145 -p1
|
|
|
|
|
2008-10-08 18:20:30 +02:00
|
|
|
%patch1 -p1
|
2010-09-21 12:21:42 +02:00
|
|
|
%patch2 -p1
|
2011-07-11 08:32:40 +02:00
|
|
|
%patch3 -p1
|
2006-12-20 12:32:29 +01:00
|
|
|
|
|
|
|
%build
|
2009-07-13 18:09:12 +02:00
|
|
|
# disable as-needed
|
|
|
|
export SUSE_ASNEEDED=0
|
2007-07-16 18:06:43 +02:00
|
|
|
%{?suse_update_config -f}
|
2016-06-23 14:03:26 +02:00
|
|
|
%ifarch ia64
|
2017-10-17 23:22:39 +02:00
|
|
|
RPM_OPT_FLAGS=$(echo "%{optflags}" | sed -e 's/-fstack-protector//')
|
2008-02-21 01:55:25 +01:00
|
|
|
%endif
|
2011-05-17 12:23:28 +02:00
|
|
|
autoreconf -f
|
2017-10-17 23:22:39 +02:00
|
|
|
CFLAGS="$RPM_OPT_FLAGS" BUILD_CFLAGS="$RPM_OPT_FLAGS" \
|
2007-07-16 18:06:43 +02:00
|
|
|
%ifarch ppc
|
2014-02-06 00:15:44 +01:00
|
|
|
%configure --host=powerpc64-suse-linux --build=powerpc64-suse-linux
|
|
|
|
%else
|
|
|
|
%configure
|
2007-07-16 18:06:43 +02:00
|
|
|
%endif
|
2008-07-14 18:20:51 +02:00
|
|
|
make
|
2014-02-21 18:41:59 +01:00
|
|
|
a2x -D . -d manpage -f manpage %{S:2}
|
2006-12-20 12:32:29 +01:00
|
|
|
|
|
|
|
%install
|
2017-10-17 23:22:39 +02:00
|
|
|
%make_install
|
|
|
|
install -c -m 0644 kexec-bootloader.8 %{buildroot}/%{_mandir}/man8
|
|
|
|
rm -f %{buildroot}/%{_mandir}/man8/kdump.8
|
|
|
|
mkdir -p %{buildroot}/%{_sbindir}
|
|
|
|
install -m 0755 %{S:1} %{buildroot}/%{_sbindir}
|
|
|
|
mkdir -p %{buildroot}/%{_unitdir}
|
|
|
|
install -m644 %{S:3} %{buildroot}/%{_unitdir}
|
2012-05-17 09:57:54 +02:00
|
|
|
#UsrMerge
|
2017-10-17 23:22:39 +02:00
|
|
|
mkdir -p %{buildroot}/sbin
|
|
|
|
ln -s %{_sbindir}/kdump %{buildroot}/sbin
|
|
|
|
ln -s %{_sbindir}/kexec %{buildroot}/sbin
|
2012-05-17 09:57:54 +02:00
|
|
|
#EndUsrMerge
|
2006-12-20 12:32:29 +01:00
|
|
|
|
2008-08-18 18:49:11 +02:00
|
|
|
%post
|
2014-02-21 18:41:59 +01:00
|
|
|
%service_add_post kexec-load.service
|
2015-03-30 20:23:51 +02:00
|
|
|
%{?regenerate_initrd_post}
|
2008-08-18 18:49:11 +02:00
|
|
|
|
|
|
|
%postun
|
2014-02-21 18:41:59 +01:00
|
|
|
%service_del_postun kexec-load.service
|
2015-12-15 17:26:27 +01:00
|
|
|
%{?regenerate_initrd_post}
|
2014-02-21 18:41:59 +01:00
|
|
|
|
|
|
|
%pre
|
|
|
|
%service_add_pre kexec-load.service
|
|
|
|
|
|
|
|
%preun
|
|
|
|
%service_del_preun kexec-load.service
|
2008-08-18 18:49:11 +02:00
|
|
|
|
2015-03-30 20:23:51 +02:00
|
|
|
%posttrans
|
|
|
|
%{?regenerate_initrd_posttrans}
|
|
|
|
|
2006-12-20 12:32:29 +01:00
|
|
|
%files
|
|
|
|
%defattr(-, root, root)
|
2008-07-14 18:20:51 +02:00
|
|
|
%doc AUTHORS COPYING News TODO doc
|
2006-12-20 12:32:29 +01:00
|
|
|
%doc %{_mandir}/man*/*
|
2012-05-17 09:57:54 +02:00
|
|
|
#UsrMerge
|
2016-06-10 22:07:09 +02:00
|
|
|
/sbin/kdump
|
|
|
|
/sbin/kexec
|
2012-05-17 09:57:54 +02:00
|
|
|
#EndUsrMerge
|
2016-06-10 22:07:09 +02:00
|
|
|
%{_sbindir}/kdump
|
|
|
|
%{_sbindir}/kexec
|
2008-08-18 18:49:11 +02:00
|
|
|
%{_sbindir}/kexec-bootloader
|
2016-06-10 22:07:09 +02:00
|
|
|
%{_sbindir}/vmcore-dmesg
|
2014-02-21 18:41:59 +01:00
|
|
|
%{_unitdir}/kexec-load.service
|
2007-11-30 13:26:29 +01:00
|
|
|
|
2007-03-10 23:59:41 +01:00
|
|
|
%changelog
|