diff --git a/python3.spec b/python3.spec index 5bc1f07..ce12ff7 100644 --- a/python3.spec +++ b/python3.spec @@ -151,6 +151,7 @@ BuildRequires: gcc-c++ %if %{with gdbm} BuildRequires: gdbm-devel %endif +BuildRequires: git-core BuildRequires: glibc-all-langpacks BuildRequires: glibc-devel BuildRequires: gmp-devel @@ -599,38 +600,34 @@ version once Python %{pybasever} is stable. %prep %gpgverify -k2 -s1 -d0 -%setup -q -n Python-%{upstream_version} -# Remove all exe files to ensure we are not shipping prebuilt binaries -# note that those are only used to create Microsoft Windows installers -# and that functionality is broken on Linux anyway -find -name '*.exe' -print -delete +%autosetup -S git_am -N -n Python-%{upstream_version} -# Remove bundled libraries to ensure that we're using the system copy. -rm -r Modules/expat - -# -# Apply patches: -# -%patch1 -p1 +# Apply initial patches manually +%apply_patch -q %{PATCH1} %if "%{_lib}" == "lib64" -%patch102 -p1 +%apply_patch -q %{PATCH102} %endif -%patch111 -p1 -%patch155 -p1 -%patch170 -p1 + +%apply_patch -q %{PATCH111} +%apply_patch -q %{PATCH155} +%apply_patch -q %{PATCH170} %if %{with rpmwheels} -%patch189 -p1 +%apply_patch -q %{PATCH189} rm Lib/ensurepip/_bundled/*.whl %endif -%patch251 -p1 -%patch274 -p1 -%patch316 -p1 -%patch328 -p1 -%patch335 -p1 +# Apply the remaining patches +%autopatch -m 190 + +# Remove all exe files to ensure we are not shipping prebuilt binaries +# note that those are only used to create Microsoft Windows installers +# and that functionality is broken on Linux anyway +find -name '*.exe' -print -delete +# Remove bundled libraries to ensure that we're using the system copy. +rm -r Modules/expat # Remove files that should be generated by the build # (This is after patching, so that we can use patches directly from upstream)