There is a potential race condition in OpkgIndexer.write_index() (in package_manager.py). When e.g. "all" appears twice in ALL_MULTILIB_PACKAGE_ARCHS/SDK_PACKAGE_ARCHS/MULTILIB_ARCHS, then two opkg-make-index instances will be run in parallel on tmp/deploy/ipk/all/Packages. This is probably what causes https://www.mail-archive.com/yocto@yoctoproject.org/msg22808.html, and we are seeing the same error sporadically. A simple fix would be to e.g. turn index_cmds into a set().
Thanks for the solution! I have tested this with rpm and deb and those packaging methods doesn't have this problem.
Sent patch to the mailing list: http://lists.openembedded.org/pipermail/openembedded-core/2016-March/118859.html
This has been solved in commit: http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=36bf66654a557c570011db0b06f2084ee2ccf9cc