From 5c6406bce60e566e4be85eddd3b7369716593cc3 Mon Sep 17 00:00:00 2001 From: CentOS Sources Date: Tue, 28 Mar 2023 09:39:43 +0000 Subject: [PATCH] import python-virt-firmware-1.6-2.el9 --- .gitignore | 1 + .python-virt-firmware.metadata | 1 + SOURCES/0001-setup.cfg-drop-peutils.patch | 37 ++++++++ SPECS/python-virt-firmware.spec | 105 ++++++++++++++++++++++ 4 files changed, 144 insertions(+) create mode 100644 .gitignore create mode 100644 .python-virt-firmware.metadata create mode 100644 SOURCES/0001-setup.cfg-drop-peutils.patch create mode 100644 SPECS/python-virt-firmware.spec diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..397aa51 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +SOURCES/virt-firmware-v1.6.tar.gz diff --git a/.python-virt-firmware.metadata b/.python-virt-firmware.metadata new file mode 100644 index 0000000..749538f --- /dev/null +++ b/.python-virt-firmware.metadata @@ -0,0 +1 @@ +66497d46df1c46543e71526530192ee296469cc4 SOURCES/virt-firmware-v1.6.tar.gz diff --git a/SOURCES/0001-setup.cfg-drop-peutils.patch b/SOURCES/0001-setup.cfg-drop-peutils.patch new file mode 100644 index 0000000..c7243b5 --- /dev/null +++ b/SOURCES/0001-setup.cfg-drop-peutils.patch @@ -0,0 +1,37 @@ +From b6db3b1366fe61a7cbe176c92420076bc6aa5936 Mon Sep 17 00:00:00 2001 +From: Gerd Hoffmann +Date: Mon, 14 Nov 2022 15:58:07 +0100 +Subject: [PATCH] setup.cfg: drop peutils + +--- + setup.cfg | 5 ----- + 1 file changed, 5 deletions(-) + +diff --git a/setup.cfg b/setup.cfg +index 5f57feac114d..307d6e279d4c 100644 +--- a/setup.cfg ++++ b/setup.cfg +@@ -17,10 +17,8 @@ packages = + virt/firmware + virt/firmware/efi + virt/firmware/varstore +- virt/peutils + install_requires = + cryptography +- pefile + + [options.entry_points] + console_scripts = +@@ -29,9 +27,6 @@ console_scripts = + virt-fw-dump = virt.firmware.dump:main + virt-fw-sigdb = virt.firmware.sigdb:main + migrate-vars = virt.firmware.migrate:main +- pe-dumpinfo = virt.peutils.peutils:pe_dumpinfo +- pe-listsigs = virt.peutils.peutils:pe_listsigs +- pe-addsigs = virt.peutils.peutils:pe_addsigs + + [options.package_data] + virt/firmware = certs/*.pem, aws/dict.v0 +-- +2.38.1 + diff --git a/SPECS/python-virt-firmware.spec b/SPECS/python-virt-firmware.spec new file mode 100644 index 0000000..d961bb7 --- /dev/null +++ b/SPECS/python-virt-firmware.spec @@ -0,0 +1,105 @@ +%global pypi_version 1.6 + +Name: python-virt-firmware +Version: %{pypi_version} +Release: 2%{?dist} +Summary: Tools for virtual machine firmware volumes + +License: GPLv2 +URL: https://gitlab.com/kraxel/virt-firmware +Source0: https://gitlab.com/kraxel/virt-firmware/-/archive/v%{pypi_version}/virt-firmware-v%{pypi_version}.tar.gz +Patch1: 0001-setup.cfg-drop-peutils.patch +BuildArch: noarch + +BuildRequires: python3-devel +BuildRequires: python3dist(cryptography) +BuildRequires: python3dist(setuptools) +BuildRequires: make + +%description +Tools for ovmf / armvirt firmware volumes This is a small collection of tools +for edk2 firmware images. They support decoding and printing the content of +firmware volumes. Variable stores (OVMF_VARS.fd) can be modified, for example +to enroll secure boot certificates. + +%package -n python3-virt-firmware +Summary: %{summary} +%{?python_provide:%python_provide python3-virt-firmware} +Provides: virt-firmware +Requires: python3dist(cryptography) +Requires: python3dist(setuptools) +%description -n python3-virt-firmware +Tools for ovmf / armvirt firmware volumes This is a small collection of tools +for edk2 firmware images. They support decoding and printing the content of +firmware volumes. Variable stores (OVMF_VARS.fd) can be modified, for example +to enroll secure boot certificates. + +%package -n python3-virt-firmware-tests +Summary: %{summary} - test cases +Requires: python3-virt-firmware +Requires: python3dist(pytest) +Requires: edk2-ovmf +%description -n python3-virt-firmware-tests +test cases + +%prep +%autosetup -n virt-firmware-v%{pypi_version} + +%build +%py3_build + +%install +%py3_install +# manpages +install -m 755 -d %{buildroot}%{_mandir}/man1 +install -m 644 man/*.1 %{buildroot}%{_mandir}/man1 +# tests +mkdir -p %{buildroot}%{_datadir}/%{name} +cp -ar tests %{buildroot}%{_datadir}/%{name} + +%files -n python3-virt-firmware +%license LICENSE +%doc README.md +%{_bindir}/host-efi-vars +%{_bindir}/virt-fw-dump +%{_bindir}/virt-fw-vars +%{_bindir}/virt-fw-sigdb +%{_bindir}/migrate-vars +%{_mandir}/man1/virt-*.1* +%{python3_sitelib}/virt/firmware +%{python3_sitelib}/virt_firmware-%{pypi_version}-py%{python3_version}.egg-info + +%files -n python3-virt-firmware-tests +%{_datadir}/%{name}/tests + +%changelog +* Tue Nov 15 2022 Gerd Hoffmann - 1.6-2 +- add tests.yml + +* Mon Nov 14 2022 Gerd Hoffmann - 1.6-1 +- update to version 1.6 +- drop peutils +- add man-pages +- add tests sub-package +- resolves: rhbz#2142608 + +* Fri Jul 22 2022 Fedora Release Engineering - 1.2-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild + +* Mon Jul 18 2022 Gerd Hoffmann - 1.2-1 +- update to version 1.2 + +* Fri Jul 01 2022 Gerd Hoffmann - 1.1-1 +- update to version 1.1 + +* Wed Jun 22 2022 Gerd Hoffmann - 1.0-1 +- update to version 1.0 + +* Mon Jun 13 2022 Python Maint - 0.98-2 +- Rebuilt for Python 3.11 + +* Tue May 24 2022 Gerd Hoffmann - 0.98-1 +- update to version 0.98 + +* Mon Apr 11 2022 Gerd Hoffmann - 0.95-1 +- Initial package.