-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
set_omp_num_threads compiling error (utils.cpp) #5
Comments
The cimg_use_openmp macro is *always* defined by CImg.h, but its *value* is either 0 or 1 depending on whether OpenMP is defined or not. This was breaking compilation on platforms without OpenMP. This fix should address #5. Signed-off-by: Rodrigo Tobar <rtobar@icrar.org>
@gvogler thanks for reporting this. Could you try the fix I just pushed to the |
The cimg_use_openmp macro is *always* defined by CImg.h, but its *value* is either 0 or 1 depending on whether OpenMP is defined or not. This was breaking compilation on platforms without OpenMP. This also uncovered an issue with our code calling Rcpp::cerr instead of Rcpp::Rcerr, which has been fixed now. This fix should address #5. Signed-off-by: Rodrigo Tobar <rtobar@icrar.org>
@gvogler any chance of testing this? We're waiting for feedback to confirm it's all working to then submit a new version to CRAN. If I head nothing in the next 24 hours I'll assume it's all good (it was when testing locally). Thanks! |
@rtobar That version compiled without problems. Thanks! |
@gvogler that on the |
@gvogler thanks for reporting back, we'll merge now and try to upload to CRAN. |
Hi!
When compiling in R (macOS, arm64) I am getting the following error:
utils.cpp:336:3: error: use of undeclared identifier 'omp_set_num_threads'; did you mean 'set_omp_num_threads'? omp_set_num_threads(threads); ^~~~~~~~~~~~~~~~~~~ set_omp_num_threads utils.cpp:333:6: note: 'set_omp_num_threads' declared here void set_omp_num_threads(int threads) ^ 1 error generated. make: *** [utils.o] Error 1
The text was updated successfully, but these errors were encountered: