我正在尝试在 macOS Sierra 上安装 wgrib2。我已按照此博客上的说明进行操作。这是终端中发生的事情:
rm tmpaec.tar
cd "/usr/local/grib2/libaec-1.0.0" && export CFLAGS="-I/usr/local/grib2/include -Wall -Wmissing-prototypes -Wold-style-definition -Werror=format-security --fast-math -O3 -DGFORTRAN -fopenmp -I/usr/local/grib2/jasper-1.900.1/src/libjasper/include -I/usr/include " && ./configure --disable-shared --prefix=/usr/local/grib2 && make check install
checking build system type... x86_64-apple-darwin16.7.0
checking host system type... x86_64-apple-darwin16.7.0
checking how to print strings... printf
checking for gcc... gcc
checking whether the C compiler works... no
configure: error: in `/usr/local/grib2/libaec-1.0.0':
configure: error: C compiler cannot create executables
See `config.log' for more details
make: *** [/usr/local/grib2/lib/libaec.a] Error 77
这是我可以在 config.log 中看到的内容:
configure:2882: gcc -V >&5
clang: error: argument to '-V' is missing (expected 1 value)
clang: error: no input files
configure:2893: $? = 1
configure:2882: gcc -qversion >&5
clang: error: unknown argument: '-qversion'
clang: error: no input files
configure:2893: $? = 1
configure:2913: checking whether the C compiler works
configure:2935: gcc -I/usr/local/grib2/include -Wall -Wmissing-prototypes -Wold-style-definition -Werror=format-security --fast-math -O3 -DGFORTRAN -fopenmp -I/usr/local/grib2/jasper-1.900.1/src/libjasper$
clang: error: unsupported option '--fast-math'
clang: error: unsupported option '-fopenmp'
clang: error: unsupported option '-fopenmp'
configure:2939: $? = 1
configure:2977: result: no
configure: failed program was:
我该如何解决这个问题?