Miscrosoft Visual C++ 2003 ToolKit 出来后高兴了一阵,又可以拾起C++代码了,在/bin目录下找了一下,居然没有提供MAKE程序, 这让我使用gVim很不方便。自己写了一个脚本,勉强支持ISO C++.但不支持Mirosoft.Net Framework
我已经提交给 http://vim.sourceforge.net/scripts/index.php 有兴趣的朋友和我联系,把它写的更好!
安装
1.添加环境变量
Set PATH=D:\Microsoft Visual C++ Toolkit 2003\bin;%PATH%
Set INCLUDE=D:\Microsoft Visual C++ Toolkit 2003\include;%INCLUDE%
Set LIB=D:\Microsoft Visual C++ Toolkit 2003\lib;%LIB%
( Change D to your drivename )
2.放置msvc2003.vim到vim安装目录compiler子目录下
使用
命令行模式下输入
:compiler msvc2003
:make
msvc2003.vim
------------------------------------------------------------------------------------------------
" Vim compiler file
" Compiler: Miscrosoft Visual C++ 2003 ToolKit
" Important: The version DOSE NOT support Mirosoft.Net Framework
" Only for ISO C++ standard code
" Maintainer: SKY <zhang.bin@163.com>
" Last Change: 2004-07-11
if exists("current_compiler")
finish
endif
let current_compiler = "msvc2003"
let s:cpo_save = &cpo
set cpo-=C
" The errorformat for MSVC-2003 is the default.
setlocal errorformat&
setlocal makeprg=cl\ /EHsc\ /TP\ %<.cpp\ /Fe%<.exe
let &cpo = s:cpo_save
unlet s:cpo_save
------------------------------------------------------------------------------------------------