[引用〕Windows上的GNU开发平台:MinGW

MinGW:即Minimalist GNU for Windows。它是一些头文件和函数库的集合,该集合允许人们在没有第三方动态链接库的情况下使用GCC(GNU Compiler C)产生Win32程序。

MinGW主要由GNU binary utilities、GCC和GDB组成。同时还包括一些必要的库,例如libc(C Runtime),及专门用于Win32环境的API接口库。如果你想学习linux环境下的编程,而又不想装linux,那你就装一个MinGW吧。

MSYS:Minimal GNU(POSIX)system on Windows,是一个小型的GNU环境,包括基本的bash,make等等。是Windows下最优秀的GNU环境。(是否厌倦了Cygwin蜗牛般的shell环境,试试MSYS中的rxvt吧)

MinGW & MSYS的主页:http://mingw.sourceforge.net/

配置MinGW环境
MinGW + MSYS + W32API

1、到http://sourceforge.net/projects/mingw/下载MinGW(我的版本是MinGW-3.1.0-1.exe)

     安装解压到 D:/MinGW目录

     在环境变量PATH中加入 D:/MinGW/bin

2、下载MSYS(我的版本是MSYS-1.0.10.exe)

     安装过程根据提示设置MinGW的路径。

3、下载Win32Api包(我的版本w32api-3.2-src.tar.gz)

    解压到D:/src/w32api-3.2目录;

    在msys环境下

   $ cd /d/src/w32api-3.2

   $ ./configure --prefix=/d/MinGW/

   $ make

   $ make install

 

注意:mingw的bin目录有一个mingw32-make.exe,msys的bin目录下也有一个make.exe。至于为什么会有mingw32-make.exe这个名字,MinGW的FAQ中说

Why is make named mingw32-make.exe?
The "native" (i.e.: MSVCRT dependent) port of make is lacking in some functionality and has modified functionality due to the lack of POSIX on Win32. There also exists a version of make in the MSYS distribution that is dependent on the MSYS runtime. This port operates more as make was intended to operate and gives less headaches during execution. Based on this, the MinGW developers/maintainers/packagers decided it would be best to rename the native version so that both the "native" version and the MSYS version could be present at the same time without file name collision.

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值