(1)下载 MinGW64 工具包:https://newsoftdown01.rbread05.cn/down/2022down/1/30/mingw64.rar?timestamp=62610c7e&auth_key=2d742e62ca21eb90cd1624ce4889a284&sign=0a6eff276846febce1b25fdb5d9e6b28&t=62611a8e
我是放在 E 盘文件夹里面:然后解压后直接在电脑环境变量配置:
MinGW_HOME = E:\mingw64
path = %MinGW_HOME%\bin;%MinGW_HOME%\include;
=================================================================
(2)查看是否安装成功:gcc -v
展示:
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=d:/java/mingw7.2.0/64-bits/bin/../libexec/gcc/x86_64-w64-mingw32/7.2.0/lto-wrapper.exe
Target: x86_64-w64-mingw32
Configured with: ../source/gcc-7.2.0/configure --build=x86_64-pc-mingw32 --target=x86_64-w64-mingw32 --disable-shared --enable-static --disable-nls --disable-multilib --prefix=/r/make6t4/newsystem/mingw-w64-x86_64 --with-sysroot=/r/make6t4/newsystem/mingw-w64-x86_64 --with-mpc=/r/make6t4/newsystem/pkgs/mpc/mpc-1.0.3-x86_64 --with-mpfr=/r/make6t4/newsystem/pkgs/mpfr/mpfr-3.1.5-x86_64 --with-gmp=/r/make6t4/newsystem/pkgs/gmp/gmp-6.1.2-x86_64 --with-isl=/r/make6t4/newsystem/pkgs/isl/isl-0.16.1-x86_64 --enable-languages=c,c++ --enable-fully-dynamic-string --enable-lto
Thread model: win32
gcc version 7.2.0 (GCC)
即是安装成功。