通常我们会对vimrc文件加以配置(如将TAB键自动转换为4个空白键). 但正是由于将tab键转换为n个空白键,使得用vim编写的Makefile中不存在tab键(即“\t”)了.恰恰Makefile中以tab键作为命令行的起始标记. 所以现在找到了报错的原因,即tab键被替换为空白键了.解决方法是:在.vimrc中加入下列配置行: autocmd FileType make set noexpandtab…
makefile has a very stupid relation with tabs, all actions of every rule are identified by tabs ...... and No 4 spaces don't make a tab, only a tab makes a tab... makefile使用tab来作为separator.如果你使用4个空格就会报错,makefile:n: *** missing separator. Stop,其中n是第几行…