I am trying to configure and build an open source program from the internet which is intended to be used with Matlab. This is my first time trying to install an open source program and I keep running into issues. I have been using the cmake GUI to try and configure my program, however this is the result I get:
My problem appears to be with OpenMP, which I understand is not supported by AppleClang. I have installed gcc and gcc47 to try and fix the problem but I don't know how to set the default compiler to either of these. When I select 'configure' in cmake, it gives me the following options:
Use default native compilers
Specify native compilers
Specify toolchain file for cross-compiling
Specify options for cross-compiling
For the configuration above I used 'default native compilers'. I have also tried the 'specify native compilers' entering in the gcc47 path but then it doesn't complete.
Any help or advice is greatly appreciated. Thank you.
Code:
The C compiler identification is AppleClang 6.0.0.6000056
The CXX compiler identification is AppleClang 6.0.0.6000056
Check for working C compiler: /usr/bin/cc
Check for working C compiler: /usr/bin/cc -- works
Detecting C compiler ABI info
Detecting C compiler ABI info - done
Check for working CXX compiler: /usr/bin/c++
Check for working CXX compiler: /usr/bin/c++ -- works
Detecting CXX compiler ABI info
Detecting CXX compiler ABI info - done
Try OpenMP C flag = [ ]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP C flag = [-fopenmp]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP C flag = [/openmp]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP C flag = [-Qopenmp]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP C flag = [-openmp]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP C flag = [-xopenmp]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP C flag = [+Oopenmp]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP C flag = [-qsmp]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP C flag = [-mp]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP CXX flag = [ ]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP CXX flag = [-fopenmp]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP CXX flag = [/openmp]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP CXX flag = [-Qopenmp]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP CXX flag = [-openmp]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP CXX flag = [-xopenmp]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP CXX flag = [+Oopenmp]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP CXX flag = [-qsmp]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Try OpenMP CXX flag = [-mp]
Performing Test OpenMP_FLAG_DETECTED
Performing Test OpenMP_FLAG_DETECTED - Failed
Could NOT find OpenMP (missing: OpenMP_C_FLAGS OpenMP_CXX_FLAGS)
Performing Test HAS_BRANCH_PEDICTION
Performing Test HAS_BRANCH_PEDICTION - Success
Using bash: /bin/bash
Using perl: /usr/bin/perl
Performing Test HAS_GETOPT
Performing Test HAS_GETOPT - Success
getopt found.
Found ZLIB: /usr/lib/libz.dylib (found version "1.2.5")
Found OpenEXR: /usr/local/lib/libHalf.dylib
Found ImageMagick: /usr/local/Cellar/imagemagick/6.9.0-3/lib/libMagick++-6.Q16.dylib
ImageMagick CFLAGS: /usr/local/Cellar/imagemagick/6.9.0-3/include/ImageMagick-6
Found NETPBM: /usr/local/lib/libnetpbm.a
Found TIFF: /usr/local/lib/libtiff.dylib
Looking for Q_WS_X11
Looking for Q_WS_X11 - not found
Looking for Q_WS_WIN
Looking for Q_WS_WIN - not found
Looking for Q_WS_QWS
Looking for Q_WS_QWS - not found
Looking for Q_WS_MAC
Looking for Q_WS_MAC - found
Looking for QT_MAC_USE_COCOA
Looking for QT_MAC_USE_COCOA - found
Found Qt4: /usr/local/bin/qmake (found version "4.8.6")
Qt4 found
Failed to find matlab root directory. Specify it manually by setting MATLAB_ROOT cmake cache variable.
Found OpenGL: /System/Library/Frameworks/OpenGL.framework
Found GLUT: /System/Library/Frameworks/GLUT.framework
Found FFTW: /usr/local/lib/libfftw3.dylib
Using GSL from /usr/local/Cellar/gsl/1.16
mkoctfile found.
OpenCV library found.
Configuring done
My problem appears to be with OpenMP, which I understand is not supported by AppleClang. I have installed gcc and gcc47 to try and fix the problem but I don't know how to set the default compiler to either of these. When I select 'configure' in cmake, it gives me the following options:
Use default native compilers
Specify native compilers
Specify toolchain file for cross-compiling
Specify options for cross-compiling
For the configuration above I used 'default native compilers'. I have also tried the 'specify native compilers' entering in the gcc47 path but then it doesn't complete.
Any help or advice is greatly appreciated. Thank you.
Last edited by a moderator: