Skip to content
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

Compiling liblinear via Matlab on mac #16

Open
roseperrone opened this issue Nov 5, 2014 · 3 comments
Open

Compiling liblinear via Matlab on mac #16

roseperrone opened this issue Nov 5, 2014 · 3 comments

Comments

@roseperrone
Copy link

liblinear depends on OpenMP, which gcc4.9 supports. I tried to make sure Matlab uses gcc4.9, and some evidence indicates it does, and some that it doesn't. This is the error I find:

external/liblinear-1.93_multicore/matlab/train.cpp:7:10: fatal error: 'omp.h' file not found
#include <omp.h>
         ^
1 error generated.

    mex: compile of ' "external/liblinear-1.93_multicore/matlab/train.cpp"' failed.

I made sure to change the /openmp option to -fopenmp because I'm on mac.

I asked this question on StackOverflow: http://stackoverflow.com/questions/26724667/openmp-not-available-on-mac-with-gcc-4-9.

@wuxinhong
Copy link

hello beauty,nice to meet you

@sunshineatnoon
Copy link

You need to change mat lab's compiler to real gcc rather than Xcode's clang compiler. Try this:http://stackoverflow.com/questions/20340117/omp-h-library-isnt-found-in-the-gcc-version-4-2-1-in-mavericks , the second answer works for me on mac 10.9.

@samuelhoover
Copy link

samuelhoover commented Apr 9, 2020

@roseperrone Was there ever a solution to your problem? Currently experiencing a similar issue with MATLAB 2019b on Catalina 10.15.4.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants