the ".uname" file is not needed anymore

This commit is contained in:
Pratham Patel 2023-10-15 19:25:13 +05:30
parent bae4cb3ee1
commit 6ee5d31442
No known key found for this signature in database

View File

@ -118,7 +118,6 @@ mkdir -p %{buildroot}
mkdir -p %{buildroot}/boot mkdir -p %{buildroot}/boot
cp $(%{make} -s image_name) %{buildroot}/boot/vmlinuz-%{KVERREL} cp $(%{make} -s image_name) %{buildroot}/boot/vmlinuz-%{KVERREL}
chmod 755 %{buildroot}/boot/vmlinuz-%{KVERREL} chmod 755 %{buildroot}/boot/vmlinuz-%{KVERREL}
echo "%{KVERREL}" > %{buildroot}/boot/.uname-%{KVERREL}
# install DTBs # install DTBs
%ifarch aarch64 || riscv64 %ifarch aarch64 || riscv64
@ -174,8 +173,7 @@ fi
# and not # and not
# vmlinuz -> /boot/vmlinuz-6.6.0-20231004.6.el9.aarch64 # vmlinuz -> /boot/vmlinuz-6.6.0-20231004.6.el9.aarch64
pushd /boot pushd /boot
rm -vf .uname dtb initramfs.img System.map vmlinuz rm -rvf dtb initramfs.img System.map vmlinuz
ln -s .uname-%{KVERREL} .uname
ln -s dtb-%{KVERREL} dtb ln -s dtb-%{KVERREL} dtb
ln -s initramfs-%{KVERREL}.img initramfs.img ln -s initramfs-%{KVERREL}.img initramfs.img
ln -s System.map-%{KVERREL} System.map ln -s System.map-%{KVERREL} System.map
@ -184,7 +182,6 @@ popd
%preun %preun
# remove symlinks # remove symlinks
rm -vf /boot/.uname /boot/.uname-%{KVERREL}
rm -vf /boot/initramfs.img rm -vf /boot/initramfs.img
rm -vf /boot/System.map rm -vf /boot/System.map
rm -vf /boot/vmlinuz rm -vf /boot/vmlinuz
@ -216,5 +213,4 @@ fi
%exclude /lib/modules/%{KVERREL}/build %exclude /lib/modules/%{KVERREL}/build
%exclude /lib/modules/%{KVERREL}/source %exclude /lib/modules/%{KVERREL}/source
/lib/modules/%{KVERREL} /lib/modules/%{KVERREL}
/boot/.uname-%{KVERREL}
/boot/* /boot/*