| Summary: | cleaning orphaned python bytecode more thoroughly in python.eclass | ||
|---|---|---|---|
| Product: | Gentoo Linux | Reporter: | Fabian Groffen <grobian> |
| Component: | Eclasses | Assignee: | Python Gentoo Team <python> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | grobian, haubi, liquidx |
| Priority: | High | ||
| Version: | unspecified | ||
| Hardware: | All | ||
| OS: | Other | ||
| Whiteboard: | |||
| Package list: | Runtime testing required: | --- | |
| Attachments: | patch | ||
Created attachment 99081 [details, diff]
patch
I fixed this quite a while ago. |
From Michael Haubenwallner: Found this while preparing for another clean bootstrap, looking for files left after the 'emerge -C': $ cd var/db/pkg $ emerge -C */* $ cd ../../.. $ find . <some intelligent prunes to avoid finding cache & usr/portage> patch (also attached) @@ -217,11 +217,11 @@ for path in ${SEARCH_PATH}; do einfo "Cleaning orphaned Python bytecode from ${path} .." - for obj in $(find ${path} -name *.pyc); do - src_py="${obj%c}" + for obj in $(find ${path} -name *.py[co]); do + src_py="${obj%[co]}" if [ ! -f "${src_py}" ]; then - einfo "Purging ${src_py}[co]" - rm -f ${src_py}[co] + einfo "Purging ${obj}" + rm -f ${obj} fi done # attempt to remove directories that maybe empty