Skip to contentSkip to conversation

python3-cython: improve reprodcibility

PATCH New Lee Chee Yang 1 participant 1 message Oct 8, 2020

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 python3-cython: improve reprodcibility

From: Lee Chee Yang <[email protected]>

fix below diff in diffoscope.
diffoscope diff :-
│ │ ├── ./usr/lib/python3.8/site-packages/Cython-0.29.21-py3.8.egg-info/SOURCES.txt

│ │ │ @@ -11,22 +11,22 @@
│ │ │  cygdb.py
│ │ │  cython.py
│ │ │  cythonize.py
│ │ │  pylintrc
│ │ │  runtests.py
│ │ │  setup.py
│ │ │  setupegg.py
│ │ │

-/yocto/poky-master/build-2/tmp/work/skylake-64-poky-linux/python3-cython/0.29.21-r0/Cython-0.29.21/Cython/Compiler/FlowControl.c │ │ │ -/yocto/poky-master/build-2/tmp/work/skylake-64-poky-linux/python3-cython/0.29.21-r0/Cython-0.29.21/Cython/Compiler/FusedNode.c │ │ │ -/yocto/poky-master/build-2/tmp/work/skylake-64-poky-linux/python3-cython/0.29.21-r0/Cython-0.29.21/Cython/Compiler/Scanning.c │ │ │ -/yocto/poky-master/build-2/tmp/work/skylake-64-poky-linux/python3-cython/0.29.21-r0/Cython-0.29.21/Cython/Compiler/Visitor.c │ │ │ -/yocto/poky-master/build-2/tmp/work/skylake-64-poky-linux/python3-cython/0.29.21-r0/Cython-0.29.21/Cython/Plex/Actions.c │ │ │ -/yocto/poky-master/build-2/tmp/work/skylake-64-poky-linux/python3-cython/0.29.21-r0/Cython-0.29.21/Cython/Plex/Scanners.c │ │ │ -/yocto/poky-master/build-2/tmp/work/skylake-64-poky-linux/python3-cython/0.29.21-r0/Cython-0.29.21/Cython/Runtime/refnanny.c │ │ │ -/yocto/poky-master/build-2/tmp/work/skylake-64-poky-linux/python3-cython/0.29.21-r0/Cython-0.29.21/Cython/Tempita/_tempita.c │ │ │ +/yocto/poky-master/build/tmp/work/skylake-64-poky-linux/python3-cython/0.29.21-r0/Cython-0.29.21/Cython/Compiler/FlowControl.c │ │ │ +/yocto/poky-master/build/tmp/work/skylake-64-poky-linux/python3-cython/0.29.21-r0/Cython-0.29.21/Cython/Compiler/FusedNode.c │ │ │ +/yocto/poky-master/build/tmp/work/skylake-64-poky-linux/python3-cython/0.29.21-r0/Cython-0.29.21/Cython/Compiler/Scanning.c │ │ │ +/yocto/poky-master/build/tmp/work/skylake-64-poky-linux/python3-cython/0.29.21-r0/Cython-0.29.21/Cython/Compiler/Visitor.c │ │ │ +/yocto/poky-master/build/tmp/work/skylake-64-poky-linux/python3-cython/0.29.21-r0/Cython-0.29.21/Cython/Plex/Actions.c │ │ │ +/yocto/poky-master/build/tmp/work/skylake-64-poky-linux/python3-cython/0.29.21-r0/Cython-0.29.21/Cython/Plex/Scanners.c │ │ │ +/yocto/poky-master/build/tmp/work/skylake-64-poky-linux/python3-cython/0.29.21-r0/Cython-0.29.21/Cython/Runtime/refnanny.c │ │ │ +/yocto/poky-master/build/tmp/work/skylake-64-poky-linux/python3-cython/0.29.21-r0/Cython-0.29.21/Cython/Tempita/_tempita.c │ │ │ Cython/CodeWriter.py

---
 meta/recipes-devtools/python/python3-cython_0.29.21.bb | 3 +++
 1 file changed, 3 insertions(+)
meta/recipes-devtools/python/python3-cython_0.29.21.bb +3 -0
index 2ce6bdbd68..81b3c02180 100644
@@ -15,4 +15,7 @@ do_install_append() {
     mv ${D}${bindir}/cython ${D}${bindir}/cython3
     mv ${D}${bindir}/cythonize ${D}${bindir}/cythonize3
     mv ${D}${bindir}/cygdb ${D}${bindir}/cygdb3
+
+    # remove WORKDIR info from SOURCES.txt to improve reproducibility
+    sed -i 's#${WORKDIR}#/#g' ${D}${PYTHON_SITEPACKAGES_DIR}/Cython-*-info/SOURCES.txt
 }
Signature · 1 line
2.17.1