Installing g++ on windows subsystem for linux

房东的猫 提交于 2019-12-03 15:50:36

Why compiling? You should be able to install the package:

sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt update
sudo apt install g++-7 -y

Verify using:

gcc-7 --version

See How to install gcc-7 or clang 4.0?

run the following

sudo apt install aptitude
sudo aptitude install gcc-7 g++-7

or

sudo apt install aptitude && sudo aptitude install golang gcc-7 g++-7

crt1.o is generally provided as part of the libdevc dependency (or something similar). I would suggest running sudo apt search libc or some similar variant with lib6c, libdev, libc-dev etc. Installing those fixed a similar issue I had recently.

Failing that, run find / -iname ctri.o and add the folder it appears in to your PATH with export PATH="[folder]:$PATH", and see if that helps.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!