- Enable /bin/login and obsolete old fork now merged back upstream.

OBS-URL: https://build.opensuse.org/package/show/Base:System/util-linux?expand=0&rev=124
This commit is contained in:
Thorsten Kukuk 2012-03-14 14:25:45 +00:00 committed by Git OBS Bridge
parent b71bcabe24
commit 224d1b1111
4 changed files with 49 additions and 4 deletions

10
login.pamd Normal file
View File

@ -0,0 +1,10 @@
#%PAM-1.0
auth requisite pam_nologin.so
auth [user_unknown=ignore success=ok ignore=ignore auth_err=die default=bad] pam_securetty.so
auth include common-auth
account include common-account
password include common-password
session required pam_loginuid.so
session include common-session
session optional pam_lastlog.so nowtmp showfailed
session optional pam_mail.so standard

12
remote.pamd Normal file
View File

@ -0,0 +1,12 @@
#%PAM-1.0
# This file is used by /bin/login in case of remote logins (means where
# the -h option is used
auth requisite pam_nologin.so
auth [user_unknown=ignore success=ok ignore=ignore auth_err=die default=bad] pam_securetty.so
auth include common-auth
account include common-account
password include common-password
session required pam_loginuid.so
session include common-session
session optional pam_lastlog.so nowtmp showfailed
session optional pam_mail.so standard

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Tue Mar 13 16:38:34 CET 2012 - kukuk@suse.de
- Enable /bin/login and obsolete old fork now merged back.
------------------------------------------------------------------- -------------------------------------------------------------------
Tue Mar 6 21:18:56 UTC 2012 - rschweikert@suse.com Tue Mar 6 21:18:56 UTC 2012 - rschweikert@suse.com

View File

