- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello everybody,
I'm willing to use/link a static C++ library, compiled with intel compiler, in my pure visual studio project which use the native C++ visual compiler.
When linking, i get some unresolved errors, how can fix that ? Do intel and microsoft compiler ABI are compatible ?
Do i need to build the static library using a specific calling convention ?
Thanks for you help.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Thanks for reaching out to us.
>> Do intel and microsoft compiler ABI are compatible ?
Yes, it is compatible. You can create/link static library with Intel C++ compiler and can be used in visual studio project that uses C++ visual compiler.
We have tried to create a sample static library using Intel C++ compiler (2021.5/2022.0) and used this library in another source file that compiled with visual C++ compiler.
Creating static library:
1. Open visual studio and create Windows Desktop Wizard project type
Please find attached screenshot to create.
2.Create Header file and Source file as required by your use case and build it with intel C++ compiler.
Using static library in another project:
1. Create a C++ console application project type
2. Rewrite the .cpp code as per your requirements.
3. On Property Pages, go to C/C++->General->Additional Include Directories and provide the path, where the header file of the library that you want to use is located.
4. Then go to Linker->General->Additional Library Directories and specify the path, where your .lib file is located.
5. If you get any linking error (libmmdd.lib is not found), locate for the libmmdd.lib file and specify the path in Linker->General->Additional Library Directories
6. Finally, go to Linker->Input->Additional Dependencies and add the name of the file containing your library together with its extension (e.g. example_library.lib)
7. Build your program and run it.
Please find the attached projects that we have tried.
If this does not match your use-case,
Could you please provide the sample reproducer along steps you have followed to reproduce the issue and the compiler version being used?
>>i get some unresolved errors
Could you please provide us the errors that your are getting?
Thanks & Regards,
Noorjahan.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Thanks for helping, the issue was due to /Qipo optimization in my librarie...
Best regards.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Could you please confirm whether your issue is resolved? If yes, could you please confirm whether can we go ahead and close this issue?
Thanks & regards,
Noorjahan.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
We are closing this thread assuming your issue has been resolved.
We will no longer respond to this thread. If you need any additional information, please submit a new question as this thread will no longer be monitored.
Thanks & Regards,
Noorjahan.
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page