From e609374de6e90f8fc5902cd55e636a14ed64145fe114ba91bf991fc41a8d8c70 Mon Sep 17 00:00:00 2001 From: Mitsutoshi NAKANO Date: Sat, 16 Mar 2019 00:28:52 +0000 Subject: [PATCH] Accepting request 685466 from home:jengelh:branches:M17N - Do not hide errors coming from useradd. OBS-URL: https://build.opensuse.org/request/show/685466 OBS-URL: https://build.opensuse.org/package/show/M17N/fwnn?expand=0&rev=26 --- fwnn.changes | 5 +++++ fwnn.spec | 26 +++++++++++++++++++------- 2 files changed, 24 insertions(+), 7 deletions(-) diff --git a/fwnn.changes b/fwnn.changes index 4543e2f..9308839 100644 --- a/fwnn.changes +++ b/fwnn.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Fri Mar 15 21:24:15 UTC 2019 - Jan Engelhardt + +- Do not hide errors coming from useradd. + ------------------------------------------------------------------- Sat Mar 9 07:51:43 UTC 2019 - bkbin005@rinku.zaq.ne.jp diff --git a/fwnn.spec b/fwnn.spec index 6e1899c..7aca4bf 100644 --- a/fwnn.spec +++ b/fwnn.spec @@ -12,7 +12,7 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # @@ -287,7 +287,9 @@ find %{buildroot} -type f -name "*.a" -delete -print %pre -n fwnn %service_add_pre fwnn.service -%{_sbindir}/useradd -r -o -g root -u 66 -s /bin/false -c "Wnn System Account" -d %{_localstatedir}/lib/wnn wnn 2> /dev/null || : +getent passwd wnn >/dev/null || \ + %{_sbindir}/useradd -r -o -g root -u 66 -s /bin/false \ + -c "Wnn System Account" -d %{_localstatedir}/lib/wnn wnn %post -n fwnn %service_add_post fwnn.service @@ -309,14 +311,20 @@ chroot . usr/bin/wnntouch var/lib/wnn/ja/dic/pubdic/*.* %postun -n libwnn0 -p /sbin/ldconfig %pre -n fwnncom -%{_sbindir}/useradd -r -o -g root -u 66 -s /bin/false -c "Wnn System Account" -d %{_localstatedir}/lib/wnn wnn 2> /dev/null || : +getent passwd wnn >/dev/null || \ + %{_sbindir}/useradd -r -o -g root -u 66 -s /bin/false \ + -c "Wnn System Account" -d %{_localstatedir}/lib/wnn wnn %pre -n fcwnncom -%{_sbindir}/useradd -r -o -g root -u 66 -s /bin/false -c "Wnn System Account" -d %{_localstatedir}/lib/wnn wnn 2> /dev/null || : +getent passwd wnn >/dev/null || \ + %{_sbindir}/useradd -r -o -g root -u 66 -s /bin/false \ + -c "Wnn System Account" -d %{_localstatedir}/lib/wnn wnn %pre -n fcwnn %service_add_pre fcwnn.service -%{_sbindir}/useradd -r -o -g root -u 66 -s /bin/false -c "Wnn System Account" -d %{_localstatedir}/lib/wnn wnn 2> /dev/null || : +getent passwd wnn >/dev/null || \ + %{_sbindir}/useradd -r -o -g root -u 66 -s /bin/false \ + -c "Wnn System Account" -d %{_localstatedir}/lib/wnn wnn %preun -n fcwnn %service_del_preun fcwnn.service @@ -337,7 +345,9 @@ chroot . usr/bin/cwnntouch var/lib/wnn/zh_CN/dic/sys/*.* %pre -n ftwnn %service_add_pre ftwnn.service -%{_sbindir}/useradd -r -o -g root -u 66 -s /bin/false -c "Wnn System Account" -d %{_localstatedir}/lib/wnn wnn 2> /dev/null || : +getent passwd wnn >/dev/null || \ + %{_sbindir}/useradd -r -o -g root -u 66 -s /bin/false \ + -c "Wnn System Account" -d %{_localstatedir}/lib/wnn wnn %preun -n ftwnn %service_del_preun ftwnn.service @@ -355,7 +365,9 @@ chroot . usr/bin/cwnntouch var/lib/wnn/zh_TW/dic/sys/*.* %pre -n fkwnn %service_add_pre fkwnn.service -%{_sbindir}/useradd -r -o -g root -u 66 -s /bin/false -c "Wnn System Account" -d %{_localstatedir}/lib/wnn wnn 2> /dev/null || : +getent passwd wnn >/dev/null || \ + %{_sbindir}/useradd -r -o -g root -u 66 -s /bin/false \ + -c "Wnn System Account" -d %{_localstatedir}/lib/wnn wnn %preun -n fkwnn %service_del_preun fkwnn.service