From e106588579616142b46ac136022586d3891f6336570d0b6ec8f99e0abefb3737 Mon Sep 17 00:00:00 2001 From: heming zhao Date: Tue, 3 Jan 2023 10:04:27 +0000 Subject: [PATCH] Accepting request 1046462 from home:hmzhao:branches:network:ha-clustering:Factory - drbd.service fails to load - incorrect path to executable (bsc#1206754) * use %suse_version to replace %UsrMerge * modify drbd-utils.spec for create symbolic folder "/lib/drbd" OBS-URL: https://build.opensuse.org/request/show/1046462 OBS-URL: https://build.opensuse.org/package/show/network:ha-clustering:Factory/drbd-utils?expand=0&rev=120 --- drbd-utils.changes | 7 +++++++ drbd-utils.spec | 26 ++++++++++++++++---------- 2 files changed, 23 insertions(+), 10 deletions(-) diff --git a/drbd-utils.changes b/drbd-utils.changes index e455532..a735284 100644 --- a/drbd-utils.changes +++ b/drbd-utils.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Tue Jan 3 05:09:00 UTC 2023 - Heming Zhao + +- drbd.service fails to load - incorrect path to executable (bsc#1206754) + * use %suse_version to replace %UsrMerge + * modify drbd-utils.spec for create symbolic folder "/lib/drbd" + ------------------------------------------------------------------- Fri Oct 14 06:37:53 UTC 2022 - Roger Zhou diff --git a/drbd-utils.spec b/drbd-utils.spec index 89823d1..895f214 100644 --- a/drbd-utils.spec +++ b/drbd-utils.spec @@ -1,7 +1,7 @@ # # spec file for package drbd-utils # -# Copyright (c) 2022 SUSE LLC +# Copyright (c) 2023 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -17,13 +17,15 @@ %define services drbd.service drbd-lvchange@.service drbd-promote@.service drbd-reconfigure-suspend-or-error@.service drbd-services@.target drbd-wait-promotable@.service drbd@.service drbd@.target ocf.ra@.service -%if !0%{?usrmerged} -%define sbindir /sbin -# see bsc#1203220 & usrmerge_move_lib_to_prefix_lib.patch for %{libdir} -%define libdir /usr/lib +%if 0%{?suse_version} < 1550 + # for SLEs + %define sbindir /sbin + # see bsc#1203220 & usrmerge_move_lib_to_prefix_lib.patch for %{libdir} + %define libdir /usr/lib %else -%define sbindir %{_sbindir} -%define libdir %{_prefix}/lib + # for opensuse + %define sbindir %{_sbindir} + %define libdir %{_prefix}/lib %endif %bcond_without drbdmon # Man pages are included in the released tarball. @@ -111,7 +113,7 @@ PATH=/sbin:$PATH ./configure \ --with-bashcompletion \ --with-initscripttype=systemd \ --with-systemdunitdir=%{_prefix}/lib/systemd/system \ -%if !0%{?usrmerged} +%if 0%{?suse_version} < 1550 --sbindir=/sbin \ %else --sbindir=%{_sbindir} \ @@ -154,8 +156,12 @@ done ln -sf drbd.conf-9.0.5.gz %{_mandir}/man5/drbd.conf.5.gz ln -sf drbd.conf-9.0.5.gz %{_mandir}/ja/man5/drbd.conf.5.gz %if %{with drbdmon} -ln -sf drbdmon-9.0.8.gz %{_mandir}/man8/drbdmon.8.gz -ln -sf drbdmon-9.0.8.gz %{_mandir}/ja/man8/drbdmon.8.gz + ln -sf drbdmon-9.0.8.gz %{_mandir}/man8/drbdmon.8.gz + ln -sf drbdmon-9.0.8.gz %{_mandir}/ja/man8/drbdmon.8.gz +%endif +%if 0%{?suse_version} < 1550 + # create symbolic folder for bsc#1206364 + ln -s /usr/lib/drbd /lib/drbd %endif %preun