I already have gcc
and g++
install:
$ which gcc
/usr/bin/gcc
$ which g++
/usr/bin/g++
$ brew install gcc
Warning: gcc-6.2.0 already installed
I follow Compile OpenMP programs with gcc compiler on OS X Yosemite to reinstall gcc
via HomeBrew:
$ brew reinstall gcc --without-multilib
then
$ /usr/bin/g++ openmp.cpp
openmp.cpp:12:10: fatal error: 'omp.h' file not found
#include <omp.h>
^
1 error generated.
with -fopenmp
$ /usr/bin/g++ openmp.cpp -fopenmp
clang: error: unsupported option '-fopenmp'
clang: error: unsupported option '-fopenmp'
What's happening with this redirection? How could I use gcc
/g++
?
Though involved, it's not about OpenMP
.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…