From 88ac25c576fdf5953224746fbb10e3a0640ef7d77b296a11b6de81fd53a97216 Mon Sep 17 00:00:00 2001 From: Egbert Eich Date: Thu, 8 Mar 2018 21:09:39 +0000 Subject: [PATCH] Accepting request 584535 from home:eeich:branches:network:cluster - Do not look for the ttyS* group - it should be dialout always (boo#1084571). - Fix shebang - remove /usr/bin/env. OBS-URL: https://build.opensuse.org/request/show/584535 OBS-URL: https://build.opensuse.org/package/show/network:cluster/conman?expand=0&rev=25 --- conman.changes | 7 +++++++ conman.spec | 7 +++---- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/conman.changes b/conman.changes index 81d85e4..58ed269 100644 --- a/conman.changes +++ b/conman.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Thu Mar 8 20:14:50 UTC 2018 - eich@suse.com + +- Do not look for the ttyS* group - it should be dialout + always (boo#1084571). +- Fix shebang - remove /usr/bin/env. + ------------------------------------------------------------------- Fri Feb 16 13:15:00 UTC 2018 - eich@suse.com diff --git a/conman.spec b/conman.spec index 64ef5bd..0f35069 100644 --- a/conman.spec +++ b/conman.spec @@ -131,6 +131,8 @@ for i in $(find %{buildroot}/usr/lib/conman) ; do fi fi done +sed -i -e '1 s@#!.*/bin/env perl@#!%{_bindir}/perl@' \ + %{buildroot}%{_bindir}/conmen %if 0%{?conmandir:1} mkdir -p %{buildroot}%{_tmpfilesdir} @@ -161,16 +163,13 @@ fi %define conman_home "%_localstatedir%_rundir/%conmandir" %define conman_descr "Connection Manager service" shopt -s nullglob -for i in /dev/ttyS[0-9] /dev/ttyS[1-9][0-9] -do TTYS_GRP=$(stat --format="%G" $i); break -done addgrp=0; addusr=0 getent group %conman_g >/dev/null || addgrp=1 [ $addgrp -eq 1 ] && groupadd -r %conman_g getent passwd %conman_u >/dev/null || addusr=1 [ $addusr -eq 1 ] && useradd -r -g %conman_g -d %conman_home \ -s /bin/false -c %conman_descr %conman_u -[ -n "$TTYS_GRP" ] && usermod -a -G $TTYS_GRP %conman_u +usermod -a -G dialout %conman_u %endif exit 0 %endif