Can't build mesa-9.1.1 with llvm-9999. These patches have fixed the problem for me. Please add them to the mesa-9.1-gentoo-patches: http://cgit.freedesktop.org/mesa/mesa/patch/src/gallium/auxiliary/gallivm/lp_bld_debug.cpp?id=ead4db420e9e5408f41c70768a290592a384aedb http://cgit.freedesktop.org/mesa/mesa/patch/src/gallium/drivers/radeon/radeon_llvm_emit.cpp?id=a0c8942bb4742b4bd22f494cea4dcd59d9ca99ab http://cgit.freedesktop.org/mesa/mesa/patch/src/gallium/drivers/radeon/radeon_llvm_emit.cpp?id=6249db73ea580e6a54874235ffb3a7d42ac63bb4 $ emerge -qpv mesa [ebuild U ] media-libs/mesa-9.1.1-r1 [9.0.3-r1] USE="classic egl gallium gbm gles1 gles2 llvm nptl openvg pax_kernel shared-glapi vdpau -bindist -debug -osmesa -pic (-r600-llvm-compiler) (-selinux) -wayland -xa -xorg -xvmc (-g3dvl%*)" PYTHON_SINGLE_TARGET="python2_7%* -python2_6%" PYTHON_TARGETS="python2_7%* -python2_6%" VIDEO_CARDS="radeon radeonsi -i915 -i965 -intel -nouveau -r100 -r200 -r300 -r600 -vmware" Relevant parts of the build log: gallivm/lp_bld_debug.cpp: In member function 'virtual void raw_debug_ostream::write_impl(const char*, size_t)': gallivm/lp_bld_debug.cpp:106:40: warning: cast from type 'const char*' to type 'char*' casts away qualifiers [-Wcast- qual] gallivm/lp_bld_debug.cpp: In function 'void lp_disassemble(const void*)': gallivm/lp_bld_debug.cpp:206:4: error: 'OwningPtr' was not declared in this scope gallivm/lp_bld_debug.cpp:206:14: error: expected primary-expression before 'const' gallivm/lp_bld_debug.cpp:206:14: error: expected ';' before 'const' gallivm/lp_bld_debug.cpp:211:9: error: 'AsmInfo' was not declared in this scope gallivm/lp_bld_debug.cpp:218:14: error: expected primary-expression before 'const' gallivm/lp_bld_debug.cpp:218:14: error: expected ';' before 'const' gallivm/lp_bld_debug.cpp:222:9: error: 'DisAsm' was not declared in this scope gallivm/lp_bld_debug.cpp:230:37: error: 'AsmInfo' was not declared in this scope gallivm/lp_bld_debug.cpp:236:14: error: expected primary-expression before 'const' gallivm/lp_bld_debug.cpp:236:14: error: expected ';' before 'const' gallivm/lp_bld_debug.cpp:237:9: error: 'MRI' was not declared in this scope gallivm/lp_bld_debug.cpp:242:14: error: expected primary-expression before 'const' gallivm/lp_bld_debug.cpp:242:14: error: expected ';' before 'const' gallivm/lp_bld_debug.cpp:243:9: error: 'MII' was not declared in this scope gallivm/lp_bld_debug.cpp:250:27: error: expected primary-expression before '>' token gallivm/lp_bld_debug.cpp:251:63: error: 'MII' was not declared in this scope gallivm/lp_bld_debug.cpp:251:69: error: 'MRI' was not declared in this scope gallivm/lp_bld_debug.cpp:251:79: error: 'Printer' was not declared in this scope gallivm/lp_bld_debug.cpp:305:12: error: 'DisAsm' was not declared in this scope radeon_llvm_emit.cpp:42:35: fatal error: llvm/Support/IRReader.h: No such file or directory Reproducible: Always
Sorry, correct links: http://cgit.freedesktop.org/mesa/mesa/patch/?id=ead4db420e9e5408f41c70768a290592a384aedb http://cgit.freedesktop.org/mesa/mesa/patch/?id=a0c8942bb4742b4bd22f494cea4dcd59d9ca99ab http://cgit.freedesktop.org/mesa/mesa/patch/?id=6249db73ea580e6a54874235ffb3a7d42ac63bb4
This was fixed in media-libs/mesa-9.1.2
Marking as fixed per comment 2