Compare commits

..

1 Commits

Author SHA1 Message Date
Zbigniew Jędrzejewski-Szmek ac43786d5b Release ownership of /var/log/lastlog
/var/log directory is provided by filesystem package, no need to create
it. And systemd >= 235 will create /var/log/lastlog owned by utmp. So
release ownership of the file, and let systemd manage it.

Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1798685.
Similar change in setup: https://pagure.io/setup/pull-request/30.
2022-01-18 16:11:02 +01:00
4 changed files with 46 additions and 114 deletions

7
.gitignore vendored
View File

@ -83,10 +83,3 @@
/util-linux-2.37-rc2.tar.xz
/util-linux-2.37.tar.xz
/util-linux-2.37.2.tar.xz
/util-linux-2.38-rc1.tar.xz
/util-linux-2.38-rc3.tar.xz
/util-linux-2.38.tar.xz
/util-linux-2.38.1.tar.xz
/util-linux-2.39-rc1.tar.xz
/util-linux-2.39-rc2.tar.xz
/util-linux-2.39-rc3.tar.xz

View File

@ -1 +1 @@
SHA512 (util-linux-2.39-rc3.tar.xz) = 8a93d32a5ceb38d50a4b2c8bfa48bcab7ec9b758c89b5a1a4f7fd74558dce37385bd7ea203345148d4389de4ea60ec42058f9d7889a8075d3e616773d085427e
SHA512 (util-linux-2.37.2.tar.xz) = 38f0fe820445e3bfa79550e6581c230f98c7661566ccc4daa51c7208a5f972c61b4e57dfc86bed074fdbc7c40bc79f856be8f6a05a8860c1c0cecc4208e8b81d

View File

