contrib/download_prerequisites

1.base_url='ftp://gcc.gnu.org/pub/gcc/infrastructure/' 改为base_url='https://gcc.gnu.org/pub/gcc/infrastructure/'

 

2.

下载失败 需要删除已下载的包文件 重新执行 contrib/download_prerequisites

apt install -y gcc g++ && gcc -v && g++ -v