VCS -- return value

M

Mark W Brehob

Guest
Hello all,
I'm doing some work with vcs and I've hit what seems like a very silly
problem. When vcs exits with a compile error, the vcs program is still
returning a zero. I've never seen any other tool or complier behave that
way on a Unix box.

Does anyone have any nice suggestions for automatically figuring out if vcs
failed? I realize I could parse the output from vcs, but that is somewhat
inconvenient (read would take me a few hours of changing other stuff).

Does vcs really behave that way? Is there any way to get it to actually
produce an error code when it actually hits an error?

Thanks for any thoughts or help.

Mark
 
Hi Mark,
I hope you are referring to the "return value" as seen by the shell
after vcs detects a compile error. If so, it seems to be working fine, it is
giving me 255 as the status. I use tcsh, vcs under Solaris.
I created a syntax error and tries:

vcs ../syntax_err.v
------ VCS output -----------
*** Using loader /usr/ccs/bin/ld instead of cc ...

Parsing design file '../syntax_err.v'
Error-[SE] Syntax error
"../syntax_err.v", 5: token is 'endmodule'
endmodule // ab
^
1 error
CPU time: 0 seconds to compile

--------------

Now I see the return value:

UNIX> echo $status
255

Thanks,
Srinivasan
"Mark W Brehob" <brehob@wildwood.eecs.umich.edu> wrote in message
news:8hN2d.39$IP1.12004@news.itd.umich.edu...
Hello all,
I'm doing some work with vcs and I've hit what seems like a very silly
problem. When vcs exits with a compile error, the vcs program is still
returning a zero. I've never seen any other tool or complier behave that
way on a Unix box.

Does anyone have any nice suggestions for automatically figuring out if
vcs
failed? I realize I could parse the output from vcs, but that is somewhat
inconvenient (read would take me a few hours of changing other stuff).

Does vcs really behave that way? Is there any way to get it to actually
produce an error code when it actually hits an error?

Thanks for any thoughts or help.

Mark
 
Hi,
Thanks to Srinivasan I can now safely say it is due to the installation
here.

Thanks to all for the help!

Mark

Srinivasan Venkataramanan <svenkat@synopsys.no_spam.co.in> wrote:
Hi Mark,
I hope you are referring to the "return value" as seen by the shell
after vcs detects a compile error. If so, it seems to be working fine, it is
giving me 255 as the status. I use tcsh, vcs under Solaris.
I created a syntax error and tries:

vcs ../syntax_err.v
------ VCS output -----------
*** Using loader /usr/ccs/bin/ld instead of cc ...

Parsing design file '../syntax_err.v'
Error-[SE] Syntax error
"../syntax_err.v", 5: token is 'endmodule'
endmodule // ab
^
1 error
CPU time: 0 seconds to compile

--------------

Now I see the return value:

UNIX> echo $status
255

Thanks,
Srinivasan
"Mark W Brehob" <brehob@wildwood.eecs.umich.edu> wrote in message
news:8hN2d.39$IP1.12004@news.itd.umich.edu...
Hello all,
I'm doing some work with vcs and I've hit what seems like a very silly
problem. When vcs exits with a compile error, the vcs program is still
returning a zero. I've never seen any other tool or complier behave that
way on a Unix box.

Does anyone have any nice suggestions for automatically figuring out if
vcs
failed? I realize I could parse the output from vcs, but that is somewhat
inconvenient (read would take me a few hours of changing other stuff).

Does vcs really behave that way? Is there any way to get it to actually
produce an error code when it actually hits an error?

Thanks for any thoughts or help.

Mark
 

Welcome to EDABoard.com

Sponsor

Back
Top