#23 Fix build when %_bindir==%_sbindir
Merged a month ago by coiby. Opened a month ago by zbyszek.
rpms/ zbyszek/kexec-tools bin-sbin-merge  into  rawhide

file modified
+6 -3
@@ -145,6 +145,8 @@ 

  %define archdef ARCH=ppc

  %endif

  

+ sed -r -i 's|/usr/sbin|%_sbindir|g' makedumpfile-*/Makefile

+ 

  %build

  autoreconf

  %configure \
@@ -156,7 +158,7 @@ 

      --host=powerpc64le-redhat-linux-gnu \

      --build=powerpc64le-redhat-linux-gnu \

  %endif

-     --sbindir=/usr/sbin

+     --sbindir=%{_sbindir}

  rm -f kexec-tools.spec.in

  %make_build

  
@@ -172,7 +174,7 @@ 

  

  # kdump-utils

  %define kdump_utils_dir kdump-utils-%{kdump_utils_ver}

- make DESTDIR=%{buildroot} -C %kdump_utils_dir install

+ %make_install -C %kdump_utils_dir sbindir=%_sbindir

  

  # makedumpfile

  
@@ -249,8 +251,9 @@ 

  %{_sbindir}/mkfadumprd

  %{_prefix}/lib/kernel/install.d/60-fadump.install

  %endif

+ %{_bindir}/kdumpctl

  %{_sbindir}/mkdumprd

- %{_bindir}/*

+ %{_sbindir}/vmcore-dmesg

  %{_prefix}/lib/kdump

  %config(noreplace,missingok) %{_sysconfdir}/sysconfig/kdump

  %config(noreplace,missingok) %verify(not mtime) %{_sysconfdir}/kdump.conf

Build succeeded.
https://fedora.softwarefactory-project.io/zuul/buildset/c34ea77044d5417f8b0d84ed138eaff9

Hi @zbyszek,

For the makedumpfile subpackage, the path of makedumpfile binary is hard-coded to /usr/sbin. Shall we fix makedumpfile before merging this PR?

In this patch, the location is "fixed" using sed. I'd be nice to push this upstream, but OTOH, it's a one-line change, so I think it's fine it is applied downstream for now and then fixed upstream at leisure.

Thanks for the clarification! I'm going to merge the PR but find%{_sbindir}/vmcore-dmesg belongs to the kexec-tools subpackage.

Updated. %{_sbindir}/vmcore-dmesg is now in kexec-tools only.

Pull-Request has been merged by coiby

a month ago
Metadata