simple reproduction: emerge -1bqO app-text/docbook-xml-dtd:4.{2..5} while emerge -1qOK -j4 app-text/docbook-xml-dtd:4.{2..5}; do :; done & while emerge dev-util/glib-utils -1qO; do :; done wait long enough and you'll see the xsltproc call in glib-utils fail. this is because docbook-xml-dtd invokes `build-docbook-catalog` and that tool doesn't update the /etc/xml/ content atomically. it grabs a lock on the dir, but it's only to protect against parallel runs of build-docbook-catalog itself.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/proj/build-docbook-catalog.git/commit/?id=203b974cdde83e876ba665df47928868278581ae commit 203b974cdde83e876ba665df47928868278581ae Author: Mike Frysinger <vapier@gentoo.org> AuthorDate: 2021-10-03 03:25:41 +0000 Commit: Mike Frysinger <vapier@gentoo.org> CommitDate: 2021-10-03 03:25:41 +0000 make file updates atomic While we have locks against other invocations of build-docbook-catalog to keep them from clobbering each other (write locks), we didn't have any locks for users of the databases (read locks). Rewriting the files in place causes those readers to get partially written files and then fail (due to missing entries). Closes: https://bugs.gentoo.org/773517 Signed-off-by: Mike Frysinger <vapier@gentoo.org> build-docbook-catalog | 51 +++++++++++++++++++++++++++++++-------------------- 1 file changed, 31 insertions(+), 20 deletions(-)
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d3a44d39bd48d2e1ed7c1a8f8805175cbb1c2a29 commit d3a44d39bd48d2e1ed7c1a8f8805175cbb1c2a29 Author: Mike Frysinger <vapier@gentoo.org> AuthorDate: 2021-10-03 04:05:38 +0000 Commit: Mike Frysinger <vapier@gentoo.org> CommitDate: 2021-10-03 04:06:08 +0000 app-text/build-docbook-catalog: version bump to 2.0 Closes: https://bugs.gentoo.org/773517 Signed-off-by: Mike Frysinger <vapier@gentoo.org> app-text/build-docbook-catalog/Manifest | 1 + .../build-docbook-catalog-2.0.ebuild | 36 ++++++++++++++++++++++ 2 files changed, 37 insertions(+)