While installing on OSX Sierra via gcc-6, keep hav

2019-02-23 07:25发布

Environment info

Operating System: macOS 10.12.2 (16C68)

Compiler: gcc-6

Steps to reproduce

I've installed gcc-6 and modified config.mk as required into export CC = gcc-6 export CXX = g++-6 But keep having this error: g++-6 -c -std=c++0x -Wall -Wno-unknown-pragmas -Iinclude -Idmlc-core/include -Irabit/include -O3 -funroll-loops -msse2 -fPIC -fopenmp src/learner.cc -o build/learner.o FATAL:/opt/local/bin/../libexec/as/x86_64/as: I don't understand 'm' flag!

What have you tried?

  1. Reinstall XCode
  2. Reinstall gcc
  3. Run make clean_all && make -4j

But still went wrong. Any idea?

2条回答
我命由我不由天
2楼-- · 2019-02-23 07:38

I had this issue when using macports-installed gnu assembler. You could try forcing the use of as that comes with Xcode, or simply temporarily removing /opt/local/bin from your path.

查看更多
闹够了就滚
3楼-- · 2019-02-23 07:47

I solved by uninstalling MacPorts:

sudo port -f uninstall installed
查看更多
登录 后发表回答