So I was working on this one most of yesterday. I am trying to install the mesa3d opengl libraries on ubuntu 14.04 x64. So I downloaded and installed the dependency for this install: llvm-3.4.2. So that went through just fine.

Then I tried to install the mesa-10.2.6 package using a configuration script:

make install

When I ran ./configure, I get an error

checking for llvm-config... /usr/local/bin/llvm-config
checking for RADEON... yes
checking for RADEON... yes
configure: error: Could not find llvm shared libraries:
Please make sure you have built llvm with the --enable-shared option
and that your llvm libraries are installed in /usr/local/lib
If you have installed your llvm libraries to a different directory you
can use the --with-llvm-prefix= configure flag to specify this directory.
NOTE: Mesa is attempting to use llvm shared libraries by default.
If you do not want to build with llvm shared libraries and instead want to
use llvm static libraries then add --disable-llvm-shared-libs to your configure
invocation and rebuild.

So I am not sure how to fix this error. I tried point the configure script to the direction with ./configure --with-llvm-prefix=/usr/local/bin but that did not work.

I am not sure what else to do. Any suggestions?

2 Answers 2


I think you have to do

sudo apt-get install llvm-dev

After installing llvm-dev, I used locate libLLVM to find the so file. It was located in /usr/lib/llvm-3.9/lib, but I can not specify the so file directory directly, otherwise it will report another gallium error with llvm.

Inspired by Pierre Moreau's comment, I have to specify the root directory of llvm as follows

./configure --with-llvm-prefix=/usr/lib/llvm-3.9

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.