Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a problem in makeing gpgpu-sim package in my Ubuntu. This is a ubuntu error and I do not know how to solve it

in the make file I have this

        g++ -shared -Wl,-soname, \

        build/3010/release/libcuda/*.o \
        build/3010/release/cuda-sim/*.o \
        build/3010/release/cuda-sim/decuda_pred_table/*.o \
        build/3010/release/gpgpu-sim/*.o \
        build/3010/release/intersim/*.o \
        build/3010/release/*.o -lm -lz -lGL -pthread \
        /home/alireza/gpgpu-sim/v3.x/src/gpuwattch//obj_opt/*.o \
        -o lib/3010/release/

but I get the following error

/usr/bin/ld: cannot find -lGL

collect2: ld returned 1 exit status

make: *** [lib/3010/release/] Error 1

do you know how to solve this? thanks

share|improve this question
up vote 0 down vote accepted

Running the following commands should solve the problem:

sudo apt-get install mesa-common-dev
sudo apt-get install freeglut3-dev
sudo apt-get install freeglut3
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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