@ -1,19 +1,19 @@
### Header
Summary: Collection of basic system utilities
Name: util-linux
Version: 2.39
Release: 0.5%{?dist}
Version: 2.37.2
Release: 1%{?dist}
License: GPLv2 and GPLv2+ and LGPLv2+ and BSD with advertising and Public Domain
URL: https://en.wikipedia.org/wiki/Util-linux
### Macros
%global upstream_version %{version}-rc3
%global upstream_major %(eval echo %{version} | sed -e 's/\([[:digit:]]*\)\.\([[:digit:]]*\)\.[[:digit:]]*$/\1.\2/')
%define upstream_version %{version}
%define upstream_major %(eval echo %{version} | %{__sed} -e 's/\([[:digit:]]*\)\.\([[:digit:]]*\)\.[[:digit:]]*$/\1.\2/')
%global compldir %{_datadir}/bash-completion/completions/
%define compldir %{_datadir}/bash-completion/completions/
%global pypkg python3
%global pyver 3
%define pypkg python3
%define pyver 3
### Dependencies
BuildRequires: make
@ -26,29 +26,32 @@ BuildRequires: pam-devel
BuildRequires: zlib-devel
BuildRequires: popt-devel
BuildRequires: libutempter-devel
BuildRequires: systemd-devel
Buildrequires: systemd-devel
BuildRequires: systemd
BuildRequires: libuser-devel
Buildrequires: libuser-devel
BuildRequires: libcap-ng-devel
BuildRequires: %{pypkg}-devel
BuildRequires: gcc
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: libtool
BuildRequires: bison
BuildRequires: rubygem-asciidoctor
%ifarch ppc64le
BuildRequires: librtas-devel
%endif
# enable if make changes to build-system
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: libtool
BuildRequires: bison
#BuildRequires: autoconf
#BuildRequires: automake
#BuildRequires: libtool
#BuildRequires: bison
### Sources
Source0: https://www.kernel.org/pub/linux/utils/util-linux/v%{upstream_major}/util-linux-%{upstream_version}.tar.xz
Source1: util-linux-login.pamd
Source2: util-linux-remote.pamd
Source3: util-linux-chsh-chfn.pamd
Source4: uuidd-tmpfiles.conf
Source5: adjtime
Source12: util-linux-su.pamd
Source13: util-linux-su-l.pamd
@ -97,12 +100,12 @@ Patch1: login-default-motd-file.patch
%description
The util-linux package contains a large variety of low-level system
utilities that are necessary for a Linux system to function. Among
others, util-linux contains the fdisk configuration tool and the login
others, Util-linux contains the fdisk configuration tool and the login
program.
%package -n util-linux-core
Summary: The most essential utilities from the util-linux suite
Summary: The most essential utilities from the util-linux suite.
License: GPLv2 and GPLv2+ and LGPLv2+ and BSD with advertising and Public Domain
Provides: /bin/dmesg
Provides: /bin/kill
@ -128,7 +131,7 @@ minimal installations.
%package -n libfdisk
Summary: Partitioning library for fdisk-like programs
Summary: Partitioning library for fdisk-like programs.
License: LGPLv2+
%description -n libfdisk
@ -136,7 +139,7 @@ This is library for fdisk-like programs, part of util-linux.
%package -n libfdisk-devel
Summary: Partitioning library for fdisk-like programs
Summary: Partitioning library for fdisk-like programs.
License: LGPLv2+
Requires: libfdisk%{?_isa} = %{version}-%{release}
Requires: pkgconfig
@ -147,7 +150,7 @@ part of util-linux.
%package -n libsmartcols
Summary: Formatting library for ls-like programs
Summary: Formatting library for ls-like programs.
License: LGPLv2+
%description -n libsmartcols
@ -155,7 +158,7 @@ This is library for ls-like terminal programs, part of util-linux.
%package -n libsmartcols-devel
Summary: Formatting library for ls-like programs
Summary: Formatting library for ls-like programs.
License: LGPLv2+
Requires: libsmartcols%{?_isa} = %{version}-%{release}
Requires: pkgconfig
@ -192,6 +195,7 @@ Summary: Block device ID library
License: LGPLv2+
Requires: libuuid%{?_isa} = %{version}-%{release}
Conflicts: filesystem < 3
Requires(post): coreutils
%description -n libblkid
This is block device identification library, part of util-linux.
@ -273,12 +277,12 @@ mountinfo, etc) and mount filesystems.
%package -n util-linux-user
Summary: util-linux utilities based on libuser
Summary: libuser based util-linux utilities
Requires: util-linux = %{version}-%{release}
License: GPLv2
%description -n util-linux-user
chfn and chsh utilities with dependence on libuser.
chfn and chsh utilities with dependence on libuser
%prep
@ -287,8 +291,8 @@ chfn and chsh utilities with dependence on libuser.
%build
unset LINGUAS || :
# enable only when make a change to the build-system
#./autogen.sh
# unfortunately, we did changes to build-system
./autogen.sh
export CFLAGS="-D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 $RPM_OPT_FLAGS"
@ -335,13 +339,11 @@ mkdir -p ${RPM_BUILD_ROOT}%{_bindir}
mkdir -p ${RPM_BUILD_ROOT}%{_mandir}/man{1,6,8,5}
mkdir -p ${RPM_BUILD_ROOT}%{_sbindir}
mkdir -p ${RPM_BUILD_ROOT}%{_sysconfdir}/{pam.d,security/console.apps}
mkdir -p ${RPM_BUILD_ROOT}%{_tmpfilesdir}/tmpfiles.d
# install util-linux
%make_install
# And a dirs uuidd needs that the makefiles don't create
install -m 644 %{SOURCE4} ${RPM_BUILD_ROOT}%{_tmpfilesdir}/uuidd.conf
install -d ${RPM_BUILD_ROOT}/run/uuidd
install -d ${RPM_BUILD_ROOT}/var/lib/libuuid
@ -429,6 +431,22 @@ find $RPM_BUILD_ROOT%{_mandir}/man8 -regextype posix-egrep \
-printf "%{_mandir}/man8/%f*\n" >> %{name}.files
%post -n util-linux-core
if [ ! -L /etc/mtab ]; then
ln -sf ../proc/self/mounts /etc/mtab || :
fi
%post -n libblkid
### Move blkid cache to /run
[ -d /run/blkid ] || mkdir -p /run/blkid
for I in /etc/blkid.tab /etc/blkid.tab.old \
/etc/blkid/blkid.tab /etc/blkid/blkid.tab.old; do
if [ -f "$I" ]; then
mv "$I" /run/blkid/ || :
fi
done
%pre -n uuidd
getent group uuidd >/dev/null || groupadd -r uuidd
getent passwd uuidd >/dev/null || \
@ -490,7 +508,6 @@ fi
%{_bindir}/eject
%{_bindir}/fallocate
%{_bindir}/fincore
%{_bindir}/fadvise
%{_bindir}/getopt
%{_bindir}/hexdump
%{_bindir}/irqtop
@ -500,7 +517,6 @@ fi
%{_bindir}/look
%{_bindir}/lsblk
%{_bindir}/lscpu
%{_bindir}/lsfd
%{_bindir}/lsipc
%{_bindir}/lsirq
%{_bindir}/lslocks
@ -510,7 +526,6 @@ fi
%{_bindir}/mcookie
%{_bindir}/mesg
%{_bindir}/namei
%{_bindir}/pipesz
%{_bindir}/prlimit
%{_bindir}/rename
%{_bindir}/rev
@ -525,7 +540,6 @@ fi
%{_bindir}/utmpdump
%{_bindir}/uuidgen
%{_bindir}/uuidparse
%{_bindir}/waitpid
%{_bindir}/wall
%{_bindir}/wdctl
%{_bindir}/whereis
@ -536,7 +550,6 @@ fi
%{_mandir}/man1/colrm.1*
%{_mandir}/man1/column.1*
%{_mandir}/man1/eject.1*
%{_mandir}/man1/fadvise.1.*
%{_mandir}/man1/fallocate.1*
%{_mandir}/man1/fincore.1*
%{_mandir}/man1/getopt.1*
@ -547,7 +560,6 @@ fi
%{_mandir}/man1/login.1*
%{_mandir}/man1/look.1*
%{_mandir}/man1/lscpu.1*
%{_mandir}/man1/lsfd.1*
%{_mandir}/man1/lsipc.1*
%{_mandir}/man1/lsirq.1*
%{_mandir}/man1/lslogins.1*
@ -555,7 +567,6 @@ fi
%{_mandir}/man1/mcookie.1*
%{_mandir}/man1/mesg.1*
%{_mandir}/man1/namei.1*
%{_mandir}/man1/pipesz.1.*
%{_mandir}/man1/prlimit.1*
%{_mandir}/man1/rename.1*
%{_mandir}/man1/rev.1*
@ -571,7 +582,6 @@ fi
%{_mandir}/man1/utmpdump.1.gz
%{_mandir}/man1/uuidgen.1*
%{_mandir}/man1/uuidparse.1*
%{_mandir}/man1/waitpid.1.*
%{_mandir}/man1/wall.1*
%{_mandir}/man1/whereis.1*
%{_mandir}/man1/write.1*
@ -579,7 +589,6 @@ fi
%{_mandir}/man5/terminal-colors.d.5*
%{_mandir}/man8/addpart.8*
%{_mandir}/man8/blkdiscard.8*
%{_mandir}/man8/blkpr.8.*
%{_mandir}/man8/blkzone.8*
%{_mandir}/man8/chcpu.8*
%{_mandir}/man8/chmem.8*
@ -613,7 +622,6 @@ fi
%{_mandir}/man8/zramctl.8*
%{_sbindir}/addpart
%{_sbindir}/blkdiscard
%{_sbindir}/blkpr
%{_sbindir}/blkzone
%{_sbindir}/chcpu
%{_sbindir}/ctrlaltdel
@ -666,7 +674,6 @@ fi
%{compldir}/irqtop
%{compldir}/isosize
%{compldir}/last
%{compldir}/lastb
%{compldir}/ldattach
%{compldir}/look
%{compldir}/lsblk
@ -683,7 +690,6 @@ fi
%{compldir}/mkfs.cramfs
%{compldir}/mkfs.minix
%{compldir}/namei
%{compldir}/pipesz
%{compldir}/pivot_root
%{compldir}/prlimit
%{compldir}/readprofile
@ -740,6 +746,7 @@ fi
%files -n util-linux-core
%ghost %verify(not md5 size mtime) %config(noreplace,missingok) /etc/mtab
%attr(4755,root,root) %{_bindir}/mount
%attr(4755,root,root) %{_bindir}/umount
%{_bindir}/chrt
@ -825,7 +832,6 @@ fi
%{_sbindir}/swapoff
%{_sbindir}/swapon
%{_sbindir}/switch_root
/etc/mtab
%files -n util-linux-user
@ -847,7 +853,6 @@ fi
%dir %attr(2775, uuidd, uuidd) /var/lib/libuuid
%dir %attr(2775, uuidd, uuidd) /run/uuidd
%{compldir}/uuidd
%{_tmpfilesdir}/uuidd.conf
%files -n libfdisk
@ -918,71 +923,6 @@ fi
%{_libdir}/python*/site-packages/libmount/
%changelog
* Wed Apr 19 2023 Karel Zak <kzak@redhat.com> - 2.39-0.5
- upgrade to v2.39-rc3 (fixes XFS and rw/ro issues)
* Wed Apr 5 2023 Karel Zak <kzak@redhat.com> - 2.39-0.4
- fix #2180593 (superblock reconfiguration libmount issue)
* Tue Apr 4 2023 Karel Zak <kzak@redhat.com> - 2.39-0.3
- fix spec file
* Tue Apr 4 2023 Karel Zak <kzak@redhat.com> - 2.39-0.2
- upgrade to v2.39-rc2
* Mon Mar 20 2023 Karel Zak <kzak@redhat.com> - 2.39-0.1
- upgrade to v2.39-rc1
https://kernel.org/pub/linux/utils/util-linux/v2.39/v2.39-ReleaseNotes
* Sat Jan 21 2023 Fedora Release Engineering <releng@fedoraproject.org> - 2.38.1-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
* Sat Dec 17 2022 Florian Weimer <fweimer@redhat.com> - 2.38.1-3
- Backport upstream patch to fix C99 issue in kill
* Mon Aug 22 2022 Karel Zak <kzak@redhat.com> - 2.38.1-2
- improve tmpfiles.d use in spec file
* Thu Aug 4 2022 Karel Zak <kzak@redhat.com> - 2.38.1-1
- upgrade to v2.38.1
https://kernel.org/pub/linux/utils/util-linux/v2.38/v2.38.1-ReleaseNotes
* Sat Jul 23 2022 Fedora Release Engineering <releng@fedoraproject.org> - 2.38-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
* Mon Jun 13 2022 Python Maint <python-maint@redhat.com> - 2.38-4
- Rebuilt for Python 3.11
* Wed Apr 13 2022 Karel Zak <kzak@redhat.com> - 2.38-3
- fix spec file changelog order
* Wed Mar 30 2022 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 2.38-2
- simplify creation of /etc/mtab symlink
* Wed Mar 30 2022 Karel Zak <kzak@redhat.com> - 2.38-1
- upgrade to v2.38
- don't (re)generate build-system
- modernize spec file style (thanks to Zbigniew)
* Thu Mar 17 2022 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 2.38-0.5
- Drop very old upgrade scriptlet for libblkid
* Wed Mar 16 2022 Karel Zak <kzak@redhat.com> - 2.38-0.4
- upgrade to v2.38-rc3
https://mirrors.edge.kernel.org/pub/linux/utils/util-linux/v2.38/v2.38-ReleaseNotes
* Wed Feb 2 2022 Karel Zak <kzak@redhat.com> - 2.38-0.3
- add /usr/lib/tmpfiles.d/uuidd.conf (based on #2047952)
* Wed Feb 2 2022 Karel Zak <kzak@redhat.com> - 2.38-0.2
- release ownership of /var/log/lastlog
* Mon Jan 31 2022 Karel Zak <kzak@redhat.com> - 2.38-0.1
- upgrade to v2.38-rc1
* Sat Jan 22 2022 Fedora Release Engineering <releng@fedoraproject.org> - 2.37.2-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
* Tue Aug 17 2021 Karel Zak <kzak@redhat.com> - 2.37.2-1
* upgrade to v2.37.2

View File

@ -1 +0,0 @@
d /run/uuidd 2775 uuidd uuidd