Skip to content

Commit

Permalink
Updates for Cygwin portability (pr1585922)
Browse files Browse the repository at this point in the history
  • Loading branch information
steve committed Oct 30, 2006
1 parent 2302693 commit 8413784
Show file tree
Hide file tree
Showing 28 changed files with 211 additions and 149 deletions.
9 changes: 6 additions & 3 deletions Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
# 59 Temple Place - Suite 330
# Boston, MA 02111-1307, USA
#
#ident "$Id: Makefile.in,v 1.178 2006/09/23 04:57:19 steve Exp $"
#ident "$Id: Makefile.in,v 1.179 2006/10/30 22:45:36 steve Exp $"
#
#
SHELL = /bin/sh
Expand Down Expand Up @@ -84,17 +84,20 @@ check: all

clean:
for dir in $(SUBDIRS); do (cd $$dir ; $(MAKE) $@); done
for dir in vpi ivlpp tgt-verilog driver; \
for dir in vpi ivlpp tgt-verilog tgt-pal driver driver-vpi; \
do (cd $$dir ; $(MAKE) $@); done
rm -f *.o parse.cc parse.cc.output parse.h lexor.cc
rm -f ivl.exp iverilog-vpi.pdf iverilog-vpi.ps parse.output
rm -f syn-rules.output dosify.exe
rm -f lexor_keyword.cc libivl.a libvpi.a iverilog-vpi syn-rules.cc*
rm -rf dep ivl@EXEEXT@

distclean: clean
for dir in $(SUBDIRS); do (cd $$dir ; $(MAKE) $@); done
for dir in vpi ivlpp tgt-verilog driver; \
for dir in vpi ivlpp tgt-verilog tgt-pal driver driver-vpi; \
do (cd $$dir ; $(MAKE) $@); done
rm -f Makefile config.status config.log config.cache config.h
rm -f _pli_types.h

TT = t-dll.o t-dll-api.o t-dll-expr.o t-dll-proc.o
FF = cprop.o nodangle.o synth.o synth2.o syn-rules.o
Expand Down
4 changes: 2 additions & 2 deletions driver/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
# 59 Temple Place - Suite 330
# Boston, MA 02111-1307, USA
#
#ident "$Id: Makefile.in,v 1.24 2004/10/13 22:01:34 steve Exp $"
#ident "$Id: Makefile.in,v 1.25 2006/10/30 22:45:37 steve Exp $"
#
#
SHELL = /bin/sh
Expand Down Expand Up @@ -50,7 +50,7 @@ all: iverilog@EXEEXT@
clean:
rm -f *.o lexor.c parse.c parse.h parse.output
rm -f cflexor.c cfparse.c cfparse.h cfparse.output
rm -f iverilog@EXEEXT@
rm -f iverilog@EXEEXT@ iverilog.pdf iverilog.ps

distclean: clean
rm -f Makefile
Expand Down
7 changes: 5 additions & 2 deletions examples/hello_vpi.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*/
#ifdef HAVE_CVS_IDENT
#ident "$Id: hello_vpi.c,v 1.3 2002/08/12 01:35:01 steve Exp $"
#ident "$Id: hello_vpi.c,v 1.4 2006/10/30 22:46:25 steve Exp $"
#endif

