From 41a58d5fbc10e6ce3ad04f3083bd4ef137da7fa6 Mon Sep 17 00:00:00 2001 From: Jaroslav Kysela Date: Fri, 4 Feb 2022 09:13:22 +0100 Subject: [PATCH] fix xz compression Signed-off-by: Jaroslav Kysela --- alsa-sof-firmware.spec | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/alsa-sof-firmware.spec b/alsa-sof-firmware.spec index 81a3fcf..640a8c5 100644 --- a/alsa-sof-firmware.spec +++ b/alsa-sof-firmware.spec @@ -2,6 +2,7 @@ # in the end package are expected. %define _binaries_in_noarch_packages_terminate_build 0 %global _firmwarepath /usr/lib/firmware +%global _xz_opts -9 --check=crc32 %global sof_ver 2.0 #global sof_ver_pre rc1 @@ -13,7 +14,7 @@ Summary: Firmware and topology files for Sound Open Firmware project Name: alsa-sof-firmware Version: %{sof_ver} -Release: 2%{?sof_ver_rel}%{?dist} +Release: 3%{?sof_ver_rel}%{?dist} # See later in the spec for a breakdown of licensing License: BSD URL: https://github.com/thesofproject/sof-bin @@ -55,7 +56,7 @@ rm -rf firmware/intel/sof-tplg/sof-imx8* rm -rf firmware/intel/sof-tplg/sof-mt8* # use xz compression -find -P firmware/intel/sof -type f -name "*.ri" -exec xz -z9 {} \; +find -P firmware/intel/sof -type f -name "*.ri" -exec xz -z %{_xz_opts} {} \; for f in $(find -P firmware/intel/sof -type l -name "*.ri"); do \ l=$(readlink "${f}"); \ d=$(dirname "${f}"); \ @@ -65,7 +66,7 @@ for f in $(find -P firmware/intel/sof -type l -name "*.ri"); do \ ln -svf "${l}.xz" "${b}.xz"; \ popd; \ done -find -P firmware/intel/sof-tplg -type f -name "*.tplg" -exec xz -z9 {} \; +find -P firmware/intel/sof-tplg -type f -name "*.tplg" -exec xz -z %{_xz_opts} {} \; %build # SST topology files (not SOF related, but it's a Intel hw support @@ -73,7 +74,7 @@ find -P firmware/intel/sof-tplg -type f -name "*.tplg" -exec xz -z9 {} \; alsatplg -c /usr/share/alsa/topology/hda-dsp/skl_hda_dsp_generic-tplg.conf \ -o firmware/skl_hda_dsp_generic-tplg.bin # use xz compression -xz -z9 firmware/*.bin +xz -z %{_xz_opts} firmware/*.bin chmod 0644 firmware/*.bin.xz %install @@ -118,6 +119,9 @@ if st and st.type == "link" then end %changelog +* Fri Feb 4 2022 Jaroslav Kysela - 2.0-3 +- Use CRC32 for the xz compression + * Thu Jan 27 2022 Jaroslav Kysela - 2.0-2 - Update to v2.0 - Use xz compression