1 # Description: Shadow password file utilities
2 # URL: https://github.com/shadow-maint/shadow/
3 # Maintainer: CRUX System Team, core-ports at crux dot nu
4 # Depends on: acl linux-pam
5
6 name=shadow
7 version=4.11.1
8 release=1
9 source=(https://github.com/shadow-maint/$name/releases/download/v$version/$name-$version.tar.xz \
10 pwck login.defs chfn chsh login groupadd groupdel \
11 groupmems groupmod passwd su useradd userdel usermod)
12
13 build() {
14 cd $name-$version
15
16 ./configure \
17 --prefix=/usr \
18 --bindir=/usr/bin \
19 --sbindir=/usr/sbin \
20 --sysconfdir=/etc \
21 --disable-shared \
22 --disable-shadowgrp \
23 --disable-nls \
24 --without-selinux \
25 --without-audit
26
27 make
28 make DESTDIR=$PKG install
29 make -C man DESTDIR=$PKG install
30
31 install -d $PKG/{bin,sbin}
32 mv $PKG/usr/bin/login $PKG/bin
33 mv $PKG/usr/sbin/nologin $PKG/sbin
34 chmod -s $PKG/usr/sbin/*
35
36 install -d $PKG/etc/cron/daily $PKG/var/log
37 install -m 644 $SRC/login.defs $PKG/etc
38 install -m 755 $SRC/pwck $PKG/etc/cron/daily
39 touch $PKG/var/log/{lastlog,faillog}
40
41 rm -r $PKG/usr/bin/gpasswd \
42 $PKG/usr/sbin/{chpasswd,grpconv,grpunconv,logoutd} \
43 $PKG/usr/sbin/{newusers,pwconv,pwunconv} \
44 $PKG/usr/share/man/man1/gpasswd.1 \
45 $PKG/usr/share/man/man8/{chpasswd.8,grpconv.8,grpunconv.8,logoutd.8} \
46 $PKG/usr/share/man/man8/{newusers.8,pwconv.8,pwunconv.8} \
47 $PKG/usr/share/man/man5/gshadow.5 \
48 $PKG/usr/share/man/man3
49
50 install -o root -g root -m 0644 \
51 $SRC/{ch{fn,sh},login,group{add,del,mems,mod},passwd,su,user{add,del,mod}} \
52 $PKG/etc/pam.d/
53 }
|