简体   繁体   中英

g++ does not recognize -stdlib=libstdc++

So I just reinstall gcc using home brew, when I compile a programme and try to use libstdc++... I get a error:

dhcp-18-189-47-44:openmp_code myname$ g++-4.8 -fopenmp tmp2.cpp -stdlib=libstdc++
g++-4.8: error: unrecognized command line option '-stdlib=libstdc++'

Someone has idea what is happening ? Thank you.

As the error message clearly says, g++ does not support -stdlib as an option. You can simply remove that option from the command line.

g++-4.8 -fopenmp tmp2.cpp

should be all you need.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM