Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Guillaume_A_
New Contributor I
250 Views

OneApi Dal - No more Multi-threaded DLL runtime library?

Jump to solution

Hello,

I recently upgraded my Intel tools suite from Intel Composer 2020.1.216 to OneAPI 2021.1.1.

I modified the compilation parameters/options of my program to use the Intel compiler 19.2, to use OneAPI dal includes and to link to OneAPI dal libs.

When I try to compile and link my program I now get an error:  error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MD_DynamicRelease' in ReproducerDaal.obj

Ok, it means that the daal libs have been compiled with /MT but mines are compiled with /MD option.

Did you change that? Are you now building daal's .lib with /MT instead of /MD option?

  • If yes: Why?? I have to rethink the whole architecture of my program...
  • If no: Something is wrong with my compilation command...

It's weird because I do not have the same behavior with MKL lib...

I provide you a reproducer in attachment:

  • ReproducerDaal.cpp: a simple program that do calls to Daal and MKL routines.
  • ReproducerDaal_OneApi.vcxproj: to compile with icl 19.2 and use OneAPI 2021.1.1
  • ReproducerDaal_Composer.vcxproj: to compile with icl 19.1 and use Composer 2020.1.216

You will notice that with Composer ReproducerDaal.cpp compiles and links fine with both options /MT or /MD (weird!). With OneApi the compilation fails with the /MD option.

My config: Visual 2019, Windows 10 64bit.

Thanks in advance for your advice,

Guillaume A.

0 Kudos

Accepted Solutions
Mikhail_A_Intel
Employee
144 Views

Hi Guillaume,

Yes, since one of betas of oneAPI, oneDAL changed an approach for building library package for Microsoft Windows, and at the moment oneDAL does not provide binaries with both static and dynamic linkages with C/C++ run-time library. It's known problem and oneDAL team investigates possible solutions. I suggest you following options:

1. Use DAAL instead of oneDAL. DAAL supports both static and dynamic linkage with C/C++ runtime library for single binary package of DAAL.

or

2. Build oneDAL by yourself from sources (https://github.com/oneapi-src/oneDAL) and manually change linking with C/C++ runtimes in the makefile (https://github.com/oneapi-src/oneDAL/blob/master/makefile). See https://github.com/oneapi-src/oneDAL/blob/master/INSTALL.md for details about building oneDAL from sources.

 

Michael.

 

View solution in original post

7 Replies
AbhishekD_Intel
Moderator
204 Views

Hi,


Thanks for reaching out to us.

As this issue is more related to DAL we are moving this issue to the Intel® oneAPI Data Analytics Library & Intel® Data Analytics Acceleration Library forum.


Warm Regards,

Abhishek


JananiC_Intel
Moderator
173 Views

Hi,


We have informed the SME about this.We will get back to you on this shortly.


Regards,

Janani Chandran


Mikhail_A_Intel
Employee
145 Views

Hi Guillaume,

Yes, since one of betas of oneAPI, oneDAL changed an approach for building library package for Microsoft Windows, and at the moment oneDAL does not provide binaries with both static and dynamic linkages with C/C++ run-time library. It's known problem and oneDAL team investigates possible solutions. I suggest you following options:

1. Use DAAL instead of oneDAL. DAAL supports both static and dynamic linkage with C/C++ runtime library for single binary package of DAAL.

or

2. Build oneDAL by yourself from sources (https://github.com/oneapi-src/oneDAL) and manually change linking with C/C++ runtimes in the makefile (https://github.com/oneapi-src/oneDAL/blob/master/makefile). See https://github.com/oneapi-src/oneDAL/blob/master/INSTALL.md for details about building oneDAL from sources.

 

Michael.

 

View solution in original post

Guillaume_A_
New Contributor I
138 Views

Hi Michael, tanks for your reply. 

First option (Use DAAL instead of oneDAL) means to be stuck in 2020...

For the moment I will consider the second option: Build oneDAL by myself.

It will be great if the next releases of oneDAL could provide binaries with both static and dynamic linkages.

Regards,

Guillaume A.

JananiC_Intel
Moderator
103 Views

Hi,


Did the solution provided help?Can we close the case?


Regards,

Janani Chandran


Guillaume_A_
New Contributor I
93 Views

Yes it is fine to me.

Regards,

Guillaume A.

JananiC_Intel
Moderator
78 Views

Hi,


Thanks for the confirmation .We would discontinue monitoring this issue. Please raise a new thread if you have any further issues.


Regards,

Janani Chandran