diff --git a/iverilog.conf b/iverilog.conf index 372c07a6f..c90ab9b48 100644 --- a/iverilog.conf +++ b/iverilog.conf @@ -66,10 +66,10 @@ # These rules support synthesized and non-synthesized variants. [-tvvp -S] -%B/ivl %W %[s-s%s] %[N-N%N] %[T-T%T] -tdll -fDLL=%B/vvp.tgt -Fsynth -Fsyn-rules -Fcprop -Fnodangle %f %m -o%o -- - +%B/ivl %W %[s-s%s] %[N-N%N] %[T-T%T] -tdll -fDLL=%B/vvp.tgt -fVVP_EXECUTABLE=%B/../../bin/vvp -Fsynth -Fsyn-rules -Fcprop -Fnodangle %f %m -o%o -- - [-tvvp] -%B/ivl %W %[s-s%s] %[N-N%N] %[T-T%T] -tdll -fDLL=%B/vvp.tgt -Fcprop -Fnodangle %f %m -o%o -- - +%B/ivl %W %[s-s%s] %[N-N%N] %[T-T%T] -tdll -fDLL=%B/vvp.tgt -fVVP_EXECUTABLE=%B/../../bin/vvp -Fcprop -Fnodangle %f %m -o%o -- - # -- # The vvm target uses the string to take the preprocessed code from diff --git a/tgt-vvp/vvp.c b/tgt-vvp/vvp.c index 1205240b1..eda2a0e4f 100644 --- a/tgt-vvp/vvp.c +++ b/tgt-vvp/vvp.c @@ -17,7 +17,7 @@ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA */ #if !defined(WINNT) && !defined(macintosh) -#ident "$Id: vvp.c,v 1.4 2001/03/27 03:31:07 steve Exp $" +#ident "$Id: vvp.c,v 1.5 2001/04/28 20:06:07 steve Exp $" #endif /* @@ -29,7 +29,14 @@ FILE*vvp_out = 0; -static void draw_module_declarations(ivl_design_t des) +inline static void draw_execute_header(ivl_design_t des) +{ + const char*cp = ivl_design_flag(des, "VVP_EXECUTABLE"); + if (cp) + fprintf(vvp_out, "#! %s\n", cp); +} + +inline static void draw_module_declarations(ivl_design_t des) { const char*cp = ivl_design_flag(des, "VPI_MODULE_LIST"); @@ -61,6 +68,8 @@ int target_design(ivl_design_t des) return -1; } + draw_execute_header(des); + draw_module_declarations(des); root = ivl_design_root(des);