Pin modification time for python files to SOURCE_DATE_EPOCH
Patching the pretty printer files leads to different mtimes for different, which then leads to different results in the compiled python bytecode since it uses mtimes for invalidation. Use `$SOURCE_DATE_EPOCH` as the mtime for the pretty printers so that they end up with identical bytecode results. This allows libstdc++.x86_64 to be installed alongside libstdc++.i686. Resolves: RHEL-100148 Related: RHEL-81975
This commit is contained in:
parent
6ee19f4557
commit
f98f195183
10
gcc.spec
10
gcc.spec
@ -1,10 +1,11 @@
|
||||
%global source_date_epoch_from_changelog 1
|
||||
%global DATE 20240719
|
||||
%global gitrev a985e3068a6f8045f8a6f2d2d5ae75f5eb0a8767
|
||||
%global gcc_version 11.5.0
|
||||
%global gcc_major 11
|
||||
# Note, gcc_release must be integer, if you want to add suffixes to
|
||||
# %%{release}, append them after %%{gcc_release} on Release: line.
|
||||
%global gcc_release 8
|
||||
%global gcc_release 9
|
||||
%global nvptx_tools_gitrev 5f6f343a302d620b0868edab376c00b15741e39e
|
||||
%global newlib_cygwin_gitrev 50e2a63b04bdd018484605fbb954fd1bd5147fa0
|
||||
%global _unpackaged_files_terminate_build 0
|
||||
@ -1831,9 +1832,9 @@ mv -f %{buildroot}%{_prefix}/%{_lib}/libstdc++*gdb.py* \
|
||||
%{buildroot}%{_datadir}/gdb/auto-load/%{_prefix}/%{_lib}/
|
||||
pushd ../libstdc++-v3/python
|
||||
for i in `find . -name \*.py`; do
|
||||
touch -r $i %{buildroot}%{_prefix}/share/gcc-%{gcc_major}/python/$i
|
||||
touch -d @$SOURCE_DATE_EPOCH %{buildroot}%{_prefix}/share/gcc-%{gcc_major}/python/$i
|
||||
done
|
||||
touch -r hook.in %{buildroot}%{_datadir}/gdb/auto-load/%{_prefix}/%{_lib}/libstdc++*gdb.py
|
||||
touch -d @$SOURCE_DATE_EPOCH %{buildroot}%{_datadir}/gdb/auto-load/%{_prefix}/%{_lib}/libstdc++*gdb.py
|
||||
popd
|
||||
for f in `find %{buildroot}%{_prefix}/share/gcc-%{gcc_major}/python/ \
|
||||
%{buildroot}%{_datadir}/gdb/auto-load/%{_prefix}/%{_lib}/ -name \*.py`; do
|
||||
@ -3612,6 +3613,9 @@ end
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Fri Jun 27 2025 Siddhesh Poyarekar <siddhesh@redhat.com> 11.5.0-9
|
||||
- Pin modification time for python files to SOURCE_DATE_EPOCH (RHEL-100148).
|
||||
|
||||
* Mon Jun 23 2025 Siddhesh Poyarekar <siddhesh@redhat.com> - 11.5.0-8
|
||||
- Sync libstdc++ pretty printers to latest GTS (RHEL-81975)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user