add sccripts to workaround replace directory with symlink bug [release 20220913-2mamba;Tue Sep 20 2022]
This commit is contained in:
parent
6c7a328685
commit
9e1529dfd1
@ -1,6 +1,6 @@
|
|||||||
Name: linux-firmware
|
Name: linux-firmware
|
||||||
Version: 20220815
|
Version: 20220913
|
||||||
Release: 1mamba
|
Release: 2mamba
|
||||||
Summary: Collection of firmware files used by the Linux Kernel
|
Summary: Collection of firmware files used by the Linux Kernel
|
||||||
Group: System/Kernel and Hardware
|
Group: System/Kernel and Hardware
|
||||||
Vendor: openmamba
|
Vendor: openmamba
|
||||||
@ -37,6 +37,8 @@ Summary: Microcode update image for AMD CPUs
|
|||||||
%description -n amd-ucode
|
%description -n amd-ucode
|
||||||
Microcode update image for AMD CPUs.
|
Microcode update image for AMD CPUs.
|
||||||
|
|
||||||
|
%define __strip /usr/bin/true
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q
|
%setup -q
|
||||||
#%patch0 -p1
|
#%patch0 -p1
|
||||||
@ -70,6 +72,23 @@ install -D -m0644 amd-ucode.img %{buildroot}/boot/amd-ucode.img
|
|||||||
%clean
|
%clean
|
||||||
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
|
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
|
||||||
|
|
||||||
|
%pretrans -p <lua>
|
||||||
|
-- Define the path to directory being replaced below.
|
||||||
|
-- DO NOT add a trailing slash at the end.
|
||||||
|
path = "/usr/lib/firmware/qcom/LENOVO/21BX"
|
||||||
|
st = posix.stat(path)
|
||||||
|
if st and st.type == "directory" then
|
||||||
|
status = os.rename(path, path .. ".rpmmoved")
|
||||||
|
if not status then
|
||||||
|
suffix = 0
|
||||||
|
while not status do
|
||||||
|
suffix = suffix + 1
|
||||||
|
status = os.rename(path .. ".rpmmoved", path .. ".rpmmoved." .. suffix)
|
||||||
|
end
|
||||||
|
os.rename(path, path .. ".rpmmoved")
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
%pre
|
%pre
|
||||||
if [ ! -L /lib -a ! -L /lib/firmware ]; then
|
if [ ! -L /lib -a ! -L /lib/firmware ]; then
|
||||||
# Migrate /lib/firmware to /usr/lib/firmware
|
# Migrate /lib/firmware to /usr/lib/firmware
|
||||||
@ -87,6 +106,8 @@ if [ ! -L /lib -a ! -e /lib/firmware ]; then
|
|||||||
# make /lib/firmware symlink to /usr/lib/firmware
|
# make /lib/firmware symlink to /usr/lib/firmware
|
||||||
ln -s ../usr/lib/firmware /lib/firmware
|
ln -s ../usr/lib/firmware /lib/firmware
|
||||||
fi
|
fi
|
||||||
|
[ -e /usr/lib/firmware/qcom/LENOVO/21BX.rpmmoved ] && \
|
||||||
|
rm -rf /usr/lib/firmware/qcom/LENOVO/21BX.rpmmoved
|
||||||
:
|
:
|
||||||
|
|
||||||
%files
|
%files
|
||||||
@ -102,6 +123,12 @@ fi
|
|||||||
%endif
|
%endif
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Sep 20 2022 Silvan Calarco <silvan.calarco@mambasoft.it> 20220913-2mamba
|
||||||
|
- add sccripts to workaround replace directory with symlink bug
|
||||||
|
|
||||||
|
* Tue Sep 20 2022 Automatic Build System <autodist@mambasoft.it> 20220913-1mamba
|
||||||
|
- automatic version update by autodist
|
||||||
|
|
||||||
* Wed Aug 17 2022 Automatic Build System <autodist@mambasoft.it> 20220815-1mamba
|
* Wed Aug 17 2022 Automatic Build System <autodist@mambasoft.it> 20220815-1mamba
|
||||||
- automatic version update by autodist
|
- automatic version update by autodist
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user