From eaf487282baf1e22bd036d6a8eeba63561a48646 Mon Sep 17 00:00:00 2001 From: Peter Robinson Date: Mon, 3 Aug 2020 17:04:42 +0100 Subject: [PATCH] fix python bytecode compile --- libsmbios.spec | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/libsmbios.spec b/libsmbios.spec index 313c1ec..0b6f843 100644 --- a/libsmbios.spec +++ b/libsmbios.spec @@ -1,7 +1,3 @@ -# This package depends on automagic byte compilation -# https://fedoraproject.org/wiki/Changes/No_more_automagic_Python_bytecompilation_phase_2 -%global _python_bytecompile_extra 1 - # these are all substituted by autoconf %define pot_file libsmbios %define lang_dom libsmbios-2.4 @@ -148,6 +144,9 @@ find %{buildroot}/%{_includedir} out/libsmbios_c -exec touch -r $TOPDIR/configur mv out/libsmbios_c out/libsmbios_c-%{_arch} +# https://fedoraproject.org/wiki/Changes/No_more_automagic_Python_bytecompilation_phase_3 +%py_byte_compile %{python3} %{buildroot}%{python3_sitearch}/ + rename %{pot_file}.mo %{lang_dom}.mo $(find %{buildroot}/%{_datadir} -name %{pot_file}.mo) %find_lang %{lang_dom}