- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
I would like to perform the compilation of the following C code (which is saved on the path "C:\Users\Desktop\example.c") directly within the R desktop environment.
#include <stdio.h>
#include <mkl.h>
int main() {
double x[] = {1.0, 2.0, 3.0};
double y[] = {4.0, 5.0, 6.0};
double z;
// Perform vector multiplication and summation using Intel MKL
z = cblas_ddot(3, x, 1, y, 1);
printf("Result: %lf\n", z);
return 0;
}
I executed the following command in R desktop, but an issue occurred during the process.
> system('icx -o myfunction "C:\\Users\\Desktop\\example.c" /Qmkl /MD')
Intel(R) oneAPI DPC++/C++ Compiler for applications running on Intel(R) 64, Version 2023.1.0 Build 20230320
Copyright (C) 1985-2023 Intel Corporation. All rights reserved.
LINK : fatal error LNK1104: cannot open file 'libiomp5md.lib'
icx: error: linker command failed with exit code 1104 (use -v to see invocation)
[1] 1104
My environment variables are displayed in the image below.
I've installed the Intel® oneAPI Base Toolkit on a Windows platform.
Than you very much.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Thanks for posting in Intel Communities.
>>C code (which is saved on the path "C:\Users\Desktop\example.c") directly within the R desktop environment.
Could you please let us know the R version you have downloaded and who you are trying to link with which version of the Intel MKL?
Also, could you please provide us with the complete steps you followed on R Desktop to compile this code Intel compilers?
Thanks & Regards,
Varsha
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
>>LINK : fatal error LNK1104: cannot open file 'libiomp5md.lib'
Regarding the error you are getting on libiomp5md.lib file is from the Intel compilers folder, could you please check whether everything is installed properly and also check whether you are linking properly whether it is 32-bit or 64-bit?
Could you please try linking the Intel Compilers with Intel MKL and let us know if you are facing any errors?
Thanks & Regards,
Varsha
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
We have not heard back from you. Could you please provide us with an update on your issue?
Thanks & Regards,
Varsha
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
We have not heard back from you. Could you please provide us with an update on your issue?
Thanks & Regards,
Varsha
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page