/*
Expand All @@ -33,7 +33,7 @@

# include <vpi_user.h>

static int my_hello_calltf(char *xx)
static PIN_INT32 my_hello_calltf(char *xx)
{
vpi_printf("Hello World, from VPI.\n");
return 0;
Expand Down Expand Up @@ -62,6 +62,9 @@ void (*vlog_startup_routines[])() = {
};
/*
* $Log: hello_vpi.c,v $
* Revision 1.4 2006/10/30 22:46:25 steve
* Updates for Cygwin portability (pr1585922)
*
* Revision 1.3 2002/08/12 01:35:01 steve
* conditional ident string using autoconfig.
*
Expand Down
5 changes: 5 additions & 0 deletions ivl.def
Original file line number Diff line number Diff line change
Expand Up @@ -153,11 +153,16 @@ ivl_signal_lsb
ivl_signal_msb
ivl_signal_name
ivl_signal_nex
ivl_signal_npath
ivl_signal_path
ivl_signal_port
ivl_signal_signed
ivl_signal_type
ivl_signal_width

ivl_path_delay
ivl_path_source

ivl_process_attr_cnt
ivl_process_attr_val
ivl_process_scope
Expand Down
18 changes: 9 additions & 9 deletions ivlpp/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
# 59 Temple Place - Suite 330
# Boston, MA 02111-1307, USA
#
#ident "$Id: Makefile.in,v 1.17 2004/10/04 01:10:56 steve Exp $"
#ident "$Id: Makefile.in,v 1.18 2006/10/30 22:45:37 steve Exp $"
#
#
SHELL = /bin/sh
Expand All @@ -44,35 +44,35 @@ CPPFLAGS = @ident_support@ -I. -I.. -I$(srcdir)/.. -I$(srcdir) @CPPFLAGS@ @DEFS@
CFLAGS = -Wall @CFLAGS@
LDFLAGS = @LDFLAGS@

all: ivlpp
all: ivlpp@EXEEXT@

clean:
rm -f *.o lexor.c parse.c parse.h parse.output ivlpp
rm -f *.o lexor.c parse.c parse.h parse.output ivlpp@EXEEXT@

distclean: clean
rm -f Makefile

O = main.o lexor.o parse.o

ivlpp: $O
$(CC) $(LDFLAGS) $O -o ivlpp @EXTRALIBS@
ivlpp@EXEEXT@: $O
$(CC) $(LDFLAGS) $O -o ivlpp@EXEEXT@ @EXTRALIBS@

lexor.c: lexor.lex
flex -s -olexor.c $(srcdir)/lexor.lex

parse.h parse.c: parse.y
bison --verbose -t -d -o parse.c $(srcdir)/parse.y

install: all installdirs $(libdir)/ivl/ivlpp
install: all installdirs $(libdir)/ivl/ivlpp@EXEEXT@

$(libdir)/ivl/ivlpp: ivlpp
$(INSTALL_PROGRAM) ./ivlpp $(libdir)/ivl/ivlpp
$(libdir)/ivl/ivlpp@EXEEXT@: ivlpp@EXEEXT@
$(INSTALL_PROGRAM) ./ivlpp@EXEEXT@ $(libdir)/ivl/ivlpp@EXEEXT@

installdirs: ../mkinstalldirs
$(srcdir)/../mkinstalldirs $(libdir)/ivl

uninstall:
rm -f $(libdir)/ivl/ivlpp
rm -f $(libdir)/ivl/ivlpp@EXEEXT@

lexor.o: lexor.c parse.h globals.h
main.o: main.c globals.h
Expand Down
4 changes: 2 additions & 2 deletions libveriuser/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
# 59 Temple Place - Suite 330
# Boston, MA 02111-1307, USA
#
#ident "$Id: Makefile.in,v 1.34 2004/10/04 01:10:07 steve Exp $"
#ident "$Id: Makefile.in,v 1.35 2006/10/30 22:45:37 steve Exp $"
#
#
SHELL = /bin/sh
Expand Down Expand Up @@ -92,7 +92,7 @@ clean:
rm -rf *.o dep libveriuser.a libveriuser.o bin32

distclean: clean
rm -f Makefile config.status config.log config.cache
rm -f Makefile config.status config.log config.cache config.h

install:: all installdirs $(libdir64)/libveriuser.a $(INSTALL32)

Expand Down
7 changes: 5 additions & 2 deletions libveriuser/a_next.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*/
#ifdef HAVE_CVS_IDENT
#ident "$Id: a_next.c,v 1.3 2003/06/17 16:55:07 steve Exp $"
#ident "$Id: a_next.c,v 1.4 2006/10/30 22:45:37 steve Exp $"
#endif

#include <stdio.h>
Expand All @@ -34,7 +34,7 @@ handle acc_next(PLI_INT32 *type, handle scope, handle prev)

