If python ebuild finds that python is beeng crosscompiling it applies two patches: --- # fix os.utime() on hppa. utimes it not supported but unfortunately reported as working - gmsoft (22 May 04) # PLEASE LEAVE THIS FIX FOR NEXT VERSIONS AS IT'S A CRITICAL FIX !!! [ "${ARCH}" = "hppa" ] && sed -e 's/utimes //' -i ${S}/configure if tc-is-cross-compiler ; then epatch "${WORKDIR}/${PATCHTAR}"/python-2.4.1-bindir-libdir.patch epatch "${WORKDIR}/${PATCHTAR}"/python-2.4.1-crosscompile.patch fi --- But first patch doesn't fit any more. It uses "Python-2.4c1" in it's paths. Heare is log: ************************************************************* ***** python-2.4.1-bindir-libdir.patch ***** ============================================ PATCH COMMAND: patch -p0 -g0 -E --no-backup-if-mismatch < /var/tmp/portage/python-2.4.2/work/python-2.4-patches-1/python-2.4.1-bindir-libdir.patch ============================================ can't find file to patch at input line 8 Perhaps you used the wrong -p or --strip option? The text leading up to this was: -------------------------- | |# |# Patch managed by http://www.holgerschurig.de/patcher.html |# | |--- Python-2.4c1/Makefile.pre.in~bindir-libdir.patch |+++ Python-2.4c1/Makefile.pre.in -------------------------- No file to patch. Skipping patch. 1 out of 1 hunk ignored ============================================ PATCH COMMAND: patch -p1 -g0 -E --no-backup-if-mismatch < /var/tmp/portage/python-2.4.2/work/python-2.4-patches-1/python-2.4.1-bindir-libdir.patch ============================================ patching file Makefile.pre.in Hunk #1 FAILED at 78. 1 out of 1 hunk FAILED -- saving rejects to file Makefile.pre.in.rej ============================================ PATCH COMMAND: patch -p2 -g0 -E --no-backup-if-mismatch < /var/tmp/portage/python-2.4.2/work/python-2.4-patches-1/python-2.4.1-bindir-libdir.patch ============================================ missing header for unified diff at line 8 of patch can't find file to patch at input line 8 Perhaps you used the wrong -p or --strip option? The text leading up to this was: -------------------------- | |# |# Patch managed by http://www.holgerschurig.de/patcher.html |# | |--- Python-2.4c1/Makefile.pre.in~bindir-libdir.patch |+++ Python-2.4c1/Makefile.pre.in -------------------------- No file to patch. Skipping patch. 1 out of 1 hunk ignored ============================================ PATCH COMMAND: patch -p3 -g0 -E --no-backup-if-mismatch < /var/tmp/portage/python-2.4.2/work/python-2.4-patches-1/python-2.4.1-bindir-libdir.patch ============================================ missing header for unified diff at line 8 of patch can't find file to patch at input line 8 Perhaps you used the wrong -p or --strip option? The text leading up to this was: -------------------------- | |# |# Patch managed by http://www.holgerschurig.de/patcher.html |# | |--- Python-2.4c1/Makefile.pre.in~bindir-libdir.patch |+++ Python-2.4c1/Makefile.pre.in -------------------------- No file to patch. Skipping patch. 1 out of 1 hunk ignored ============================================ PATCH COMMAND: patch -p4 -g0 -E --no-backup-if-mismatch < /var/tmp/portage/python-2.4.2/work/python-2.4-patches-1/python-2.4.1-bindir-libdir.patch ============================================ missing header for unified diff at line 8 of patch can't find file to patch at input line 8 Perhaps you used the wrong -p or --strip option? The text leading up to this was: -------------------------- | |# |# Patch managed by http://www.holgerschurig.de/patcher.html |# | |--- Python-2.4c1/Makefile.pre.in~bindir-libdir.patch |+++ Python-2.4c1/Makefile.pre.in -------------------------- No file to patch. Skipping patch. 1 out of 1 hunk ignored **************************************************************** So merging stops wih error: --- * Applying python-2.4.1-bindir-libdir.patch ... * Failed Patch: python-2.4.1-bindir-libdir.patch ! * ( /var/tmp/portage/python-2.4.2/work/python-2.4-patches-1/python-2.4.1-bindir-libdir.patch ) --- This applies to all versions of python in portages.
Created attachment 88252 [details, diff] modified patch Now this patch applies to Python 2.4.3-r1
Created attachment 88253 [details, diff] Modified patch Noq it can be aplyed to python 2.4.3-r1 BUT it may not work on 32bit systems. I have noticed that on my athlon64 in Makefile.in libdir ends with smth/lib64. I gues, that on 32bit systems it vill be smth/lib
So, after replacing this patches in python-2.4-patches-2.tar.bz2 crosscompiling went OK. I have only one question, is it possible not to include "Python-*.*.*" in file path in patches?
*** Bug 130278 has been marked as a duplicate of this bug. ***
Crosscompile patches are a bit different now but this should be fixed in latest versions.