Friday, September 3, 2010

external compiler output into window/buffer/quickfix from vim

Hi,

I'm experimenting in getting my compiler output redirected into vim,
while editing my file to get it bugfree.

When I compile my file in my other program the command is as below:

vcom -work work -2002 -explicit C:/projects/iic_slave_pa_a0.vhd

In this line you can see that:
1) vcom is the external compiler
2) "-work work -2002 -explicit" are the given arguments (without the
double qoute signs ")
3) C:/projects/iic_slave_pa_a0.vhd is the file that is compiled.

In the program the output is something like this:
# Model Technology ModelSim ALTERA vcom 6.5b Compiler 2009.10 Oct 1 2009
# -- Loading package standard
# -- Loading package textio
# -- Loading package std_logic_1164
# -- Loading package std_logic_textio
# -- Loading package std_logic_arith
# -- Loading package std_logic_unsigned
# -- Compiling entity cntrlio_module
# -- Compiling architecture rtl of cntrlio_module
# -- Compiling entity iic_state
# -- Compiling architecture a0 of iic_state
# -- Compiling entity iic_in
# -- Compiling architecture a0 of iic_in
# -- Compiling entity iic_bundle
# -- Compiling architecture a0 of iic_bundle
# -- Compiling entity iic_sync
# -- Compiling architecture a0 of iic_sync
# -- Compiling entity iic_divide
# -- Compiling architecture a0 of iic_divide
# -- Compiling entity iic_init
# -- Compiling architecture rtl of iic_init
# -- Compiling entity iic_register_map
# -- Compiling architecture structure of iic_register_map
# -- Compiling entity iic_88_default
# -- Compiling architecture rtl of iic_88_default
# -- Compiling entity from7to14addresslines
# -- Compiling architecture rtl of from7to14addresslines
# -- Compiling entity iic_io_cntrl
# -- Compiling architecture a0 of iic_io_cntrl
# -- Compiling entity cntrl_module
# -- Compiling architecture structure of cntrl_module
# -- Compiling entity iic_slave_pa_a0
# -- Compiling architecture a0 of iic_slave_pa_a0


If I'm editing my file "iic_slave_pa_a0.vhd" in vim and I want to
compile it, how should I call this external compiler with these arguments?

I've come this far, but this still doesn't work:

nmap <F9> :set makeprg=vcom\ %<<CR>!make [-work work 2002 -explicit] >&1<CR>

What's wrong with this?

I'm using Windows XP and gvim 7.3, included patches 1-3

Rgds,
Jeri

--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

No comments: