[Trilinos-Users] Installing with Intel MKL

Mark Hoemmen mhoemme at sandia.gov
Sun Nov 21 21:53:29 MST 2010


On Nov 21, 2010, at 10:41 AM, trilinos-users-request at software.sandia.gov wrote:
> Message: 1
> Date: Sun, 21 Nov 2010 08:09:23 -0800 (PST)
> From: einaro at yahoo.com
> Subject: [Trilinos-Users] Installing with Intel MKL
> To: trilinos-users at software.sandia.gov
> Message-ID: <155585.87484.qm at web111613.mail.gq1.yahoo.com>
> Content-Type: text/plain; charset="us-ascii"
> 
> Dear experts,
> I have been trying to install Trilinos using the BLAS/LAPACK libraries from
> Intel MKL, but I have a few questions to how to set up the cmake script. I
> started from one of the scripts provided with the distribution.
> 
> The problem is related to providing the path to the blas/lapack libraries which
> does not seem to work for me. In order to make this work I need to provide the
> path inside the
> 
> TPL_LAPACK_LIBRARIES definition as
> "-D  TPL_LAPACK_LIBRARIES:STRING="-L/opt/intel/Compiler/11.1/073/mkl/lib/em64t
> -lmkl_intel_lp64 -Wl,--start-group -lmkl_intel_thread -lmkl_core
> -Wl,--end-group -lguide -lpthread" "
> This is also done in a few of the sampleScripts which are provided with the
> distribution.
> 
> My problem with this is that when I want to link trilinos into my own programs,
> the compiler thinks that the path is a library and try to link in
> "-l -L/opt/intel/Compiler/11.1/073/mkl/lib/em64", which then causes some
> problems.
> 
> Can you please tell me what I'm doing wrong?
> 
> The cmake script I'm using follows below...
> 
> Thanks,
> 
> Einar
> 
> #####################################################################################
> 
> #!/bin/bash
> 
> TRILINOS_PATH=~/Software/src/trilinos-10.6.1-Source
> EXTRA_ARGS=$@
> FORTRAN_LIBRARIES=""
> 
> 
> 
> 
> 
> 
> cmake \
>          -D CMAKE_BUILD_TYPE:STRING=DEBUG \
>          -D
> CMAKE_INSTALL_PREFIX:PATH=~/Software/src/trilinos-10.6.1-Source/installed \
>          -D Trilinos_ENABLE_DEFAULT_PACKAGES:BOOL=ON \
>          -D Trilinos_ENABLE_ALL_PACKAGES:BOOL=OFF \
>          -D Trilinos_ENABLE_Tpetra:BOOL=ON \
>          -D Trilinos_ENABLE_Teuchos:BOOL=ON \
>          -D Trilinos_ENABLE_TESTS:BOOL=ON \
>          -D TPL_ENABLE_Boost:BOOL=ON \
>          -D TPL_ENABLE_BLAS:BOOL=ON \
>          -D TPL_ENABLE_LAPACK:BOOL=ON \
>          -D Boost_INCLUDE_DIRS:PATH="/dd/Packages/boost/1.41.0/include" \
>          -D Boost_LIBRARY_DIRS:PATH="/dd/Packages/boost/1.41.0/lib" \
>          -D
> TPL_BLAS_LIBRARY_DIRS:PATH="/opt/intel/Compiler/11.1/073/mkl/lib/em64t" \
>          -D BLAS_LIBRARY_DIRS:PATH="/opt/intel/Compiler/11.1/073/mkl/lib/em64t"
> \
>          -D TPL_LIBRARY_DIRS:PATH="/opt/intel/Compiler/11.1/073/mkl/lib/em64t"
> \
>          -D
> Trilinos_TPL_LIBRARY_DIRS:PATH="/opt/intel/Compiler/11.1/073/mkl/lib/em64t" \
>          -D
> TPL_BLAS_LIBRARIES:STRING="-L/opt/intel/Compiler/11.1/073/mkl/lib/em64t
> -lmkl_intel_lp64 -Wl,--start-group -lmkl_intel_thread -lmkl_core -Wl,--end-group
> -lguide -lpthread" \

Greetings --

If you are setting BLAS_LIBRARY_DIRS already, then you should be able to omit the directory in TPL_BLAS_LIBRARIES, right?

mfh


More information about the Trilinos-Users mailing list