|
|
6521d1 |
%global pkg ecryptfs
|
|
|
6521d1 |
|
|
Kmods SIG |
c540c3 |
%global driver_version 4.18.0-277.el8
|
|
Kmods SIG |
c540c3 |
|
|
|
6521d1 |
%global kernel_version 4.18.0-348.el8
|
|
|
6521d1 |
|
|
|
6521d1 |
%global _use_internal_dependency_generator 0
|
|
|
6521d1 |
%global __find_requires /usr/lib/rpm/redhat/find-requires
|
|
|
6521d1 |
%global __find_provides /usr/lib/rpm/redhat/find-provides
|
|
|
6521d1 |
|
|
|
6521d1 |
%global debug_package %{nil}
|
|
|
6521d1 |
|
|
|
6521d1 |
%global __spec_install_post \
|
|
|
6521d1 |
%{?__debug_package:%{__debug_install_post}} \
|
|
|
6521d1 |
%{__arch_install_post} \
|
|
|
6521d1 |
%{__os_install_post} \
|
|
|
6521d1 |
%{__mod_compress_install_post}
|
|
|
6521d1 |
|
|
|
6521d1 |
%global __mod_compress_install_post find %{buildroot}/lib/modules -type f -name \*.ko -exec xz \{\} \\;
|
|
|
6521d1 |
|
|
|
6521d1 |
|
|
|
6521d1 |
Name: kmod-%{pkg}
|
|
Kmods SIG |
c540c3 |
Version: 4.18.0.277
|
|
|
6521d1 |
Release: 1%{?dist}
|
|
|
6521d1 |
Summary: Encrypted filesystem that operates on the VFS layer
|
|
|
6521d1 |
|
|
|
6521d1 |
License: GPLv2
|
|
|
6521d1 |
URL: https://www.kernel.org/
|
|
|
6521d1 |
|
|
Kmods SIG |
c540c3 |
Source0: %{pkg}-%{driver_version}.tar.xz
|
|
Kmods SIG |
c540c3 |
Patch1: 0001-ecryptfs_rename-verify-that-lower-dentries-are-still.patch
|
|
Kmods SIG |
c540c3 |
Patch2: 0002-crypto-shash-remove-shash_desc-flags.patch
|
|
Kmods SIG |
c540c3 |
Patch3: 0003-eCryptfs-fix-a-couple-type-promotion-bugs.patch
|
|
Kmods SIG |
c540c3 |
Patch4: 0004-eCryptfs-fix-permission-denied-with-ecryptfs_xattr-m.patch
|
|
Kmods SIG |
c540c3 |
Patch5: 0005-ecryptfs-fix-unlink-and-rmdir-in-face-of-underlying-.patch
|
|
Kmods SIG |
c540c3 |
Patch6: 0006-ecryptfs_lookup_interpose-lower_dentry-d_inode-is-no.patch
|
|
Kmods SIG |
c540c3 |
Patch7: 0007-ecryptfs_lookup_interpose-lower_dentry-d_parent-is-n.patch
|
|
Kmods SIG |
c540c3 |
Patch8: 0008-ecryptfs-fix-a-memory-leak-bug-in-parse_tag_1_packet.patch
|
|
Kmods SIG |
c540c3 |
Patch9: 0009-ecryptfs-fix-a-memory-leak-bug-in-ecryptfs_init_mess.patch
|
|
Kmods SIG |
c540c3 |
Patch10: 0010-ecryptfs-fix-kernel-panic-with-null-dev_name.patch
|
|
Kmods SIG |
c540c3 |
Patch11: 0011-fs-ecryptfs-remove-BUG_ON-from-crypt_scatterlist.patch
|
|
Kmods SIG |
c540c3 |
Patch9999: 9999-enable-ecryptfs.patch
|
|
|
6521d1 |
|
|
|
6521d1 |
ExclusiveArch: x86_64 aarch64
|
|
|
6521d1 |
|
|
|
6521d1 |
BuildRequires: elfutils-libelf-devel
|
|
|
6521d1 |
BuildRequires: gcc
|
|
|
6521d1 |
BuildRequires: kernel-rpm-macros
|
|
|
6521d1 |
BuildRequires: kmod
|
|
|
6521d1 |
BuildRequires: make
|
|
|
6521d1 |
BuildRequires: redhat-rpm-config
|
|
|
6521d1 |
BuildRequires: xz
|
|
|
6521d1 |
|
|
|
6521d1 |
BuildRequires: kernel-abi-stablelists = %{kernel_version}
|
|
|
6521d1 |
BuildRequires: kernel-devel = %{kernel_version}
|
|
|
6521d1 |
BuildRequires: kernel-devel-uname-r = %{kernel_version}.%{_arch}
|
|
|
6521d1 |
|
|
|
6521d1 |
Requires: kernel >= %{kernel_version}
|
|
|
6521d1 |
Requires: kernel-uname-r >= %{kernel_version}.%{_arch}
|
|
|
6521d1 |
Requires: kernel-modules >= %{kernel_version}
|
|
|
6521d1 |
Requires: kernel-modules-uname-r >= %{kernel_version}.%{_arch}
|
|
|
6521d1 |
|
|
|
6521d1 |
Provides: installonlypkg(kernel-module)
|
|
|
6521d1 |
Provides: kernel-modules >= %{kernel_version}.%{_arch}
|
|
|
6521d1 |
|
|
|
6521d1 |
Requires(post): %{_sbindir}/depmod
|
|
|
6521d1 |
Requires(postun): %{_sbindir}/depmod
|
|
|
6521d1 |
|
|
|
6521d1 |
Requires(post): %{_sbindir}/weak-modules
|
|
|
6521d1 |
Requires(postun): %{_sbindir}/weak-modules
|
|
|
6521d1 |
|
|
|
6521d1 |
Supplements: ecryptfs-utils
|
|
|
6521d1 |
Recommends: ecryptfs-utils
|
|
|
6521d1 |
|
|
|
6521d1 |
|
|
|
6521d1 |
%description
|
|
|
6521d1 |
This package provides the required kernel module (ecryptfs) to mount devices
|
|
|
6521d1 |
formatted with the Encrypted filesystem that operates on the VFS layer.
|
|
|
6521d1 |
|
|
|
6521d1 |
|
|
|
6521d1 |
%prep
|
|
Kmods SIG |
c540c3 |
%autosetup -p1 -n %{pkg}-%{driver_version}
|
|
|
6521d1 |
|
|
|
6521d1 |
|
|
|
6521d1 |
%build
|
|
|
6521d1 |
pushd src
|
|
|
6521d1 |
%{__make} -C /usr/src/kernels/%{kernel_version}.%{_arch} %{?_smp_mflags} M=$PWD modules
|
|
|
6521d1 |
popd
|
|
|
6521d1 |
|
|
|
6521d1 |
|
|
|
6521d1 |
%install
|
|
|
7f43f5 |
%{__install} -D -t %{buildroot}/lib/modules/%{kernel_version}.%{_arch}/extra/fs/%{pkg} src/%{pkg}.ko
|
|
|
6521d1 |
|
|
|
6521d1 |
# Make .ko objects temporarily executable for automatic stripping
|
|
|
6521d1 |
find %{buildroot}/lib/modules -type f -name \*.ko -exec chmod u+x \{\} \+
|
|
|
6521d1 |
|
|
|
6521d1 |
|
|
|
6521d1 |
%clean
|
|
|
6521d1 |
%{__rm} -rf %{buildroot}
|
|
|
6521d1 |
|
|
|
6521d1 |
|
|
|
6521d1 |
%post
|
|
|
6521d1 |
mkdir -p %{_localstatedir}/lib/rpm-state/sig-kmods
|
|
|
7f43f5 |
printf '%s\n' "/lib/modules/%{kernel_version}.%{_arch}/extra/fs/%{pkg}/%{pkg}.ko.xz" >> %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-add
|
|
|
6521d1 |
|
|
|
6521d1 |
|
|
|
6521d1 |
%preun
|
|
|
6521d1 |
mkdir -p %{_localstatedir}/lib/rpm-state/sig-kmods
|
|
|
6521d1 |
rpm -ql kmod-%{pkg}-%{?epoch:%{epoch}:}%{version}-%{release}.%{_arch} | grep '/lib/modules/%{kernel_version}.%{_arch}/.*\.ko\.xz$' >> %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-remove
|
|
|
6521d1 |
|
|
|
6521d1 |
|
|
|
6521d1 |
%postun
|
|
|
6521d1 |
if [ -f %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-remove ]
|
|
|
6521d1 |
then
|
|
|
6521d1 |
modules=( $(cat %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-remove) )
|
|
|
6521d1 |
rm -f %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-remove
|
|
|
6521d1 |
rmdir --ignore-fail-on-non-empty %{_localstatedir}/lib/rpm-state/sig-kmods
|
|
|
6521d1 |
printf '%s\n' "${modules[@]}" | %{_sbindir}/weak-modules --remove-modules
|
|
|
6521d1 |
fi
|
|
|
6521d1 |
|
|
|
6521d1 |
|
|
|
6521d1 |
%pretrans -p <lua>
|
|
|
6521d1 |
posix.unlink("%{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-add")
|
|
|
6521d1 |
posix.unlink("%{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-remove")
|
|
|
6521d1 |
|
|
|
6521d1 |
|
|
|
6521d1 |
%posttrans
|
|
|
6521d1 |
if [ -f %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-add ]
|
|
|
6521d1 |
then
|
|
|
6521d1 |
modules=( $(cat %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-add) )
|
|
|
6521d1 |
rm -f %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-add
|
|
|
6521d1 |
rmdir --ignore-fail-on-non-empty %{_localstatedir}/lib/rpm-state/sig-kmods
|
|
|
6521d1 |
printf '%s\n' "${modules[@]}" | %{_sbindir}/weak-modules --add-modules
|
|
|
6521d1 |
fi
|
|
|
6521d1 |
|
|
|
6521d1 |
|
|
|
6521d1 |
%files
|
|
|
6521d1 |
%defattr(644,root,root,755)
|
|
|
6521d1 |
/lib/modules/%{kernel_version}.%{_arch}
|
|
|
63eace |
%license LICENSES
|
|
|
6521d1 |
|
|
|
6521d1 |
|
|
|
6521d1 |
%changelog
|
|
Kmods SIG |
c540c3 |
* Wed Jan 12 2022 Kmods SIG <sig-kmods@centosproject.org> - 4.18.0.277-1
|
|
Kmods SIG |
c540c3 |
- Switch to EL kernel source and versioning
|
|
Kmods SIG |
c540c3 |
- kABI tracking kmod package (kernel >= 4.18.0-348.el8)
|