CMAKE_VERBOSE=1 is quite revealing. I have only tested this with app-text/poppler so far, a build.log is coming soon. I confirmed that everything that the calls to g++ displayed by the build.log are accurate by using ``ps -Aef |grep g++''. Relevant information from environment (will be attached): ohnopublishing / # grep '^declare.*C.\{0,2\}FLAGS' /var/tmp/portage/app-text/poppler-0.12.3-r3/temp/environment declare -x CFLAGS="-Os -pipe -march=i686" declare -x CFLAGS_default="" declare -x CPPFLAGS=" -DNDEBUG" declare -x CXXFLAGS="-Os -pipe -march=i686" CFLAGS seems to work fine. I cannot explain why CXXFLAGS doesn't as CXXFLAGS appears to be derived using the same method as CFLAGS.
Created attachment 223443 [details] poppler-0.12.3-r3-build.log Compiled with dev-util/cmake-2.6.4-r3. The same problem was also observed with dev-util/cmake-2.8.0-r2.
Created attachment 223445 [details] poppler-0.12.3-r3-environment.bz2
wesnoth seems to be getting CXXFLAGS fine, sorry for misfiling this and making too many assumptions. I'll try to look for the error in the correct place now :-). May you reassign to wranglers please?
Created attachment 223471 [details] files/poppler-0.12.3-cxxflags.patch This applies to all versions of poppler in portage. This is not a clean patch because it seems to go against the design of cmake regarding control over *FLAGS. (considering, for example, ``release'' builds versus ``debug'' builds which cmake would rather handle itself).
Indeed, issue was there, it needed to be fixed different way however. Fixed in 0.12.3-r6 and 0.12.4-r2