From c73f2a9f6439d2a0fbafd64aa3d9e17cbd2a9d52 Mon Sep 17 00:00:00 2001 From: Sandro Mani Date: Jul 29 2020 09:56:05 +0000 Subject: Use %py_byte_compile --- diff --git a/mingw-glib2.spec b/mingw-glib2.spec index 3feb555..e360d63 100644 --- a/mingw-glib2.spec +++ b/mingw-glib2.spec @@ -1,12 +1,5 @@ -# This package depends on automagic byte compilation -# https://fedoraproject.org/wiki/Changes/No_more_automagic_Python_bytecompilation_phase_2 -%global _python_bytecompile_extra 1 - %{?mingw_package_header} -# See https://fedoraproject.org/wiki/Packaging:Python_Appendix#Manual_byte_compilation -%global __python %{__python3} - Name: mingw-glib2 Version: 2.64.3 Release: 2%{?dist} @@ -165,6 +158,13 @@ find %{buildroot} -name "*.la" -delete %mingw_find_lang glib20 +# Manually invoke the python byte compile macro for each path that needs byte +# compilation. +%py_byte_compile %{__python3} %{buildroot}%{mingw32_datadir}/glib-2.0/gdb +%py_byte_compile %{__python3} %{buildroot}%{mingw32_datadir}/glib-2.0/codegen +%py_byte_compile %{__python3} %{buildroot}%{mingw64_datadir}/glib-2.0/gdb +%py_byte_compile %{__python3} %{buildroot}%{mingw64_datadir}/glib-2.0/codegen + # Win32 %files -n mingw32-glib2 -f mingw32-glib20.lang