Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
28446 Discussions

Compiling with ifort: cannot find -lmkl_em64t

Widner__Max
Beginner
1,191 Views

Hello, my experience with Fortran is pretty limited so I apologize in advance if I don't provide all the necessary information. I'm trying to run a makefile but getting errors stating "cannot find -lmkl_em64t." There are other issues but I'm not sure if they're detrimental or not. Here is my makefile:

**************************

libs =
OPT = -O3 -xT -r8 -i8 -FR -WB -save -static -zero -nus -mp -double_size 128
COPT =
LOPT = -Wl,-rpath,${TACC_MKL_LIB} -L${TACC_MKL_LIB} -lmkl_em64t -lc -nus
 
OBJS=  \
ser_v10_whitecone_correctPSD.o gasdev.o rk4.o osc_stm.o \
  osc_deriv.o
 
ser_v10_whitecone_correctPSD.exe: $(MOBJS) $(OBJS)
ifort -o ser_v10_whitecone_correctPSD.exe $(LOPT) $(MOBJS) $(OBJS)
 
.SUFFIXES:      .o .f .f90 
 
.f.o:
ifort $(OPT) -c $<
 
.f90.o:
ifort $(OPT) -c $<
 
.c.o:
icc $(COPT) -c $<
 
***************
And here are the errors I'm receiving:
***************
login3.ls5(1039)$ make
ifort -O3 -xT -r8 -i8 -FR -WB -save -static -zero -nus -mp -double_size 128 -c ser_v10_whitecone_correctPSD.f90
ifort: command line remark #10279: option '-xT' is deprecated and will be removed in a future release. See '-help deprecated'
ifort: command line remark #10148: option '-nus' not supported
ifort: command line remark #10148: option '-mp' not supported
ifort -O3 -xT -r8 -i8 -FR -WB -save -static -zero -nus -mp -double_size 128 -c gasdev.f90
ifort: command line remark #10279: option '-xT' is deprecated and will be removed in a future release. See '-help deprecated'
ifort: command line remark #10148: option '-nus' not supported
ifort: command line remark #10148: option '-mp' not supported
ifort -O3 -xT -r8 -i8 -FR -WB -save -static -zero -nus -mp -double_size 128 -c rk4.f90
ifort: command line remark #10279: option '-xT' is deprecated and will be removed in a future release. See '-help deprecated'
ifort: command line remark #10148: option '-nus' not supported
ifort: command line remark #10148: option '-mp' not supported
ifort -O3 -xT -r8 -i8 -FR -WB -save -static -zero -nus -mp -double_size 128 -c osc_stm.f90
ifort: command line remark #10279: option '-xT' is deprecated and will be removed in a future release. See '-help deprecated'
ifort: command line remark #10148: option '-nus' not supported
ifort: command line remark #10148: option '-mp' not supported
ifort -O3 -xT -r8 -i8 -FR -WB -save -static -zero -nus -mp -double_size 128 -c osc_deriv.f90
ifort: command line remark #10279: option '-xT' is deprecated and will be removed in a future release. See '-help deprecated'
ifort: command line remark #10148: option '-nus' not supported
ifort: command line remark #10148: option '-mp' not supported
ifort -o ser_v10_whitecone_correctPSD.exe -Wl,-rpath,/opt/apps/intel/16.0.1.150/compilers_and_libraries_2016.1.150/linux/mkl/lib/intel64 -L/opt/apps/intel/16.0.1.150/compilers_and_libraries_2016.1.150/linux/mkl/lib/intel64 -lmkl_em64t -lc -nus  ser_v10_whitecone_correctPSD.o gasdev.o rk4.o osc_stm.o osc_deriv.o
ifort: command line remark #10148: option '-nus' not supported
ld: cannot find -lmkl_em64t
make: *** [ser_v10_whitecone_correctPSD.exe] Error 1
 
 
*****************************************
Like I said, I'm pretty new to this so I'm not sure if I'm providing enough information or not. Any advice would be greatly appreciated!
0 Kudos
1 Solution
Steve_Lionel
Honored Contributor III
1,191 Views

That library name was very likely changed many years ago - and I'm not sure if that was ever a provided library. Try just -lmkl . If you need more help, see the MKL forum or the MKL Link Line Advisor.

View solution in original post

0 Kudos
3 Replies
Steve_Lionel
Honored Contributor III
1,192 Views

That library name was very likely changed many years ago - and I'm not sure if that was ever a provided library. Try just -lmkl . If you need more help, see the MKL forum or the MKL Link Line Advisor.

0 Kudos
mecej4
Honored Contributor III
1,191 Views

Indeed, as Steve suspects, your makefile is several years older than your compiler. You should probably use -lmkl_intel_lp64 instead of -lmkl_em64t if integer arguments to MKL routines are 32-bits long, but it is best to consult the MKL Link Line Advisor. Once you find the proper set of libraries to use, you should probably update your makefile accordingly.

Instead of -xT, use -xSSE3.

 

0 Kudos
Widner__Max
Beginner
1,191 Views
Thank you both for your input. I assumed it was something along these lines. I will check the references you both mentioned. Thank you!
0 Kudos
Reply