SPECS: users.spec (HEAD)

Tomasz Pala gotar w polanet.pl
Śro, 20 Sie 2003, 11:39:45 CEST


On Wed, Aug 20, 2003 at 10:35:20 +0200, Andrzej Krzysztofowicz wrote:

> > ~/rpm-0/SPECS-all: grep "useradd -" * | grep -v "Requires(pre)" | wc -l
> >     110
> 
> Przesadzasz. wrapper jest potrzebny tylko dla specow, w ktorych sa dodawani
> userzy wystepujacy rowniez w innych specach. A takich jest duuuzo mniej

Tak?

~/rpm/SPECS-all: for i in *.spec; grep -q mldonkey $i && echo $i
kmldonkey.spec
mldonkey.spec
users.spec

To spójrzmy:

~/rpm-0/SPECS-all: grep -e "group\|user"add kmldonkey.spec
~/rpm-0/SPECS-all:

Pusto. Zaś w mldonkey.spec:

%pre
if [ -n "`getgid mldonkey`" ]; then
        if [ "`getgid mldonkey`" != "33" ]; then
                echo "Error: group mldonkey doesn't have gid=33. Correct this before installing mldo                exit 1
        fi
else
        /usr/sbin/groupadd -g 33 -r -f mldonkey
fi

if [ -n "`id -u mldonkey 2>/dev/null`" ]; then
        if [ "`id -u mldonkey`" != "47" ]; then
                echo "Error: user mldonkey doesn't have uid=47. Correct this before installing mldon                exit 1
        fi
else
        /usr/sbin/useradd -m -o -r -u 47 \
                -d /home/services/mldonkey -s /bin/sh -g mldonkey \
                -c "mldonkey" mldonkey 1>&2
fi

Że niby TO nie wymaga wrappera!?!?!?

-- 
GoTaR <priv0.onet.pl->gotar>           USA sux
      http://mops.uci.agh.edu.pl/~gotar/
GEOS:.  http://informatica.agh.edu.pl/  .:LF&A



Więcej informacji o liście dyskusyjnej pld-devel-pl