title: linking mkl as lapack and blas with cmake
body: <p>I am having trouble linking MKL math libraries to my project with CMake. The CMake config looks for LAPACK and BLAS with:</p>
  
  <pre><code>find_package(BLAS REQUIRED)
  find_package(LAPACK REQUIRED)
  </code></pre>
  
  <p>I have a good MKL installation in my path. How do I tell CMake to use it?</p>
  
  <p>I've tried various versions of this:</p>
  
  <pre><code>ccmake .. -DCMAKE_Fortran_COMPILER:PATH=ifort
      -DBLAS_LIBRARIES=path/to/mkl/lib/intel64/libmkl_blas95_lp64.a
      -DLAPACK_LIBRARIES=path/to/mkl/lib/intel64/libmkl_lapack95_lp64.a
  </code></pre>
  
  <p>but it always fails in the link step in Make with errors such as</p>
  
  <pre><code>undefined reference to `dgesvd_'
  </code></pre>