Besides the Intel MKL link line advisor which helps you generate the correct compile and link options for gcc
/icc
compiler, there's another pre-request you may have to pay attention to -- setting the environment variables.
In order to use MKL, you need to set some environment variables properly. Intel has provided a script to easy this setup. You could add one line to your shell profile like .bash_profile
. Please read through the getting started section of MKL doc for more details.