php-5.4.32 has this is DEPEND: berkdb? ( =sys-libs/db-4* ) However, on my system, it is linked with db-5.1: !!! existing preserved libs: >>> package: sys-libs/db-5.1.29 * - /usr/lib64/libdb-5.1.so * used by /usr/lib64/php5.4/bin/php (dev-lang/php-5.4.32) * used by /usr/lib64/php5.4/bin/php-cgi (dev-lang/php-5.4.32) * used by /usr/lib64/php5.4/bin/php-fpm (dev-lang/php-5.4.32) Also, after running emerge @preserved-rebuild, it is *still* linked against db-5.1, which would indicate that the library version is being incorrectly auto-detected by the build system. I am guessing that the preferred db version needs to be passed to the build system somehow.
The configure option was poorly named, --with-db4=DIR DBA: Oracle Berkeley DB 4.x or 5.x support so there's "nothing wrong" with it picking up db-5.x. I think it would be OK to require >=4 and <6 in $DEPEND.
Recording this here for posterity: https://archives.gentoo.org/gentoo-dev/message/632585e7eb42520071495017d8ab5077 I plan on listing the acceptable slots one-by-one.
Fixed for the 5.6.x series here: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d9454b5d1c5a22855e7c22f30644ba7c8980f923
I've fixed it in 7.x too with a version bump: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6ed7b478508ebff056c57a73ba0a9a9b14fc2a39 Now the fact that we accept db-5.x is explicit, and the dependency no longer throws repoman warnings.