During an upgrade to cmucl-source-19a, portage tried to unmerge the previous version, 18e-r1. As it attempted to unmerge, the following message appeared: Code: {...} --- !empty dir /usr/share/common-lisp/source --- !empty dir /usr/share/common-lisp --- !empty dir /usr/share --- !empty dir /usr --- !targe sym /usr/share/common-lisp/systems/cmucl-graystream.asd --- !targe sym /usr/share/common-lisp/systems/cmucl-clx.asd !!! ERROR: dev-lisp/cmucl-source-18e-r1 failed. !!! Function common-lisp_pkg_postrm, Line 30, Exitcode 0 !!! CLPACKAGE was empty or undefined upon call to pkg_prerm !!! If you need support, post the topmost build error, NOT this status message. !!! FAILED postrm: 1 No other messages were given. After the unmerge failed, Reproducible: Always Steps to Reproduce: 1. Make sure no cmucl-source package is installed. 2. emerge dev-lisp/cmucl-source-18e-r1 3. emerge dev-list/cmucl-source (to get the latest one) Actual Results: Failure during unmerge of cmucl-source-18e-r1 Expected Results: The previous package should have been able to be unmerged successfully. Workaround found: Delete the directory /var/db/pkg/dev-lisp/cmucl-source-18e-r1. There will still be a remnant lock file, -MERGING-cmucl-source-18e-r1.portage_lockfile, in the dev-lisp directory. You will NOT be able to delete it via rm; however, it does not cause any issues for you later.
I tried to reproduce this in a 2004.3 (KEYWORDS=x86) chroot w/ the packages CD and 20041022 portage snapshot (ie. http://gentoo.osuosl.org/releases/x86/2004.3/) by following the reproduction steps, but I was unsuccessful. It unmerged for me. All I can suggest it was some kind of change in portage (emerge) in how it records the environment variables.