@ -52,15 +52,17 @@ License: GPL-2.0+
Group: System/Base Group: System/Base
Source: ftp://ftp.kernel.org/pub/linux/utils/util-linux/v2.21/%{name}-%{version}.tar.bz2 Source: ftp://ftp.kernel.org/pub/linux/utils/util-linux/v2.21/%{name}-%{version}.tar.bz2
Source1: util-linux-rpmlintrc Source1: util-linux-rpmlintrc
# XXX: make nologin part of login package # XXX: make nologin part of util-linux upstream
Source2: nologin.c Source2: nologin.c
Source3: nologin.8 Source3: nologin.8
Source4: raw.init Source4: raw.init
Source5: etc.raw Source5: etc.raw
Source6: etc_filesystems Source6: etc_filesystems
Source7: baselibs.conf Source7: baselibs.conf
Source8: login.pamd
Source9: remote.pamd
# TODO: split to separate package # TODO: split to separate package
Source9: http://ftp.debian.org/debian/pool/main/a/adjtimex/adjtimex_%{adjtimex_ver}.orig.tar.gz Source10: http://ftp.debian.org/debian/pool/main/a/adjtimex/adjtimex_%{adjtimex_ver}.orig.tar.gz
Source11: klogconsole.tar.bz2 Source11: klogconsole.tar.bz2
# TODO: split to separate package # TODO: split to separate package
Source12: which-%{which_ver}.tar.bz2 Source12: which-%{which_ver}.tar.bz2
@ -107,11 +109,13 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-build
PreReq: %insserv_prereq %fillup_prereq /bin/sed PreReq: %insserv_prereq %fillup_prereq /bin/sed
# #
Provides: base = %{version}-%{release} Provides: base = %{version}-%{release}
Provides: login = 4.0-13.4
Provides: raw = %{version}-%{release} Provides: raw = %{version}-%{release}
Provides: rawio = %{version}-%{release} Provides: rawio = %{version}-%{release}
Provides: util = %{version}-%{release} Provides: util = %{version}-%{release}
Provides: uuid-runtime = %{version}-%{release} Provides: uuid-runtime = %{version}-%{release}
Obsoletes: base < %{version}-%{release} Obsoletes: base < %{version}-%{release}
Obsoletes: login < 4.0-13.4
Obsoletes: raw < %{version}-%{release} Obsoletes: raw < %{version}-%{release}
Obsoletes: rawio < %{version}-%{release} Obsoletes: rawio < %{version}-%{release}
Obsoletes: util < %{version}-%{release} Obsoletes: util < %{version}-%{release}
@ -185,7 +189,7 @@ Files to develop applications using the libmount library.
%lang_package %lang_package
%prep %prep
%setup -q -n %{name}-%{version} -a 9 -b 11 -b 12 -b 13 %setup -q -n %{name}-%{version} -a 10 -b 11 -b 12 -b 13
%patch1 -p1 %patch1 -p1
%patch2 -p1 %patch2 -p1
%patch3 -p1 %patch3 -p1
@ -252,6 +256,7 @@ export SUID_LDFLAGS="-pie"
--enable-line \ --enable-line \
--enable-libmount-mount \ --enable-libmount-mount \
--enable-ddate \ --enable-ddate \
--enable-login-utils \
--disable-mountpoint \ --disable-mountpoint \
--disable-use-tty-group \ --disable-use-tty-group \
--disable-static \ --disable-static \
@ -265,11 +270,13 @@ make %{?_smp_mflags}
%{__cc} -fwhole-program %{optflags} -o chrp-addnote %{SOURCE31} %{__cc} -fwhole-program %{optflags} -o chrp-addnote %{SOURCE31}
%install %install
mkdir -p %{buildroot}{/etc/init.d,%{_mandir}/man{1,8},/bin,/sbin,/usr/bin,/usr/sbin,%{_infodir}} mkdir -p %{buildroot}{/etc/init.d,/etc/pam.d,%{_mandir}/man{1,8},/bin,/sbin,/usr/bin,/usr/sbin,%{_infodir}}
mkdir -p %{buildroot}%{_localstatedir}/lib/libuuid/ mkdir -p %{buildroot}%{_localstatedir}/lib/libuuid/
mkdir -p %{buildroot}%{_localstatedir}/run/uuidd/ mkdir -p %{buildroot}%{_localstatedir}/run/uuidd/
install -m 744 %{SOURCE50} %{buildroot}%{_initddir}/uuidd install -m 744 %{SOURCE50} %{buildroot}%{_initddir}/uuidd
install -m 644 %{SOURCE51} %{buildroot}%{_sysconfdir}/blkid.conf install -m 644 %{SOURCE51} %{buildroot}%{_sysconfdir}/blkid.conf
install -m 644 %{SOURCE8} %{buildroot}/etc/pam.d/login
install -m 644 %{SOURCE9} %{buildroot}/etc/pam.d/remote
mkdir -p %{buildroot}%{_localstatedir}/adm/fillup-templates mkdir -p %{buildroot}%{_localstatedir}/adm/fillup-templates
cp adjtimex-*/adjtimex %{buildroot}/%{_sbindir} cp adjtimex-*/adjtimex %{buildroot}/%{_sbindir}
cp adjtimex-*/adjtimex.8 %{buildroot}%{_mandir}/man8/ cp adjtimex-*/adjtimex.8 %{buildroot}%{_mandir}/man8/
@ -372,6 +379,13 @@ rm -f %{buildroot}%{_mandir}/man1/pg.1*
# Do not package these files to get rid of the perl dependency # Do not package these files to get rid of the perl dependency
rm -f %{buildroot}%{_bindir}/chkdupexe rm -f %{buildroot}%{_bindir}/chkdupexe
rm -f %{buildroot}%{_mandir}/man1/chkdupexe.1 rm -f %{buildroot}%{_mandir}/man1/chkdupexe.1
# we use this tools from pwdutils
rm -f %{buildroot}/%{_bindir}/{chfn,chsh,newgrp}
rm -f %{buildroot}/%{_sbindir}/{vigr,vipw}
rm -f %{buildroot}/%{_mandir}/man1/{chfn.1*,chsh.1*,newgrp.1*}
rm -f %{buildroot}/%{_mandir}/man8/{vigr.8*,vipw.8*}
# login is always and only in /bin
mv %{buildroot}/%{_bindir}/login %{buildroot}/bin/
# arch dependent # arch dependent
%ifarch s390 s390x %ifarch s390 s390x
rm -f %{buildroot}%{_sysconfdir}/fdprm rm -f %{buildroot}%{_sysconfdir}/fdprm
@ -507,6 +521,8 @@ fi
%config(noreplace) %attr(644,root,root) %{_sysconfdir}/raw %config(noreplace) %attr(644,root,root) %{_sysconfdir}/raw
%config(noreplace) %{_sysconfdir}/filesystems %config(noreplace) %{_sysconfdir}/filesystems
%config(noreplace) %{_sysconfdir}/blkid.conf %config(noreplace) %{_sysconfdir}/blkid.conf
%config(noreplace) /etc/pam.d/login
%config(noreplace) /etc/pam.d/remote
#UsrMerge #UsrMerge
/bin/dmesg /bin/dmesg
/bin/more /bin/more
@ -514,6 +530,7 @@ fi
/bin/umount /bin/umount
/bin/findmnt /bin/findmnt
/bin/logger /bin/logger
/bin/login
/bin/lsblk /bin/lsblk
/sbin/adjtimex /sbin/adjtimex
/sbin/agetty /sbin/agetty
@ -648,6 +665,7 @@ fi
%{_mandir}/man1/ipcs.1.gz %{_mandir}/man1/ipcs.1.gz
%{_mandir}/man1/line.1.gz %{_mandir}/man1/line.1.gz
%{_mandir}/man1/logger.1.gz %{_mandir}/man1/logger.1.gz
%{_mandir}/man1/login.1.gz
%{_mandir}/man1/look.1.gz %{_mandir}/man1/look.1.gz
%{_mandir}/man1/lscpu.1.gz %{_mandir}/man1/lscpu.1.gz
%{_mandir}/man1/mcookie.1.gz %{_mandir}/man1/mcookie.1.gz