-
Notifications
You must be signed in to change notification settings - Fork 42
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
Build package with compilers without OpenMP support #61
Comments
This issue seems to be fixed for package xgboost as documented here. They use a configure script to detect OSX and set the OpenMP flags accordingly. |
CRAN OS X binaries are now build using OpenMP, so that should solve the OpenMP problem for most Mac users. The same applies to the |
Hi Mark , Package "fst" starting on my mac with single core support. OpenMP is installed and declared . Can you help ? sessionInfo() Platform: x86_64-apple-darwin17.7.0 (64-bit)
Running under: macOS 10.14.1
Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /usr/local/Cellar/openblas/0.3.3/lib/libopenblasp-r0.3.3.dylib
locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] fst_0.8.8
loaded via a namespace (and not attached):
[1] compiler_3.5.1 parallel_3.5.1 tools_3.5.1 yaml_2.2.0 Rcpp_1.0.0.1 ~/.R/.Makevar
|
Hi @robbig2871, thanks for posting your question. From your build output I can see that the I think you can fix that by adding the following line to your CXX11 = $(LLVM_LOC)/bin/clang++ -fopenmp you could also change the CPPFLAGS = -I/usr/local/opt/gettext/include -I$(LLVM_LOC)/include -g -O3 -Wall -pedantic that should trigger the new clang++ compiler and add the -openmp and -g -O3 -Wall -pedantic options. By the way, with the Travis continuous integration build for brew install llvm
export PATH="/usr/local/opt/llvm/bin:$PATH"
export LDFLAGS="-L/usr/local/opt/llvm/lib"
export CPPFLAGS="-I/usr/local/opt/llvm/include"
export PKG_CXXFLAGS="-O3 -Wall -pedantic" (and there is no I would be interested to see if one of these options will work for your setup, please let me know! |
Hi @MarcusKlik . Regarding Makevar - after changes and reinstallation fst see 8 threads ! Regarding travis ... R from cmd line ... some issue found.
|
Hi @robbig2871, thanks for testing both options! The method used on Travis appears to result in some linker problems, I will have to take a closer look to see what's going on. But it's good to hear that the updated Makevars does the trick! |
Still happening today (latest R, no OpenMP installed)
(If you'll pardon my French — Mac OS X is weird, at least |
Currently,
fst
can't be build on OSX systems that don't have manually installed OpenMP (for example using these instructions). Without OpenMP support,fst
should still be able to built and use single-threaded mode only. The same issue applies to thedata.table
package (see Rdatatable/data.table#2161).The text was updated successfully, but these errors were encountered: