Open http://www.cygwin.cn/site/install/ , download setup.exe ,install through internet。
In URL input:http://www.cygwin.cn/pub/ then put “add”
But Error comes : report about the setup.ini , that is because internet can not be connected.
It strongly cause by the firewall or antivirus software. When i turned them off. It can installed normally.
2. puttycyg setup
edit the "putty" properties with right mouse button. as follows:
then ,can open it directly without settings .
yohoo~ it's really comvenient.
also, you can get reference in http://code.google.com/p/puttycyg/wiki/README.
it introduces the process in detail.
and download the tool :puttycyg-20091228.zip in
http://code.google.com/p/puttycyg/downloads/list
cygwin 使用问题
1. vim 时insert模式不能用箭头, 代码也没有颜色标识。
解决方法:可以添加 vim ~/.vimrc
set nocompatible
set backspace=indent,eol,start
set ruler
set showcmd
set wildmenu
set fo=cqrt
set laststatus=2
set textwidth=78
set ww=<,>,h,l
set autoindent
" set no error bells
set noeb visualbell
set expandtab
set tabstop=4
set shiftwidth=4
set expandtab
let mapleader = ","
syn on
filetype on
filetype plugin on
filetype indent on
保存退出
2. 没有 gcc, 可以在安装中找:
All->Devel下的gcc4: GCC Release Series 4 compiler(C & C++ install helper).
还要查找gdb,安装Devel下的The GNU Debugger
安装完毕cygwin以后,执行gcc -v命令,确定你的gcc真的安装好了,并且版本是4.5.3
3. ls 文件夹之类的没有颜色提示:在cygwin中,默认ls输出没有颜色,可修改$HOME下的.bashrc,以支持颜色输出。
默认alias ls=’ls -h --color=tty’被注释掉啦,去掉注释符。