Community
cancel
Showing results for 
Search instead for 
Did you mean: 
John_Young
New Contributor I
33 Views

MKL compile failure with scalapack/pblas

Hi, When I try to compile some c++ code using scalapack and pblas on Windows, I get the compile errors shown below. A simple test case is #include "mkl_pblas.h" #include "mkl_scalapack.h" int main() { return 0; } The problem seems to be that mkl_scalapack.h and mkl_pblas.h both define the functions pdtran/pstran, etc.. If I comment out one or the other headers, the code compiles fine. In my full code, I need access to both scalapack and the pblas. I don't see this behavior on a *nix box. I'm using VS2010, Windows 7, MKL 11.1.2. Is there anyway around this problem? Thanks, John :\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(180): error C2733: second C linkage of overloaded function 'pstran' not allowed 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(180) : see declaration of 'pstran' 1>C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(181): error C2733: second C linkage of overloaded function 'pdtran' not allowed 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(181) : see declaration of 'pdtran' 1>C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(549): error C2733: second C linkage of overloaded function 'PSTRAN' not allowed 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(549) : see declaration of 'PSTRAN' 1>C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(550): error C2733: second C linkage of overloaded function 'PDTRAN' not allowed 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(550) : see declaration of 'PDTRAN' 1>C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(551): error C2733: second C linkage of overloaded function 'PSTRAN_' not allowed 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(551) : see declaration of 'PSTRAN_' 1>C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(552): error C2733: second C linkage of overloaded function 'PDTRAN_' not allowed 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(552) : see declaration of 'PDTRAN_' 1>C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(553): error C2733: second C linkage of overloaded function 'pstran_' not allowed 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(553) : see declaration of 'pstran_' 1>C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(554): error C2733: second C linkage of overloaded function 'pdtran_' not allowed 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(554) : see declaration of 'pdtran_'

0 Kudos
4 Replies
John_Young
New Contributor I
33 Views

I'm not sure why the formatting is so bad in the original post. Here is another try. When I try to compile some c++ code using scalapack and pblas on Windows, I get the compile errors shown below. A simple test case is #include "mkl_pblas.h" #include "mkl_scalapack.h" int main() { return 0; } The problem seems to be that mkl_scalapack.h and mkl_pblas.h both define the functions pdtran/pstran, etc.. If I comment out one or the other headers, the code compiles fine. In my full code, I need access to both scalapack and the pblas. I don't see this behavior on a *nix box. I'm using VS2010, Windows 7, MKL 11.1.2. Is there anyway around this problem? Thanks, John :\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(180): error C2733: second C linkage of overloaded function 'pstran' not allowed 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(180) : see declaration of 'pstran' 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(181): error C2733: second C linkage of overloaded function 'pdtran' not allowed 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(181) : see declaration of 'pdtran' 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(549): error C2733: second C linkage of overloaded function 'PSTRAN' not allowed 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(549) : see declaration of 'PSTRAN' 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(550): error C2733: second C linkage of overloaded function 'PDTRAN' not allowed 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(550) : see declaration of 'PDTRAN' 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(551): error C2733: second C linkage of overloaded function 'PSTRAN_' not allowed 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(551) : see declaration of 'PSTRAN_' 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(552): error C2733: second C linkage of overloaded function 'PDTRAN_' not allowed 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(552) : see declaration of 'PDTRAN_' 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(553): error C2733: second C linkage of overloaded function 'pstran_' not allowed 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(553) : see declaration of 'pstran_' 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(554): error C2733: second C linkage of overloaded function 'pdtran_' not allowed 1> C:\Program Files (x86)\Intel\Composer XE 2013 SP1\mkl\include\mkl_pblas.h(554) : see declaration of 'pdtran_'

Evarist_F_Intel
Employee
33 Views

Hi John!

Yes, we faced with this problem sometime ago on this forum. The bug is fixed and MKL 11.1.3 will be without it.

For now as workaround you can remove lines 750-751 and 2573-2578 from mkl_scalapack.h (all these lines contain either pstran or pdtran (w/ w/o _ and upper- and lowercase).

Thank you!

Gennady_F_Intel
Moderator
33 Views

We will inform you when the fix of the problem would be available. Stat tuned.

John_Young
New Contributor I
33 Views

Thanks. That workaround solved the problem.