]>
Commit | Line | Data |
---|---|---|
714e50f5 MT |
1 | ############################################################################### |
2 | # # | |
3 | # IPFire.org - A linux based firewall # | |
4 | # Copyright (C) 2007, 2008 Michael Tremer & Christian Schmidt # | |
5 | # # | |
6 | # This program is free software: you can redistribute it and/or modify # | |
7 | # it under the terms of the GNU General Public License as published by # | |
8 | # the Free Software Foundation, either version 3 of the License, or # | |
9 | # (at your option) any later version. # | |
10 | # # | |
11 | # This program is distributed in the hope that it will be useful, # | |
12 | # but WITHOUT ANY WARRANTY; without even the implied warranty of # | |
13 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # | |
14 | # GNU General Public License for more details. # | |
15 | # # | |
16 | # You should have received a copy of the GNU General Public License # | |
17 | # along with this program. If not, see <http://www.gnu.org/licenses/>. # | |
18 | # # | |
19 | ############################################################################### | |
20 | ||
21 | ############################################################################### | |
22 | # Definitions | |
23 | ############################################################################### | |
24 | ||
25 | include $(PKGROOT)/Include | |
26 | ||
3e3816c3 | 27 | PKG_NAME = shadow-utils |
bbaafb6b | 28 | PKG_VER = 4.1.4.3 |
3e3816c3 | 29 | PKG_REL = 1 |
714e50f5 | 30 | |
3e3816c3 MT |
31 | PKG_MAINTAINER = Michael Tremer <michael.tremer@ipfire.org> |
32 | PKG_GROUPS = Base System/Base | |
714e50f5 MT |
33 | PKG_URL = ftp://pkg-shadow.alioth.debian.org/pub/pkg-shadow/ |
34 | PKG_LICENSE = GPLv2+ | |
35 | PKG_SUMMARY = Utilities to deal with user accounts. | |
36 | ||
5f157e9d | 37 | PKG_BUILD_DEPS+= audit-devel libcap-devel libselinux-devel |
3e3816c3 | 38 | PKG_OBSOLETES += shadow |
bd15364e | 39 | |
714e50f5 MT |
40 | define PKG_DESCRIPTION |
41 | The shadow-utils package includes the necessary programs \ | |
42 | for converting UNIX password files to the shadow password \ | |
43 | format, plus programs for managing user and group accounts. | |
44 | endef | |
45 | ||
3e3816c3 | 46 | THISAPP = shadow-$(PKG_VER) |
714e50f5 MT |
47 | PKG_TARBALL = $(THISAPP).tar.bz2 |
48 | ||
714e50f5 MT |
49 | CONFIGURE_OPTIONS += \ |
50 | --sysconfdir=/etc \ | |
51 | --enable-shadowgrp \ | |
52 | --with-sha-crypt \ | |
5f157e9d | 53 | --with-selinux \ |
714e50f5 MT |
54 | --without-libcrack \ |
55 | --without-libpam \ | |
56 | --disable-static | |
57 | ||
714e50f5 MT |
58 | define STAGE_PREPARE_CMDS |
59 | # Do not build these files: | |
60 | cd $(DIR_APP) && \ | |
61 | for i in nologin chfn chgpasswd chpasswd chsh expiry gpasswd groups login \ | |
62 | logoutd passwd su; do \ | |
63 | sed -i "s/$$i\$$(EXEEXT)//" src/Makefile.in; \ | |
64 | find man -name Makefile.in -exec sed -i "s/$$i\.1/ /" {} \;; \ | |
65 | done | |
66 | cd $(DIR_APP) && sed -i src/Makefile.in \ | |
67 | -e "s/^suidbins.*/# &/" -e "s/^suidubins.*/# &/" | |
68 | ||
69 | # Do not install korean and zh man pages | |
70 | cd $(DIR_APP) && sed -i -e 's/ ko//' -e 's/ zh_CN zh_TW//' man/Makefile.in | |
bbaafb6b SS |
71 | |
72 | # Do not install russion man pages - was broken in 4.1.4.3 | |
73 | cd $(DIR_APP) && sed -i -e 's/ ru//' man/Makefile.in | |
714e50f5 MT |
74 | endef |
75 | ||
76 | define STAGE_INSTALL_CMDS | |
77 | # Remove man pages in other languages | |
78 | rm -rfv $(BUILDROOT)/usr/share/man/{cs,de,fi,fr,hu,id,it,ja,pl,pt_BR,ru,sv,tr} | |
4c113bd2 | 79 | endef |
bd15364e | 80 | |
4c113bd2 | 81 | define STAGE_INSTALL_POST |
bd15364e MT |
82 | # Capabilities |
83 | chmod u-s $(BUILDROOT)/usr/bin/chage | |
84 | setcap cap_dac_read_search+ep $(BUILDROOT)/usr/bin/chage | |
85 | ||
86 | chmod u-s $(BUILDROOT)/usr/bin/newgrp | |
87 | setcap cap_dac_override,cap_setgid+ep $(BUILDROOT)/usr/bin/newgrp | |
a4de5755 MT |
88 | |
89 | # Configuration | |
90 | install -p -c -m 0644 $(DIR_SOURCE)/login.defs $(BUILDROOT)/etc/login.defs | |
714e50f5 | 91 | endef |