There was an API change in mdds-0.8.0. LibreOffice's master was already adapted at http://cgit.freedesktop.org/libreoffice/core/commit/sc/source/core/data/dpfilteredcache.cxx?id=6cbca6fc0ceee4370a962d67db362f3e22270e18 but the 4.0.3.3 release still depends on mdds-0.7.1 (and 4.1.0 alpha1 does too). I lost my build.log after downgrading to mdds-0.7.1 and merging libreoffice-4.0.3.3 but will attach emerge --info later.
I just read the ebuild and it states it depends on <dev-util/mdds-0.8.0. I'm wondering why did it try to build libreoffice-4.0.3.3 then. Sorry for the noise.