/* trace */
if (pli_trace) {
int *ip;
PLI_INT32 *ip;
fprintf(pli_trace, "acc_next(%p <", type);
for (ip = type; *ip; ip++) {
fprintf(pli_trace, "%s%d", ip != type ? "," : "", *ip);
Expand Down Expand Up @@ -94,6 +94,9 @@ handle acc_next_scope(handle scope, handle prev)

/*
* $Log: a_next.c,v $
* Revision 1.4 2006/10/30 22:45:37 steve
* Updates for Cygwin portability (pr1585922)
*
* Revision 1.3 2003/06/17 16:55:07 steve
* 1) setlinebuf() for vpi_trace
* 2) Addes error checks for trace file opens
Expand Down
19 changes: 11 additions & 8 deletions libveriuser/veriusertfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*/
#ifdef HAVE_CVS_IDENT
#ident "$Id: veriusertfs.c,v 1.15 2004/09/10 23:13:05 steve Exp $"
#ident "$Id: veriusertfs.c,v 1.16 2006/10/30 22:45:37 steve Exp $"
#endif

/*
Expand All @@ -44,9 +44,9 @@ typedef struct t_pli_data {
int paramvc; /* parameter number for misctf */
} s_pli_data, *p_pli_data;

static int compiletf(char *);
static int calltf(char *);
static int callback(p_cb_data);
static PLI_INT32 compiletf(char *);
static PLI_INT32 calltf(char *);
static PLI_INT32 callback(p_cb_data);

/*
* Register veriusertfs routines/wrappers. Iterate over the tfcell
Expand Down Expand Up @@ -139,7 +139,7 @@ void veriusertfs_register_table(p_tfcell vtable)
* This function calls the veriusertfs checktf and sets up all the
* callbacks misctf requires.
*/
static int compiletf(char *data)
static PLI_INT32 compiletf(char *data)
{
p_pli_data pli;
p_tfcell tf;
Expand Down Expand Up @@ -221,7 +221,7 @@ static int compiletf(char *data)
/*
* This function is the wrapper for the veriusertfs calltf routine.
*/
static int calltf(char *data)
static PLI_INT32 calltf(char *data)
{
int rc = 0;
p_pli_data pli;
Expand Down Expand Up @@ -249,13 +249,13 @@ static int calltf(char *data)
*/
extern int async_misctf_enable;

static int callback(p_cb_data data)
static PLI_INT32 callback(p_cb_data data)
{
p_pli_data pli;
p_tfcell tf;
int reason;
int paramvc = 0;
int rc;
PLI_INT32 rc;

/* not enabled */
if (data->reason == cbValueChange && !async_misctf_enable)
Expand Down Expand Up @@ -389,6 +389,9 @@ PLI_INT32 tf_setrealdelay(double dly)
}
/*
* $Log: veriusertfs.c,v $
* Revision 1.16 2006/10/30 22:45:37 steve
* Updates for Cygwin portability (pr1585922)
*
* Revision 1.15 2004/09/10 23:13:05 steve
* Compile cleanup of C code.
*
Expand Down
4 changes: 2 additions & 2 deletions tgt-stub/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
# 59 Temple Place - Suite 330
# Boston, MA 02111-1307, USA
#
#ident "$Id: Makefile.in,v 1.16 2006/05/01 18:48:24 steve Exp $"
#ident "$Id: Makefile.in,v 1.17 2006/10/30 22:45:37 steve Exp $"
#
#
SHELL = /bin/sh
Expand Down Expand Up @@ -70,7 +70,7 @@ clean:
rm -rf *.o dep stub.tgt

distclean: clean
rm -f Makefile
rm -f Makefile config.status config.log

install: all installdirs $(libdir)/ivl/stub.tgt \
$(libdir)/ivl/stub.conf $(libdir)/ivl/stub-s.conf
Expand Down
6 changes: 3 additions & 3 deletions tgt-vvp/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
# 59 Temple Place - Suite 330
# Boston, MA 02111-1307, USA
#
#ident "$Id: Makefile.in,v 1.24 2005/09/14 02:53:15 steve Exp $"
#ident "$Id: Makefile.in,v 1.25 2006/10/30 22:45:37 steve Exp $"
#
#
SHELL = /bin/sh
Expand Down Expand Up @@ -77,10 +77,10 @@ Makefile: Makefile.in config.status
./config.status

clean:
rm -rf *.o dep vvp.tgt
rm -rf *.o dep vvp.tgt vvp.conf vvp-s.conf

distclean: clean
rm -f Makefile config.status config.log config.cache
rm -f Makefile config.status config.log config.cache vvp_config.h

check: all

Expand Down
4 changes: 2 additions & 2 deletions vpi/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
# 59 Temple Place - Suite 330
# Boston, MA 02111-1307, USA
#
#ident "$Id: Makefile.in,v 1.59 2006/08/03 05:06:04 steve Exp $"
#ident "$Id: Makefile.in,v 1.60 2006/10/30 22:45:37 steve Exp $"
#
#
SHELL = /bin/sh
Expand Down Expand Up @@ -111,7 +111,7 @@ clean:
rm -rf *.o sys_readmem_lex.c dep system.vpi bin32

distclean: clean
rm -f Makefile
rm -f Makefile config.status config.log vpi_config.h

install: all installdirs $(vpidir)/system.vpi $(libdir)/ivl/system.sft $(INSTALL32)

Expand Down
21 changes: 12 additions & 9 deletions vpi/sys_convert.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*/
#ifdef HAVE_CVS_IDENT
#ident "$Id: sys_convert.c,v 1.5 2004/02/15 18:03:30 steve Exp $"
#ident "$Id: sys_convert.c,v 1.6 2006/10/30 22:45:37 steve Exp $"
#endif

# include "vpi_config.h"
Expand Down Expand Up @@ -86,13 +86,13 @@ static void double2bits(double real, PLI_UINT32 bits[2])
#endif
}

static int sizetf_32 (char*x) { return 32; }
static int sizetf_64 (char*x) { return 64; }
static PLI_INT32 sizetf_32 (char*x) { return 32; }
static PLI_INT32 sizetf_64 (char*x) { return 64; }

static int sys_convert_compiletf(char *name)
static PLI_INT32 sys_convert_compiletf(char *name)
{
vpiHandle call_hand, argv, arg;
int rtn = 0;
PLI_INT32 rtn = 0;

call_hand = vpi_handle(vpiSysTfCall, 0);
argv = vpi_iterate(vpiArgument, call_hand);
Expand All @@ -116,7 +116,7 @@ static int sys_convert_compiletf(char *name)
return rtn;
}

static int sys_bitstoreal_calltf(char *user)
static PLI_INT32 sys_bitstoreal_calltf(char *user)
{
vpiHandle sys, argv, arg;
s_vpi_value value;
Expand Down Expand Up @@ -147,7 +147,7 @@ static int sys_bitstoreal_calltf(char *user)
return 0;
}

static int sys_itor_calltf(char *user)
static PLI_INT32 sys_itor_calltf(char *user)
{
vpiHandle sys, argv, arg;
s_vpi_value value;
Expand All @@ -174,7 +174,7 @@ static int sys_itor_calltf(char *user)
return 0;
}

static int sys_realtobits_calltf(char *user)
static PLI_INT32 sys_realtobits_calltf(char *user)
{
vpiHandle sys, argv, arg;
s_vpi_value value;
Expand Down Expand Up @@ -211,7 +211,7 @@ static int sys_realtobits_calltf(char *user)
return 0;
}

static int sys_rtoi_calltf(char *user)
static PLI_INT32 sys_rtoi_calltf(char *user)
{
vpiHandle sys, argv, arg;
s_vpi_value value;
Expand Down Expand Up @@ -281,6 +281,9 @@ void sys_convert_register()

/*
* $Log: sys_convert.c,v $
* Revision 1.6 2006/10/30 22:45:37 steve
* Updates for Cygwin portability (pr1585922)
*
* Revision 1.5 2004/02/15 18:03:30 steve
* Cleanup of warnings.
*
Expand Down
Loading

0 comments on commit 8413784

Please sign in to comment.