Require at least the same expat version as used during the build
The versioned requirement is no longer valid - this happens again now with expat 2.7.2 introducing new symbols. Make the versioned requirement future-proof - the generated version will always match at least the one present in the buildroot during the Python build.
This commit is contained in:
parent
44d63ded35
commit
0b2d48a807
1 changed files with 13 additions and 5 deletions
|
|
@ -240,8 +240,7 @@ BuildRequires: bluez-libs-devel
|
|||
BuildRequires: bzip2
|
||||
BuildRequires: bzip2-devel
|
||||
BuildRequires: desktop-file-utils
|
||||
# See the runtime requirement in the -libs subpackage
|
||||
BuildRequires: expat-devel >= 2.6
|
||||
BuildRequires: expat-devel
|
||||
|
||||
BuildRequires: findutils
|
||||
BuildRequires: gcc-c++
|
||||
|
|
@ -574,12 +573,20 @@ Recommends: (%{pkgname}-tkinter%{?_isa} = %{version}-%{release} if tk%{?_isa})
|
|||
Requires: tzdata
|
||||
|
||||
# The requirement on libexpat is generated, but we need to version it.
|
||||
# When built with expat >= 2.6, but installed with older expat, we get:
|
||||
# When built with a specific expat version, but installed with an older one,
|
||||
# we sometimes get:
|
||||
# ImportError: /usr/lib64/python3.X/lib-dynload/pyexpat.cpython-....so:
|
||||
# undefined symbol: XML_SetReparseDeferralEnabled
|
||||
# undefined symbol: XML_...
|
||||
# The pyexpat module has build-time checks for expat version to only use the
|
||||
# available symbols. However, there is no runtime protection, so when the module
|
||||
# is later installed with an older expat, it may error due to undefined symbols.
|
||||
# This breaks many things, including python -m venv.
|
||||
# We avoid this problem by requiring at least the same version of expat that
|
||||
# was used during the build time.
|
||||
# Other subpackages (like -debug) also need this, but they all depend on -libs.
|
||||
Requires: expat >= 2.6
|
||||
%global expat_version %(LANG=C rpm -q --qf '%%{version}' expat.%{_target_cpu} | sed 's/.*not installed/0/')
|
||||
Requires: expat >= %{expat_version}
|
||||
|
||||
|
||||
%description -n %{pkgname}-libs
|
||||
This package contains runtime libraries for use by Python:
|
||||
|
|
@ -1748,6 +1755,7 @@ CheckPython optimized
|
|||
%changelog
|
||||
* Tue Jan 06 2026 Lumír Balhar <lbalhar@redhat.com> - 3.12.12-2
|
||||
- Security fix for CVE-2025-12084
|
||||
- Require at least the same expat version as used during the build time
|
||||
|
||||
* Fri Oct 10 2025 Karolina Surma <ksurma@redhat.com> - 3.12.12-1
|
||||
- Update to 3.12.12
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue