and when I use above linking, I get many unresolved referenced to almost all MKL functions I have used. Is there anything wrong with the link above? Is it also possible to just provide the path, so the compiler can statically bind all libraries needed? I read somewhere that using "-static-intel" would do such thing, but it didn't help.
you forgot to use -Wl,--start-group/-Wl,--end-group linker options. So, your link line will look: MKL = "-Wl,--start-group ~/intel/Compiler/11.1/064/mkl/lib/em64t"/libmkl_intel_lp64.a "~/intel/Compiler/11.1/064/mkl/lib/em64t"/libmkl_intel_thread.a "~/intel/Compiler/11.1/064/mkl/lib/em64t"/libmkl_core.a "~/intel/Compiler/11.1/064/mkl/lib/em64t"/libmkl_solver_lp64.a -Wl,--end-group -L"~/intel/Compiler/11.1/064/mkl/lib/em64t" -openmp -lpthread -lm -DMKL_Complex16="std::complex" -static-intel
compiler shouldn`t put dependencies to libguide to your application. Looks like this dependency is coming from somewhere else (for example, from third-party libs which you are using in your application). Could you provide FULL link line?