TCLSPICE IMPORT + libtool + measure2 command
This commit is contained in:
parent
cacdda8fde
commit
fa549df82a
23
ChangeLog
23
ChangeLog
|
|
@ -1,4 +1,25 @@
|
|||
008-08-25 Paolo Nenzi
|
||||
2008-08-27 Paolo Nenzi
|
||||
* --- TCLSPICE initial integration (Lionel Sainte Cluque) ---
|
||||
* Makefile.am: Makefiles changed for libtool. We use still .a files but we let
|
||||
libtool to created them in a portable manner. This slows compilation a little
|
||||
bit but improves portability of ngspice/tclspice.
|
||||
* src/tclspice.c, src/tclspice.map, pkgIndex.tcl.in, src/include/tclspice.h:
|
||||
tclspice main and include file. (Readded files).
|
||||
* src/tests/tcl/, src/tests/tcl-testbench1/, src/tests/tcl-testbench2/,
|
||||
src/tests/tcl-testbench3/, src/tests/tcl-testbench4/: testbenches for
|
||||
the tclspice simulator. (New dirs).
|
||||
* src/frontend/plotit.c: added blt_plot for blt output device if TCL defined.
|
||||
* src/frontend/com_plot.c, src/frontend/com_plot.h: added com_bltplot.
|
||||
* src/frontend/commands.c: redefined plot command to combltplot if TCL is enabled.
|
||||
* src/frontend/display.c: defined Tk display device.
|
||||
* src/frontend/outitf.c: added blt support.
|
||||
* src/frontend/terminal.c: if TCL is defined, interactive terminal stubs are copiled in.
|
||||
* src/include/ngspice.h: added definitions for TCL functions.
|
||||
* src/misc/alloc.c: Using TCL allocation functions when tclspice is enabled.
|
||||
* src/frontend/com_measure2.c,.h: new measure command (to link and test)
|
||||
* src/main.c: some static function moved for TCL interface (nutmeginfo, etc.)
|
||||
|
||||
2008-08-25 Paolo Nenzi
|
||||
* configure.in, src/spicelib/analysis/noisean.c: removed the compilation switch
|
||||
--enable-intnoise. Noise analyses now generate two plot, the first one for
|
||||
spectrum and the second one the integrated noise.
|
||||
|
|
|
|||
|
|
@ -22,4 +22,3 @@ mrproper: maintainer-clean
|
|||
rm -f `find . -type f -name "*.orig" -print`
|
||||
rm -f `find . -type f -name "*.rej" -print`
|
||||
|
||||
|
||||
|
|
|
|||
191
configure.in
191
configure.in
|
|
@ -173,6 +173,11 @@ dnl --with-editline: Includes BSD Editline support into CLI. Default is "no".
|
|||
AC_ARG_WITH(editline,
|
||||
AS_HELP_STRING([--with-editline[=yes/no]],[Enable BSD editline support for CLI. Default=no.]))
|
||||
|
||||
dnl --with-tcl: define TCL_MODULE in the code. This is for tcl support
|
||||
AC_ARG_WITH(tcl,
|
||||
[ --with-tcl[=tcldir] Compiles the tcl module instead, experimental, see README.Tcl])
|
||||
|
||||
|
||||
|
||||
dnl readline and editline cannot both be enabled
|
||||
if test "$with_editline" = "yes"; then
|
||||
|
|
@ -280,6 +285,133 @@ case $with_windows in
|
|||
CFLAGS="$CFLAGS -mwindows";;
|
||||
* )
|
||||
|
||||
##########################################################################
|
||||
#
|
||||
# tcl libraries test
|
||||
#
|
||||
##########################################################################
|
||||
|
||||
dnl
|
||||
dnl The tclSpice options
|
||||
dnl
|
||||
AM_CONDITIONAL(TCL_MODULE, false)
|
||||
if test "x$with_tcl" != "x" -a "$with_tcl" != "no" ; then
|
||||
AM_CONDITIONAL(TCL_MODULE, true)
|
||||
AC_DEFINE(TCL_MODULE,1,[Tcl Module])
|
||||
with_x=no
|
||||
enable_shared=no
|
||||
|
||||
AC_MSG_CHECKING([for tclConfig.sh])
|
||||
tcl_config_sh=""
|
||||
if test "x$with_tcl" != "xyes" ; then
|
||||
for dir in \
|
||||
$with_tcl
|
||||
do
|
||||
if test -r "$dir/tclConfig.sh" ; then
|
||||
tcl_config_sh="$dir/tclConfig.sh"
|
||||
break
|
||||
elif test -r "$dir/lib/tclConfig.sh" ; then
|
||||
tcl_config_sh="$dir/lib/tclConfig.sh"
|
||||
break
|
||||
elif test -r "$dir/unix/tclConfig.sh" ; then
|
||||
tcl_config_sh="$dir/unix/tclConfig.sh"
|
||||
break
|
||||
fi
|
||||
done
|
||||
else
|
||||
for dir in \
|
||||
$prefix \
|
||||
$exec_prefix
|
||||
do
|
||||
if test -r "$dir/tclConfig.sh" ; then
|
||||
tcl_config_sh="$dir/tclConfig.sh"
|
||||
break
|
||||
elif test -r "$dir/lib/tclConfig.sh" ; then
|
||||
tcl_config_sh="$dir/lib/tclConfig.sh"
|
||||
break
|
||||
elif test -r "$dir/unix/tclConfig.sh" ; then
|
||||
tcl_config_sh="$dir/unix/tclConfig.sh"
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
|
||||
if test "x$tcl_config_sh" = "x" ; then
|
||||
for dir in \
|
||||
`ls -dr /usr/local/tcl/tcl[[7-9]].[[0-9]]* 2>/dev/null` \
|
||||
/usr/local/tcl \
|
||||
/usr/local \
|
||||
/usr
|
||||
do
|
||||
if test -r "$dir/tclConfig.sh" ; then
|
||||
tcl_config_sh="$dir/tclConfig.sh"
|
||||
break
|
||||
elif test -r "$dir/lib/tclConfig.sh" ; then
|
||||
tcl_config_sh="$dir/lib/tclConfig.sh"
|
||||
break
|
||||
fi
|
||||
done
|
||||
fi
|
||||
fi
|
||||
|
||||
AC_MSG_RESULT([${tcl_config_sh}])
|
||||
|
||||
|
||||
|
||||
if test "x$tcl_config_sh" = "x" ; then
|
||||
echo "can't find Tcl configuration script \"tclConfig.sh\""
|
||||
find /usr/lib/ -name 'tclConfig.sh' -exec echo "Should you add --with-tcl={} to ./configure arguments?" \;
|
||||
exit 1
|
||||
fi
|
||||
|
||||
. $tcl_config_sh
|
||||
|
||||
CFLAGS="$CFLAGS $TCL_INCLUDE_SPEC"
|
||||
CPPFLAGS="$CPPFLAGS $TCL_INCLUDE_SPEC"
|
||||
|
||||
AC_CHECK_HEADERS(tcl.h blt.h,,AC_MSG_ERROR(Couldn't find Tcl/BLT headers),)
|
||||
|
||||
if test ! -x "$TCL_EXEC_PREFIX/bin/tclsh$TCL_VERSION" ; then
|
||||
AC_MSG_ERROR(Couldn't find $TCL_EXEC_PREFIX/bin/tclsh$TCL_VERSION)
|
||||
fi
|
||||
|
||||
AC_MSG_CHECKING(for TCL module BLT)
|
||||
rm -f conftest.tcl
|
||||
cat > conftest.tcl << EOF
|
||||
package require BLT;
|
||||
exit;
|
||||
EOF
|
||||
if ($TCL_EXEC_PREFIX/bin/tclsh$TCL_VERSION conftest.tcl; exit) 2>/dev/null
|
||||
then
|
||||
AC_MSG_RESULT(Found)
|
||||
else
|
||||
AC_MSG_ERROR(Couldn't find BLT)
|
||||
fi
|
||||
rm -f conftest.tcl
|
||||
|
||||
AC_CHECK_LIB(pthread,pthread_create)
|
||||
for TCL_PACKAGE_PATH_ELEMENT in $TCL_PACKAGE_PATH ; do
|
||||
if test -a $TCL_PACKAGE_PATH_ELEMENT ; then
|
||||
libdir=$TCL_PACKAGE_PATH_ELEMENT
|
||||
AC_SUBST(libdir)
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
else
|
||||
TCL_PACKAGE_PATH=""
|
||||
TCL_LIB_SPEC=""
|
||||
fi
|
||||
|
||||
AC_SUBST(TCL_PACKAGE_PATH)
|
||||
AC_SUBST(TCL_LIB_SPEC)
|
||||
##################################################################
|
||||
#
|
||||
#
|
||||
#End of tcl libraries test
|
||||
#
|
||||
#################################################################
|
||||
|
||||
dnl Check for /proc (virtual process information file system)
|
||||
AC_CHECK_HEADERS( /proc/meminfo)
|
||||
|
||||
|
|
@ -445,13 +577,14 @@ dnl Check for the random function:
|
|||
AC_CHECK_FUNCS(random,,AC_CHECK_LIB(iberty,random,AC_DEFINE([HAVE_RANDOM],1,[Have random in libiberty]) LIBS="$LIBS -liberty"))
|
||||
|
||||
dnl If user enables garbage collection, look for garbage collector
|
||||
if test "$enable_gc" = "yes"; then
|
||||
AC_MSG_RESULT(Checking for the presence of the Garbage Collector:)
|
||||
AC_CHECK_LIB(gc,GC_malloc,
|
||||
AC_DEFINE(HAVE_LIBGC,[],[Define if we want garbage collection enabled])
|
||||
LIBS="$LIBS -lgc")
|
||||
if test "$TCL_PACKAGE_PATH" = ""; then
|
||||
if test "$enable_gc" = "yes"; then
|
||||
AC_MSG_RESULT(Checking for the presence of the Garbage Collector:)
|
||||
AC_CHECK_LIB(gc,GC_malloc,
|
||||
AC_DEFINE(HAVE_LIBGC,[],[Define if we want garbage collection enabled])
|
||||
LIBS="$LIBS -lgc")
|
||||
fi
|
||||
fi
|
||||
|
||||
dnl check, if we have sigsetjmp and siglongjmp.
|
||||
dnl A trivial AC_CHECK_FUNCS(sigsetjmp) won't do because sigsetjmp() might be a
|
||||
dnl macro declared in <setjmp.h>. (joze)
|
||||
|
|
@ -497,7 +630,7 @@ AC_DEFINE_UNQUOTED(NGSPICEBUILDDATE,"`date`",[Define the build date])
|
|||
if test "$with_windows" = "yes"; then
|
||||
AC_MSG_RESULT(WINDOWS code enabled)
|
||||
WINMAIN="winmain.o"
|
||||
WINDISPLIB="frontend/wdisp/libwindisp.a"
|
||||
WINDISPLIB="frontend/wdisp/libwindisp.la"
|
||||
AC_CHECK_FUNCS([memmove])
|
||||
else
|
||||
WINMAIN=""
|
||||
|
|
@ -613,12 +746,12 @@ dnl Define variables for YACC and LEX
|
|||
AC_DEFINE([IPC_UNIX_SOCKETS], [1], [Client-Server via socket.])
|
||||
DLLIBS="-ldl";;
|
||||
esac
|
||||
XSPICELIB1="$XSPICEDIR/cm/libcmxsp.a \
|
||||
$XSPICEDIR/mif/libmifxsp.a"
|
||||
XSPICELIB2="$XSPICEDIR/evt/libevtxsp.a \
|
||||
$XSPICEDIR/enh/libenhxsp.a \
|
||||
$XSPICEDIR/ipc/libipcxsp.a \
|
||||
$XSPICEDIR/idn/libidnxsp.a \
|
||||
XSPICELIB1="$XSPICEDIR/cm/libcmxsp.la \
|
||||
$XSPICEDIR/mif/libmifxsp.la"
|
||||
XSPICELIB2="$XSPICEDIR/evt/libevtxsp.la \
|
||||
$XSPICEDIR/enh/libenhxsp.la \
|
||||
$XSPICEDIR/ipc/libipcxsp.la \
|
||||
$XSPICEDIR/idn/libidnxsp.la \
|
||||
$DLLIBS"
|
||||
XSPICEINIT=""
|
||||
XSPICETESTS=""
|
||||
|
|
@ -644,16 +777,16 @@ if test "$enable_cider" = "yes"; then
|
|||
|
||||
CIDERDIR="ciderlib"
|
||||
|
||||
CIDERSIM=" $CIDERDIR/twod/libcidertwod.a \
|
||||
$CIDERDIR/oned/libcideroned.a \
|
||||
$CIDERDIR/input/libciderinput.a \
|
||||
$CIDERDIR/support/libcidersuprt.a"
|
||||
CIDERSIM=" $CIDERDIR/twod/libcidertwod.la \
|
||||
$CIDERDIR/oned/libcideroned.la \
|
||||
$CIDERDIR/input/libciderinput.la \
|
||||
$CIDERDIR/support/libcidersuprt.la"
|
||||
|
||||
NUMDEV=" spicelib/devices/nbjt/libnbjt.a \
|
||||
spicelib/devices/nbjt2/libnbjt2.a \
|
||||
spicelib/devices/numd/libnumd.a \
|
||||
spicelib/devices/numd2/libnumd2.a \
|
||||
spicelib/devices/numos/libnumos.a"
|
||||
NUMDEV=" spicelib/devices/nbjt/libnbjt.la \
|
||||
spicelib/devices/nbjt2/libnbjt2.la \
|
||||
spicelib/devices/numd/libnumd.la \
|
||||
spicelib/devices/numd2/libnumd2.la \
|
||||
spicelib/devices/numos/libnumos.la"
|
||||
NUMDEVDIR=" nbjt \
|
||||
nbjt2 \
|
||||
numd \
|
||||
|
|
@ -694,11 +827,11 @@ if test "$enable_adms" = "yes"; then
|
|||
adms/ekv \
|
||||
adms/psp102 "
|
||||
|
||||
VLADEV=" spicelib/devices/adms/hicum0/libhicum0.a \
|
||||
spicelib/devices/adms/hicum2/libhicum2.a \
|
||||
spicelib/devices/adms/mextram/libmextram.a \
|
||||
spicelib/devices/adms/ekv/libekv.a \
|
||||
spicelib/devices/adms/psp102/libpsp102.a "
|
||||
VLADEV=" spicelib/devices/adms/hicum0/libhicum0.la \
|
||||
spicelib/devices/adms/hicum2/libhicum2.la \
|
||||
spicelib/devices/adms/mextram/libmextram.la \
|
||||
spicelib/devices/adms/ekv/libekv.la \
|
||||
spicelib/devices/adms/psp102/libpsp102.la "
|
||||
|
||||
fi
|
||||
AC_SUBST(ADMSXML)
|
||||
|
|
@ -711,7 +844,7 @@ if test "$enable_ndev" = "yes"; then
|
|||
AC_DEFINE(NDEV,[],[The NDEV interface])
|
||||
NDEV=""
|
||||
NDEV_DIR=" ndev "
|
||||
NDEV_LIB=" spicelib/devices/ndev/libndev.a "
|
||||
NDEV_LIB=" spicelib/devices/ndev/libndev.la "
|
||||
else
|
||||
NDEV=""
|
||||
NDEV_DIR=""
|
||||
|
|
@ -740,6 +873,7 @@ dnl ---- Hope to see in the future readline replacement. ----
|
|||
if test "$with_readline" != "yes"; then
|
||||
AC_MSG_RESULT(GNU readline disabled.)
|
||||
else
|
||||
if test "x$with_tcl" == "x" -o "$with_tcl" == "no" ; then
|
||||
AC_MSG_RESULT(Checking for readline:)
|
||||
AC_CHECK_HEADERS([readline/readline.h readline/history.h],
|
||||
[AC_DEFINE(HAVE_GNUREADLINE,[],[Define if we have GNU readline])],
|
||||
|
|
@ -750,6 +884,7 @@ else
|
|||
AC_CHECK_LIB(readline, readline,
|
||||
[LIBS="$LIBS -lreadline"],
|
||||
[AC_MSG_ERROR(Couldn't find readline libraries.)])
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
|
|
|
|||
257
src/Makefile.am
257
src/Makefile.am
|
|
@ -4,6 +4,7 @@
|
|||
SUBDIRS = misc maths frontend spicelib include @XSPICEDIR@ @CIDERDIR@
|
||||
DIST_SUBDIRS = misc maths frontend spicelib include xspice ciderlib
|
||||
|
||||
if !TCL_MODULE
|
||||
bin_PROGRAMS = ngspice ngnutmeg ngmakeidx
|
||||
|
||||
if !WINDOWS
|
||||
|
|
@ -13,8 +14,10 @@ endif
|
|||
if !NO_HELP
|
||||
bin_PROGRAMS += nghelp
|
||||
endif
|
||||
endif
|
||||
|
||||
EXTRA_DIST = ngspice.txt ngspice.idx setplot spectrum \
|
||||
devload devaxis ciderinit winmain.c
|
||||
devload devaxis ciderinit winmain.c
|
||||
|
||||
helpdatadir = $(pkgdatadir)/helpdir
|
||||
|
||||
|
|
@ -26,57 +29,57 @@ initdata_DATA = spinit setplot spectrum @CIDERSCRIPTS@
|
|||
|
||||
|
||||
DYNAMIC_DEVICELIBS = \
|
||||
spicelib/devices/asrc/libasrc.a \
|
||||
spicelib/devices/bjt/libbjt.a \
|
||||
spicelib/devices/bjt2/libbjt2.a \
|
||||
spicelib/devices/bsim1/libbsim1.a \
|
||||
spicelib/devices/bsim2/libbsim2.a \
|
||||
spicelib/devices/bsim3/libbsim3.a \
|
||||
spicelib/devices/bsim3v0/libbsim3v0.a \
|
||||
spicelib/devices/bsim3v1/libbsim3v1.a \
|
||||
spicelib/devices/bsim3v1s/libbsim3v1s.a \
|
||||
spicelib/devices/bsim3v1a/libbsim3v1a.a \
|
||||
spicelib/devices/bsim3v32/libbsim3v32.a \
|
||||
spicelib/devices/bsim4/libbsim4.a \
|
||||
spicelib/devices/bsim4v2/libbsim4v2.a \
|
||||
spicelib/devices/bsim4v3/libbsim4v3.a \
|
||||
spicelib/devices/bsim4v4/libbsim4v4.a \
|
||||
spicelib/devices/bsim4v5/libbsim4v5.a \
|
||||
spicelib/devices/cap/libcap.a \
|
||||
spicelib/devices/bsim3soi/libbsim3soi.a \
|
||||
spicelib/devices/bsim3soi_pd/libbsim3soipd.a \
|
||||
spicelib/devices/bsim3soi_fd/libbsim3soifd.a \
|
||||
spicelib/devices/bsim3soi_dd/libbsim3soidd.a \
|
||||
spicelib/devices/cccs/libcccs.a \
|
||||
spicelib/devices/ccvs/libccvs.a \
|
||||
spicelib/devices/cpl/libcpl.a \
|
||||
spicelib/devices/csw/libcsw.a \
|
||||
spicelib/devices/dio/libdio.a \
|
||||
spicelib/devices/ind/libind.a \
|
||||
spicelib/devices/isrc/libisrc.a \
|
||||
spicelib/devices/hfet1/libhfet.a \
|
||||
spicelib/devices/hfet2/libhfet2.a \
|
||||
spicelib/devices/hisim/libhisim.a \
|
||||
spicelib/devices/jfet/libjfet.a \
|
||||
spicelib/devices/jfet2/libjfet2.a \
|
||||
spicelib/devices/ltra/libltra.a \
|
||||
spicelib/devices/mes/libmes.a \
|
||||
spicelib/devices/mesa/libmesa.a \
|
||||
spicelib/devices/mos1/libmos1.a \
|
||||
spicelib/devices/mos2/libmos2.a \
|
||||
spicelib/devices/mos3/libmos3.a \
|
||||
spicelib/devices/mos6/libmos6.a \
|
||||
spicelib/devices/mos9/libmos9.a \
|
||||
spicelib/devices/res/libres.a \
|
||||
spicelib/devices/soi3/libsoi3.a \
|
||||
spicelib/devices/sw/libsw.a \
|
||||
spicelib/devices/txl/libtxl.a \
|
||||
spicelib/devices/tra/libtra.a \
|
||||
spicelib/devices/urc/liburc.a \
|
||||
spicelib/devices/vbic/libvbic.a \
|
||||
spicelib/devices/vccs/libvccs.a \
|
||||
spicelib/devices/vcvs/libvcvs.a \
|
||||
spicelib/devices/vsrc/libvsrc.a \
|
||||
spicelib/devices/asrc/libasrc.la \
|
||||
spicelib/devices/bjt/libbjt.la \
|
||||
spicelib/devices/bjt2/libbjt2.la \
|
||||
spicelib/devices/bsim1/libbsim1.la \
|
||||
spicelib/devices/bsim2/libbsim2.la \
|
||||
spicelib/devices/bsim3/libbsim3.la \
|
||||
spicelib/devices/bsim3v0/libbsim3v0.la \
|
||||
spicelib/devices/bsim3v1/libbsim3v1.la \
|
||||
spicelib/devices/bsim3v1s/libbsim3v1s.la \
|
||||
spicelib/devices/bsim3v1a/libbsim3v1a.la \
|
||||
spicelib/devices/bsim3v32/libbsim3v32.la \
|
||||
spicelib/devices/bsim4/libbsim4.la \
|
||||
spicelib/devices/bsim4v2/libbsim4v2.la \
|
||||
spicelib/devices/bsim4v3/libbsim4v3.la \
|
||||
spicelib/devices/bsim4v4/libbsim4v4.la \
|
||||
spicelib/devices/bsim4v5/libbsim4v5.la \
|
||||
spicelib/devices/cap/libcap.la \
|
||||
spicelib/devices/bsim3soi/libbsim3soi.la \
|
||||
spicelib/devices/bsim3soi_pd/libbsim3soipd.la \
|
||||
spicelib/devices/bsim3soi_fd/libbsim3soifd.la \
|
||||
spicelib/devices/bsim3soi_dd/libbsim3soidd.la \
|
||||
spicelib/devices/cccs/libcccs.la \
|
||||
spicelib/devices/ccvs/libccvs.la \
|
||||
spicelib/devices/cpl/libcpl.la \
|
||||
spicelib/devices/csw/libcsw.la \
|
||||
spicelib/devices/dio/libdio.la \
|
||||
spicelib/devices/ind/libind.la \
|
||||
spicelib/devices/isrc/libisrc.la \
|
||||
spicelib/devices/hfet1/libhfet.la \
|
||||
spicelib/devices/hfet2/libhfet2.la \
|
||||
spicelib/devices/hisim/libhisim.la \
|
||||
spicelib/devices/jfet/libjfet.la \
|
||||
spicelib/devices/jfet2/libjfet2.la \
|
||||
spicelib/devices/ltra/libltra.la \
|
||||
spicelib/devices/mes/libmes.la \
|
||||
spicelib/devices/mesa/libmesa.la \
|
||||
spicelib/devices/mos1/libmos1.la \
|
||||
spicelib/devices/mos2/libmos2.la \
|
||||
spicelib/devices/mos3/libmos3.la \
|
||||
spicelib/devices/mos6/libmos6.la \
|
||||
spicelib/devices/mos9/libmos9.la \
|
||||
spicelib/devices/res/libres.la \
|
||||
spicelib/devices/soi3/libsoi3.la \
|
||||
spicelib/devices/sw/libsw.la \
|
||||
spicelib/devices/txl/libtxl.la \
|
||||
spicelib/devices/tra/libtra.la \
|
||||
spicelib/devices/urc/liburc.la \
|
||||
spicelib/devices/vbic/libvbic.la \
|
||||
spicelib/devices/vccs/libvccs.la \
|
||||
spicelib/devices/vcvs/libvcvs.la \
|
||||
spicelib/devices/vsrc/libvsrc.la \
|
||||
@NDEV_LIB@ \
|
||||
@VLADEV@ \
|
||||
@NUMDEV@
|
||||
|
|
@ -94,37 +97,39 @@ ngspice_SOURCES += winmain.c
|
|||
endif
|
||||
|
||||
ngspice_LDADD = \
|
||||
spice.o \
|
||||
frontend/libfte.a \
|
||||
spice.lo \
|
||||
frontend/libfte.la \
|
||||
@WINDISPLIB@ \
|
||||
frontend/plotting/libplotting.a \
|
||||
frontend/plotting/libplotting.la \
|
||||
@XSPICELIB1@ \
|
||||
spicelib/devices/dev.o \
|
||||
spicelib/devices/dev.lo \
|
||||
$(DYNAMIC_DEVICELIBS) \
|
||||
spicelib/analysis/libckt.a \
|
||||
spicelib/devices/libdev.a \
|
||||
spicelib/analysis/libckt.la \
|
||||
spicelib/devices/libdev.la \
|
||||
@XSPICELIB2@ \
|
||||
frontend/parser/libparser.a \
|
||||
frontend/numparam/libnumparam.a \
|
||||
spicelib/parser/libinp.a \
|
||||
frontend/parser/libparser.la \
|
||||
frontend/numparam/libnumparam.la \
|
||||
spicelib/parser/libinp.la \
|
||||
@CIDERSIM@ \
|
||||
maths/deriv/libderiv.a \
|
||||
maths/cmaths/libcmaths.a \
|
||||
maths/misc/libmathmisc.a \
|
||||
maths/poly/libpoly.a \
|
||||
maths/ni/libni.a \
|
||||
maths/sparse/libsparse.a \
|
||||
misc/libmisc.a
|
||||
maths/deriv/libderiv.la \
|
||||
maths/cmaths/libcmaths.la \
|
||||
maths/misc/libmathmisc.la \
|
||||
maths/poly/libpoly.la \
|
||||
maths/ni/libni.la \
|
||||
maths/sparse/libsparse.la \
|
||||
misc/libmisc.la
|
||||
if !NO_X
|
||||
ngspice_LDADD += \
|
||||
frontend/help/libhlp.a
|
||||
frontend/help/libhlp.la
|
||||
endif
|
||||
|
||||
winmain.o: winmain.c
|
||||
$(COMPILE) -DSIMULATOR -o winmain.o -c $(srcdir)/winmain.c
|
||||
|
||||
spice.o: main.c
|
||||
$(COMPILE) -DSIMULATOR -o spice.o -c $(srcdir)/main.c
|
||||
spice.lo: main.c
|
||||
$(LTCOMPILE) -DSIMULATOR -MT spice.lo -MD -MP -MF $(DEPDIR)/spice.Tpo -c -o spice.o $<
|
||||
mv -f $(DEPDIR)/spice.Tpo $(DEPDIR)/spice.Plo
|
||||
|
||||
|
||||
## nutmeg:
|
||||
|
||||
|
|
@ -139,19 +144,19 @@ ngnutmeg_SOURCES += winmain.c
|
|||
endif
|
||||
|
||||
ngnutmeg_LDADD = \
|
||||
frontend/libfte.a \
|
||||
frontend/libfte.la \
|
||||
@WINDISPLIB@ \
|
||||
frontend/plotting/libplotting.a \
|
||||
frontend/parser/libparser.a \
|
||||
frontend/numparam/libnumparam.a \
|
||||
maths/cmaths/libcmaths.a \
|
||||
maths/misc/libmathmisc.a \
|
||||
maths/poly/libpoly.a \
|
||||
misc/libmisc.a \
|
||||
spicelib/parser/libinp.a
|
||||
frontend/plotting/libplotting.la \
|
||||
frontend/parser/libparser.la \
|
||||
frontend/numparam/libnumparam.la \
|
||||
maths/cmaths/libcmaths.la \
|
||||
maths/misc/libmathmisc.la \
|
||||
maths/poly/libpoly.la \
|
||||
misc/libmisc.la \
|
||||
spicelib/parser/libinp.la
|
||||
if !NO_X
|
||||
ngnutmeg_LDADD += \
|
||||
frontend/help/libhlp.a
|
||||
frontend/help/libhlp.la
|
||||
endif
|
||||
|
||||
## help:
|
||||
|
|
@ -167,11 +172,11 @@ endif
|
|||
# rather than the full front-end library libfte.a to avoid link errors that
|
||||
# that would otherwise occur (thanks to Andreas Unger for this fix).
|
||||
nghelp_LDADD = \
|
||||
frontend/terminal.o \
|
||||
misc/libmisc.a
|
||||
frontend/terminal.lo \
|
||||
misc/libmisc.la
|
||||
if !NO_X
|
||||
nghelp_LDADD += \
|
||||
frontend/help/libhlp.a
|
||||
frontend/help/libhlp.la
|
||||
endif
|
||||
endif
|
||||
|
||||
|
|
@ -184,19 +189,19 @@ ngsconvert_SOURCES = ngsconvert.c
|
|||
|
||||
|
||||
ngsconvert_LDADD = \
|
||||
frontend/libfte.a \
|
||||
frontend/parser/libparser.a \
|
||||
maths/misc/libmathmisc.a \
|
||||
misc/libmisc.a
|
||||
frontend/libfte.la \
|
||||
frontend/parser/libparser.la \
|
||||
maths/misc/libmathmisc.la \
|
||||
misc/libmisc.la
|
||||
|
||||
## proc2mod:
|
||||
|
||||
ngproc2mod_SOURCES = ngproc2mod.c
|
||||
|
||||
ngproc2mod_LDADD = \
|
||||
frontend/parser/libparser.a \
|
||||
spicelib/parser/libinp.a \
|
||||
misc/libmisc.a
|
||||
frontend/parser/libparser.la \
|
||||
spicelib/parser/libinp.la \
|
||||
misc/libmisc.la
|
||||
|
||||
|
||||
## multidec:
|
||||
|
|
@ -204,8 +209,8 @@ ngproc2mod_LDADD = \
|
|||
ngmultidec_SOURCES = ngmultidec.c
|
||||
|
||||
ngmultidec_LDADD = \
|
||||
maths/sparse/libsparse.a \
|
||||
misc/libmisc.a
|
||||
maths/sparse/libsparse.la \
|
||||
misc/libmisc.la
|
||||
|
||||
endif !WINDOWS
|
||||
|
||||
|
|
@ -231,3 +236,69 @@ LIBS += -lpsapi
|
|||
endif
|
||||
|
||||
MAINTAINERCLEANFILES = Makefile.in ngspice.idx
|
||||
|
||||
if TCL_MODULE
|
||||
lib_LTLIBRARIES = libspice.la
|
||||
install: install-libLTLIBRARIES install-tcl-recursive install-tclspice install-data-am
|
||||
EXTRA_DIST += tclspice.c
|
||||
|
||||
libspice_la_SOURCES =
|
||||
libspice_la_LIBADD = ngspice.lo conf.lo \
|
||||
spice.lo \
|
||||
@X_LIBS@ \
|
||||
frontend/libfte.la \
|
||||
@WINDISPLIB@ \
|
||||
frontend/plotting/libplotting.la \
|
||||
@XSPICELIB1@ \
|
||||
$(DYNAMIC_DEVICELIBS) \
|
||||
spicelib/analysis/libckt.la \
|
||||
spicelib/devices/libdev.la \
|
||||
@XSPICELIB2@ \
|
||||
frontend/parser/libparser.la \
|
||||
frontend/numparam/libnumparam.la \
|
||||
spicelib/parser/libinp.la \
|
||||
@CIDERSIM@ \
|
||||
maths/deriv/libderiv.la \
|
||||
maths/cmaths/libcmaths.la \
|
||||
maths/misc/libmathmisc.la \
|
||||
maths/poly/libpoly.la \
|
||||
maths/ni/libni.la \
|
||||
maths/sparse/libsparse.la \
|
||||
misc/libmisc.la \
|
||||
tclspice.lo $(LIBS)
|
||||
libspice_la_CFLAGS = $(AM_CFLAGS)
|
||||
libspice_la_LDFALGS = -shared -Wl,--version-script=tclspice.map
|
||||
|
||||
CLEANFILES = pkgIndex.tcl libspice.so
|
||||
|
||||
TCL_PKG_PATH = @TCL_PACKAGE_PATH@
|
||||
|
||||
TCLSPICE_VERSION = @VERSION@
|
||||
|
||||
|
||||
TCL_FILES = libspice.la pkgIndex.tcl
|
||||
|
||||
|
||||
pkgIndex.tcl: pkgIndex.tcl.in
|
||||
rm -f $@
|
||||
sed -e 's;%LIB_DIR%;$(libdir);g' $< | \
|
||||
sed -e 's;%VERSION%;$(TCLSPICE_VERSION);g' > $@
|
||||
|
||||
all: $(TCL_FILES)
|
||||
|
||||
install-tcl-recursive:
|
||||
list='$(SUBDIRS)'; for subdir in $$list; do \
|
||||
echo "Making $$target in $$subdir"; \
|
||||
(cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) install) \
|
||||
|| case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
|
||||
done;
|
||||
|
||||
install-tclspice:
|
||||
$(mkinstalldirs) $(libdir)/spice
|
||||
$(INSTALL_DATA) pkgIndex.tcl $(libdir)/spice
|
||||
|
||||
tclspice.lo: tclspice.c
|
||||
$(LTCOMPILE) -DTCLSPICE_version="\"$(TCLSPICE_VERSION)\"" -MT tclspice.lo -MD -MP -MF $(DEPDIR)/tclspice.Tpo -c -o tclspice.o $<
|
||||
mv -f $(DEPDIR)/tclspice.Tpo $(DEPDIR)/tclspice.Plo
|
||||
|
||||
endif
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libciderinput.a
|
||||
noinst_LTLIBRARIES = libciderinput.la
|
||||
|
||||
libciderinput_a_SOURCES = \
|
||||
libciderinput_la_SOURCES = \
|
||||
bdryset.c \
|
||||
boundary.c \
|
||||
cards.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libcideroned.a
|
||||
noinst_LTLIBRARIES = libcideroned.la
|
||||
|
||||
libcideroned_a_SOURCES = \
|
||||
libcideroned_la_SOURCES = \
|
||||
oneadmit.c \
|
||||
oneaval.c \
|
||||
onecond.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libcidersuprt.a
|
||||
noinst_LTLIBRARIES = libcidersuprt.la
|
||||
|
||||
libcidersuprt_a_SOURCES = \
|
||||
libcidersuprt_la_SOURCES = \
|
||||
database.c \
|
||||
devprint.c \
|
||||
geominfo.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libcidertwod.a
|
||||
noinst_LTLIBRARIES = libcidertwod.la
|
||||
|
||||
libcidertwod_a_SOURCES = \
|
||||
libcidertwod_la_SOURCES = \
|
||||
twoadmit.c \
|
||||
twoaval.c \
|
||||
twocond.c \
|
||||
|
|
|
|||
|
|
@ -4,9 +4,11 @@
|
|||
SUBDIRS = plotting help parser wdisp numparam
|
||||
DIST_SUBDIRS = plotting help parser wdisp numparam
|
||||
|
||||
noinst_LIBRARIES = libfte.a
|
||||
noinst_LTLIBRARIES = libfte.la
|
||||
|
||||
libfte_a_SOURCES = \
|
||||
libfte_la_SOURCES = \
|
||||
com_measure2.c \
|
||||
com_measure2.h \
|
||||
commands.c \
|
||||
commands.h \
|
||||
com_ahelp.c \
|
||||
|
|
|
|||
|
|
@ -0,0 +1,940 @@
|
|||
#include <config.h>
|
||||
#include <ngspice.h>
|
||||
|
||||
#include <fteext.h>
|
||||
#include <wordlist.h>
|
||||
|
||||
#include "vectors.h"
|
||||
#include <math.h>
|
||||
|
||||
typedef struct measure
|
||||
{
|
||||
char *result;
|
||||
|
||||
char *m_vec; // name of the output variable which determines the beginning of the measurement
|
||||
char *m_vec2;
|
||||
int m_rise;
|
||||
int m_fall;
|
||||
int m_cross;
|
||||
float m_val; // value of the m_ver at which the counter for crossing, rises or falls is incremented by one
|
||||
float m_td; // amount of delay before the measurement should start
|
||||
float m_from;
|
||||
float m_to;
|
||||
float m_at;
|
||||
float m_measured;
|
||||
float m_measured_at;
|
||||
|
||||
} measure;
|
||||
|
||||
enum AnalysisType {
|
||||
AT_DELAY, AT_TRIG,
|
||||
AT_FIND, AT_WHEN,
|
||||
AT_AVG, AT_MIN, AT_MAX, AT_RMS, AT_PP,
|
||||
AT_INTEG, AT_DERIV,
|
||||
AT_ERR, AT_ERR1, AT_ERR2, AT_ERR3
|
||||
};
|
||||
|
||||
void com_measure_when(struct measure *meas) {
|
||||
|
||||
int i, first;
|
||||
int riseCnt =0;
|
||||
int fallCnt =0;
|
||||
int crossCnt =0;
|
||||
int section = -1;
|
||||
float value, prevValue;
|
||||
float timeValue, prevTimeValue;
|
||||
|
||||
enum ValSide { S_ABOVE_VAL, S_BELOW_VAL };
|
||||
enum ValEdge { E_RISING, E_FALLING };
|
||||
|
||||
struct dvec *d, *dTime;
|
||||
|
||||
d = vec_get(meas->m_vec);
|
||||
dTime = plot_cur->pl_scale;
|
||||
|
||||
if (d == NULL) {
|
||||
fprintf(cp_err, "Error: no such vector as %s.\n", meas->m_vec);
|
||||
return;
|
||||
}
|
||||
|
||||
if (dTime == NULL) {
|
||||
fprintf(cp_err, "Error: no such vector as time.\n");
|
||||
return;
|
||||
}
|
||||
|
||||
prevValue =0;
|
||||
prevTimeValue =0;
|
||||
first =0;
|
||||
|
||||
for (i=0; i < d->v_length; i++) {
|
||||
|
||||
value = d->v_realdata[i];
|
||||
timeValue = dTime->v_realdata[i];
|
||||
|
||||
if (timeValue < meas->m_td)
|
||||
continue;
|
||||
|
||||
if (first == 1) {
|
||||
// initialise
|
||||
crossCnt =0;
|
||||
if (value < meas->m_val) {
|
||||
section = S_BELOW_VAL;
|
||||
if ( (prevValue <= meas->m_val) && (value >= meas->m_val) ) {
|
||||
fallCnt =1;
|
||||
crossCnt =1;
|
||||
}
|
||||
|
||||
} else {
|
||||
section = S_ABOVE_VAL;
|
||||
if ( (prevValue <= meas->m_val) && (value >= meas->m_val) ) {
|
||||
riseCnt =1;
|
||||
crossCnt =1;
|
||||
}
|
||||
}
|
||||
printf("");
|
||||
}
|
||||
|
||||
if (first > 1) {
|
||||
|
||||
if ( (section == S_BELOW_VAL) && (value >= meas->m_val) ) {
|
||||
section = S_ABOVE_VAL;
|
||||
crossCnt++;
|
||||
riseCnt++;
|
||||
|
||||
} else if ( (section == S_ABOVE_VAL) && (value <= meas->m_val) ) {
|
||||
section = S_BELOW_VAL;
|
||||
crossCnt++;
|
||||
fallCnt++;
|
||||
}
|
||||
|
||||
if ((crossCnt == meas->m_cross) || (riseCnt == meas->m_rise) || (fallCnt == meas->m_fall)) {
|
||||
meas->m_measured = prevTimeValue + (meas->m_val - prevValue) * (timeValue - prevTimeValue) / (value - prevValue);
|
||||
return;
|
||||
|
||||
}
|
||||
}
|
||||
first ++;
|
||||
|
||||
prevValue = value;
|
||||
prevTimeValue = timeValue;
|
||||
}
|
||||
|
||||
meas->m_measured = 0.0e0;
|
||||
return;
|
||||
}
|
||||
|
||||
void measure_at(struct measure *meas, float at) {
|
||||
|
||||
int i;
|
||||
float value, pvalue, svalue, psvalue;
|
||||
struct dvec *d, *dScale;
|
||||
|
||||
psvalue = pvalue = 0;
|
||||
d = vec_get(meas->m_vec);
|
||||
dScale = plot_cur->pl_scale;
|
||||
|
||||
if (d == NULL) {
|
||||
fprintf(cp_err, "Error: no such vector as %s.\n", meas->m_vec);
|
||||
return;
|
||||
}
|
||||
|
||||
if (dScale == NULL) {
|
||||
fprintf(cp_err, "Error: no such vector time.\n");
|
||||
return;
|
||||
}
|
||||
|
||||
for (i=0; i < d->v_length; i++) {
|
||||
value = d->v_realdata[i];
|
||||
svalue = dScale->v_realdata[i];
|
||||
|
||||
if ( (i > 0) && (psvalue <= at) && (svalue >= at) ) {
|
||||
meas->m_measured = pvalue + (at - psvalue) * (value - pvalue) / (svalue - psvalue);
|
||||
// meas->m_measured = value;
|
||||
return;
|
||||
}
|
||||
|
||||
psvalue = svalue;
|
||||
pvalue = value;
|
||||
}
|
||||
|
||||
meas->m_measured = 0.0e0;
|
||||
return;
|
||||
}
|
||||
|
||||
void measure_avg( ) {
|
||||
// AVG (Average):
|
||||
// Calculates the area under the 'out_var' divided by the periods of intrest
|
||||
return;
|
||||
}
|
||||
|
||||
void measure_minMaxAvg( struct measure *meas, int minMax ) {
|
||||
|
||||
int i, avgCnt;
|
||||
struct dvec *d, *dScale;
|
||||
float value, svalue, mValue, mValueAt;
|
||||
int first;
|
||||
|
||||
mValue =0;
|
||||
mValueAt = svalue =0;
|
||||
meas->m_measured = 0.0e0;
|
||||
meas->m_measured_at = 0.0e0;
|
||||
first =0;
|
||||
avgCnt =0;
|
||||
|
||||
d = vec_get(meas->m_vec);
|
||||
if (d == NULL) {
|
||||
fprintf(cp_err, "Error: no such vector as %s.\n", meas->m_vec);
|
||||
return;
|
||||
}
|
||||
|
||||
dScale = vec_get("time");
|
||||
if (d == NULL) {
|
||||
fprintf(cp_err, "Error: no such vector as time.\n");
|
||||
return;
|
||||
}
|
||||
|
||||
for (i=0; i < d->v_length; i++) {
|
||||
value = d->v_realdata[i];
|
||||
svalue = dScale->v_realdata[i];
|
||||
|
||||
if (svalue < meas->m_from)
|
||||
continue;
|
||||
|
||||
if ((meas->m_to != 0.0e0) && (svalue > meas->m_to) )
|
||||
break;
|
||||
|
||||
if (first ==0) {
|
||||
mValue = value;
|
||||
mValueAt = svalue;
|
||||
first =1;
|
||||
|
||||
} else {
|
||||
switch (minMax) {
|
||||
case AT_MIN: {
|
||||
if (value <= mValue) {
|
||||
mValue = value;
|
||||
mValueAt = svalue;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case AT_MAX: {
|
||||
if (value >= mValue) {
|
||||
mValue = value;
|
||||
mValueAt = svalue;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case AT_AVG:
|
||||
case AT_RMS: {
|
||||
mValue = mValue + value;
|
||||
avgCnt ++;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
switch (minMax)
|
||||
{
|
||||
case AT_AVG: {
|
||||
meas->m_measured = (mValue / avgCnt);
|
||||
meas->m_measured_at = svalue;
|
||||
break;
|
||||
}
|
||||
case AT_RMS: {
|
||||
// printf(" mValue %e svalue %e avgCnt %i, ", mValue, svalue, avgCnt);
|
||||
meas->m_measured = sqrt(mValue) / avgCnt;
|
||||
meas->m_measured_at = svalue;
|
||||
break;
|
||||
}
|
||||
case AT_MIN:
|
||||
case AT_MAX: {
|
||||
meas->m_measured = mValue;
|
||||
meas->m_measured_at = mValueAt;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
void measure_rms( ) {
|
||||
// RMS (root mean squared):
|
||||
// Calculates the square root of the area under the 'out_var2' curve
|
||||
// divided be the period of interest
|
||||
return;
|
||||
}
|
||||
|
||||
void measure_integ( ) {
|
||||
// INTEGRAL INTEG
|
||||
return;
|
||||
}
|
||||
|
||||
void measure_deriv( ) {
|
||||
// DERIVATIVE DERIV
|
||||
return;
|
||||
}
|
||||
|
||||
// ERR Equations
|
||||
void measure_ERR( ) {
|
||||
return;
|
||||
}
|
||||
|
||||
void measure_ERR1( ) {
|
||||
return;
|
||||
}
|
||||
|
||||
void measure_ERR2( ) {
|
||||
return;
|
||||
}
|
||||
|
||||
void measure_ERR3( ) {
|
||||
return;
|
||||
}
|
||||
|
||||
void measure_errMessage(char *mName, char *mFunction, char *trigTarg, char *errMsg) {
|
||||
|
||||
printf("\tmeasure '%s' failed\n", mName);
|
||||
printf("Error: measure %s %s(%s) :\n", mName, mFunction, trigTarg);
|
||||
printf("\t%s\n",errMsg);
|
||||
return;
|
||||
}
|
||||
|
||||
void com_dotmeasure( ) {
|
||||
|
||||
// simulation info
|
||||
// printf("*%s\n", plot_cur->pl_title);
|
||||
// printf("\t %s, %s\n", plot_cur->pl_name, plot_cur->pl_date); // missing temp
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
int measure_valid_vector(char *vec) {
|
||||
|
||||
struct dvec *d;
|
||||
|
||||
d = vec_get(vec);
|
||||
if (d == NULL)
|
||||
return 0;
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
int measure_parse_stdParams (struct measure *meas, wordlist *wl, wordlist *wlBreak, char *errbuf) {
|
||||
|
||||
int pCnt;
|
||||
char *p, *pName, *pValue;
|
||||
double *engVal, engVal1;
|
||||
|
||||
pCnt =0;
|
||||
while (wl != wlBreak) {
|
||||
p = wl->wl_word;
|
||||
pName = strtok(p, "=");
|
||||
pValue = strtok(NULL, "=");
|
||||
|
||||
if (pValue == NULL) {
|
||||
sprintf(errbuf,"bad syntax of ??\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (!(engVal = ft_numparse(&pValue, FALSE))) {
|
||||
sprintf(errbuf,"bad syntax of ??\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
engVal1 = *engVal;
|
||||
|
||||
if(strcasecmp(pName,"RISE")==0) {
|
||||
meas->m_rise = engVal1;
|
||||
meas->m_fall = -1;
|
||||
meas->m_cross = -1;
|
||||
} else if(strcasecmp(pName,"FALL")==0) {
|
||||
meas->m_fall = engVal1;
|
||||
meas->m_rise = -1;
|
||||
meas->m_cross = -1;
|
||||
} else if(strcasecmp(pName,"CROSS")==0) {
|
||||
meas->m_cross = engVal1;
|
||||
meas->m_rise = -1;
|
||||
meas->m_fall = -1;
|
||||
} else if(strcasecmp(pName,"VAL")==0) {
|
||||
meas->m_val = engVal1;
|
||||
} else if(strcasecmp(pName,"TD")==0) {
|
||||
meas->m_td = engVal1;
|
||||
} else if(strcasecmp(pName,"FROM")==0) {
|
||||
meas->m_from = engVal1;
|
||||
} else if(strcasecmp(pName,"TO")==0) {
|
||||
meas->m_to = engVal1;
|
||||
} else if(strcasecmp(pName,"AT")==0) {
|
||||
meas->m_at = engVal1;
|
||||
} else {
|
||||
sprintf(errbuf,"no such parameter as '%s'\n",pName);
|
||||
return 0;
|
||||
}
|
||||
|
||||
pCnt ++;
|
||||
wl = wl->wl_next;
|
||||
}
|
||||
|
||||
if (pCnt == 0) {
|
||||
sprintf(errbuf,"bad syntax of ??\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
// valid vector
|
||||
if (measure_valid_vector(meas->m_vec)==0) {
|
||||
sprintf(errbuf,"no such vector as '%s'\n", meas->m_vec);
|
||||
return 0;
|
||||
}
|
||||
|
||||
// valid vector2
|
||||
if (meas->m_vec2 != NULL) {
|
||||
if (measure_valid_vector(meas->m_vec2)==0) {
|
||||
sprintf(errbuf,"no such vector as '%s'\n", meas->m_vec2);
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
int measure_parse_find (struct measure *meas, wordlist *wl, wordlist *wlBreak, char *errbuf) {
|
||||
|
||||
int pCnt;
|
||||
char *p, *pName, *pVal;
|
||||
double *engVal, engVal1;
|
||||
|
||||
meas->m_vec = NULL;
|
||||
meas->m_vec2 = NULL;
|
||||
meas->m_val = -1;
|
||||
meas->m_cross = -1;
|
||||
meas->m_fall = -1;
|
||||
meas->m_rise = -1;
|
||||
meas->m_td = 0;
|
||||
meas->m_from = 0.0e0;
|
||||
meas->m_to = 0.0e0;
|
||||
meas->m_at = -1;
|
||||
|
||||
pCnt =0;
|
||||
while(wl != wlBreak) {
|
||||
p = wl->wl_word;
|
||||
|
||||
if (pCnt == 0 ) {
|
||||
// meas->m_vec =(char *)malloc(strlen(wl->wl_word)+1);
|
||||
// strcpy(meas->m_vec, cp_unquote(wl->wl_word));
|
||||
meas->m_vec= cp_unquote(wl->wl_word);
|
||||
} else if (pCnt == 1) {
|
||||
|
||||
pName = strtok(p, "=");
|
||||
pVal = strtok(NULL, "=");
|
||||
|
||||
if (pVal == NULL) {
|
||||
sprintf(errbuf,"bad syntax of WHEN\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (strcasecmp(pName,"AT")==0) {
|
||||
|
||||
if (!(engVal = ft_numparse(&pVal, FALSE))) {
|
||||
sprintf(errbuf,"bad syntax of WHEN\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
engVal1 = *engVal;
|
||||
|
||||
meas->m_at = engVal1;
|
||||
|
||||
} else {
|
||||
sprintf(errbuf,"bad syntax of WHEN\n");
|
||||
return 0;
|
||||
}
|
||||
} else {
|
||||
if (measure_parse_stdParams(meas, wl, NULL, errbuf) == 0)
|
||||
return 0;
|
||||
}
|
||||
|
||||
wl = wl->wl_next;
|
||||
pCnt ++;
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
int measure_parse_when (struct measure *meas, wordlist *wl, char *errBuf) {
|
||||
|
||||
int pCnt;
|
||||
char *p, *pVar1, *pVar2;
|
||||
|
||||
meas->m_vec = NULL;
|
||||
meas->m_vec2 = NULL;
|
||||
meas->m_val = -1;
|
||||
meas->m_cross = -1;
|
||||
meas->m_fall = -1;
|
||||
meas->m_rise = -1;
|
||||
meas->m_td = 0;
|
||||
meas->m_from = 0.0e0;
|
||||
meas->m_to = 0.0e0;
|
||||
meas->m_at = -1;
|
||||
|
||||
pCnt =0;
|
||||
while (wl) {
|
||||
p= wl->wl_word;
|
||||
|
||||
if (pCnt == 0) {
|
||||
pVar1 = strtok(p, "=");
|
||||
pVar2 = strtok(NULL, "=");
|
||||
|
||||
if (pVar2 == NULL) {
|
||||
sprintf(errBuf,"bad syntax\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
meas->m_vec = pVar1;
|
||||
if (measure_valid_vector(pVar2)==1)
|
||||
meas->m_vec2 = pVar2;
|
||||
else
|
||||
meas->m_val = atof(pVar2);
|
||||
} else {
|
||||
if (measure_parse_stdParams(meas, wl, NULL, errBuf) == 0)
|
||||
return 0;
|
||||
break;
|
||||
}
|
||||
|
||||
wl = wl->wl_next;
|
||||
pCnt ++;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
int measure_parse_trigtarg (struct measure *meas, wordlist *words, wordlist *wlTarg, char *trigTarg, char *errbuf) {
|
||||
|
||||
int pcnt;
|
||||
char *p;
|
||||
|
||||
meas->m_vec = NULL;
|
||||
meas->m_vec2 = NULL;
|
||||
meas->m_cross = -1;
|
||||
meas->m_fall = -1;
|
||||
meas->m_rise = -1;
|
||||
meas->m_td = 0;
|
||||
meas->m_from = 0.0e0;
|
||||
meas->m_to = 0.0e0;
|
||||
meas->m_at = -1;
|
||||
|
||||
pcnt =0;
|
||||
while (words != wlTarg) {
|
||||
p = words->wl_word;
|
||||
|
||||
if (pcnt ==0) {
|
||||
// meas->m_vec =(char *)malloc(strlen(words->wl_word)+1);
|
||||
// strcpy(meas->m_vec, cp_unquote(words->wl_word));
|
||||
meas->m_vec= cp_unquote(words->wl_word);
|
||||
} else {
|
||||
|
||||
if (measure_parse_stdParams(meas, words, wlTarg, errbuf) == 0)
|
||||
return 0;
|
||||
break;
|
||||
|
||||
}
|
||||
|
||||
words = words->wl_next;
|
||||
pcnt ++;
|
||||
}
|
||||
|
||||
if (pcnt == 0) {
|
||||
sprintf(errbuf,"bad syntax of '%s'\n", trigTarg);
|
||||
return 0;
|
||||
}
|
||||
|
||||
// valid vector
|
||||
if (measure_valid_vector(meas->m_vec)==0) {
|
||||
sprintf(errbuf,"no such vector as '%s'\n", meas->m_vec);
|
||||
return 0;
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
float
|
||||
get_measure2(wordlist *wl)
|
||||
{
|
||||
wordlist *words, *wlTarg, *wlWhen;
|
||||
char errbuf[100];
|
||||
char *mType = NULL; // analysis type
|
||||
char *mName = NULL; // name given to the measured output
|
||||
char *mFunction = NULL;
|
||||
int mFunctionType, wl_cnt;
|
||||
char *p;
|
||||
|
||||
mFunctionType = -1;
|
||||
|
||||
if (!wl) {
|
||||
printf("usage: measure .....\n");
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
if (!plot_cur || !plot_cur->pl_dvecs || !plot_cur->pl_scale) {
|
||||
fprintf(cp_err, "Error: no vectors available\n");
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
if (!ciprefix("tran", plot_cur->pl_typename)) {
|
||||
fprintf(cp_err, "Error: measure limited to transient analysis\n");
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
words =wl;
|
||||
wlTarg = NULL;
|
||||
wlWhen = NULL;
|
||||
|
||||
if (!words) {
|
||||
fprintf(cp_err, "Error: no assignment found.\n");
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
wl_cnt = 0;
|
||||
while (words) {
|
||||
|
||||
switch(wl_cnt)
|
||||
{
|
||||
case 0:
|
||||
mType = cp_unquote(words->wl_word);
|
||||
break;
|
||||
case 1:
|
||||
mName = cp_unquote(words->wl_word);
|
||||
break;
|
||||
case 2:
|
||||
{
|
||||
mFunction = cp_unquote(words->wl_word);
|
||||
// Functions
|
||||
if (strcasecmp(mFunction,"DELAY")==0)
|
||||
mFunctionType = AT_DELAY;
|
||||
else if (strcasecmp(mFunction,"TRIG")==0)
|
||||
mFunctionType = AT_DELAY;
|
||||
else if (strcasecmp(mFunction,"FIND")==0)
|
||||
mFunctionType = AT_FIND;
|
||||
else if (strcasecmp(mFunction,"WHEN")==0)
|
||||
mFunctionType = AT_WHEN;
|
||||
else if (strcasecmp(mFunction,"AVG")==0)
|
||||
mFunctionType = AT_AVG;
|
||||
else if (strcasecmp(mFunction,"MIN")==0)
|
||||
mFunctionType = AT_MIN;
|
||||
else if (strcasecmp(mFunction,"MAX")==0)
|
||||
mFunctionType = AT_MAX;
|
||||
else if (strcasecmp(mFunction,"RMS")==0)
|
||||
mFunctionType = AT_RMS;
|
||||
else if (strcasecmp(mFunction,"PP")==0)
|
||||
mFunctionType = AT_PP;
|
||||
else if (strcasecmp(mFunction,"INTEG")==0)
|
||||
mFunctionType = AT_INTEG;
|
||||
else if (strcasecmp(mFunction,"DERIV")==0)
|
||||
mFunctionType = AT_DERIV;
|
||||
else if (strcasecmp(mFunction,"ERR")==0)
|
||||
mFunctionType = AT_ERR;
|
||||
else if (strcasecmp(mFunction,"ERR1")==0)
|
||||
mFunctionType = AT_ERR1;
|
||||
else if (strcasecmp(mFunction,"ERR2") == 0)
|
||||
mFunctionType = AT_ERR2;
|
||||
else if (strcasecmp(mFunction,"ERR3") == 0)
|
||||
mFunctionType = AT_ERR3;
|
||||
else {
|
||||
printf("\tmeasure '%s' failed\n", mName);
|
||||
printf("Error: measure %s :\n", mName);
|
||||
printf("\tno such function as '%s'\n", mFunction);
|
||||
return 0.0e0;
|
||||
}
|
||||
break;
|
||||
}
|
||||
default:
|
||||
{
|
||||
p = words->wl_word;
|
||||
|
||||
if (strcasecmp(p,"targ")==0)
|
||||
wlTarg = words;
|
||||
|
||||
if (strcasecmp(p,"when")==0)
|
||||
wlWhen = words;
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
wl_cnt ++;
|
||||
words = words->wl_next;
|
||||
}
|
||||
|
||||
if (wl_cnt < 3) {
|
||||
printf("\tmeasure '%s' failed\n", mName);
|
||||
printf("Error: measure %s :\n", mName);
|
||||
printf("\tinvalid num params\n");
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
//------------------------
|
||||
|
||||
|
||||
words =wl;
|
||||
|
||||
if (words)
|
||||
words = words->wl_next; // skip
|
||||
if (words)
|
||||
words = words->wl_next; // results name
|
||||
if (words)
|
||||
words = words->wl_next; // Function
|
||||
|
||||
|
||||
// switch here
|
||||
switch(mFunctionType)
|
||||
{
|
||||
case AT_DELAY:
|
||||
case AT_TRIG:
|
||||
{
|
||||
// trig parameters
|
||||
measure *measTrig, *measTarg;
|
||||
measTrig = (struct measure*)malloc(sizeof(struct measure));
|
||||
measTarg = (struct measure*)malloc(sizeof(struct measure));
|
||||
|
||||
if (measure_parse_trigtarg(measTrig, words , wlTarg, "trig", errbuf)==0) {
|
||||
measure_errMessage(mName, mFunction, "TRIG", errbuf);
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
if ((measTrig->m_rise == -1) && (measTrig->m_fall == -1) && (measTrig->m_cross == -1)) {
|
||||
sprintf(errbuf,"rise, fall or cross must be given\n");
|
||||
measure_errMessage(mName, mFunction, "TRIG", errbuf);
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
while (words != wlTarg)
|
||||
words = words->wl_next; // hack
|
||||
|
||||
if (words)
|
||||
words = words->wl_next; // skip targ
|
||||
|
||||
if (measure_parse_trigtarg(measTarg, words , NULL, "targ", errbuf)==0) {
|
||||
measure_errMessage(mName, mFunction, "TARG", errbuf);
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
if ((measTarg->m_rise == -1) && (measTarg->m_fall == -1) && (measTarg->m_cross == -1)) {
|
||||
sprintf(errbuf,"rise, fall or cross must be given\n");
|
||||
measure_errMessage(mName, mFunction, "TARG", errbuf);
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
// measure trig
|
||||
if (measTrig->m_at == -1)
|
||||
com_measure_when(measTrig);
|
||||
else
|
||||
measTrig->m_measured = measTrig->m_at;
|
||||
|
||||
|
||||
if (measTrig->m_measured == 0.0e0) {
|
||||
sprintf(errbuf,"out of interval\n");
|
||||
measure_errMessage(mName, mFunction, "TRIG", errbuf);
|
||||
return 0.0e0;
|
||||
}
|
||||
// measure targ
|
||||
com_measure_when(measTarg);
|
||||
|
||||
if (measTarg->m_measured == 0.0e0) {
|
||||
sprintf(errbuf,"out of interval\n");
|
||||
measure_errMessage(mName, mFunction, "TARG", errbuf);
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
// print results
|
||||
printf("%-20s= %e targ= %e trig= %e\n", mName, (measTarg->m_measured - measTrig->m_measured), measTarg->m_measured, measTrig->m_measured);
|
||||
|
||||
return (measTarg->m_measured - measTrig->m_measured);
|
||||
}
|
||||
case AT_FIND:
|
||||
{
|
||||
measure *meas, *measFind;
|
||||
meas = (struct measure*)malloc(sizeof(struct measure));
|
||||
measFind = (struct measure*)malloc(sizeof(struct measure));
|
||||
|
||||
if (measure_parse_find(meas, words, wlWhen, errbuf) == 0) {
|
||||
measure_errMessage(mName, mFunction, "FIND", errbuf);
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
if (meas->m_at == -1 ) {
|
||||
// find .. when statment
|
||||
|
||||
while (words != wlWhen)
|
||||
words = words->wl_next; // hack
|
||||
|
||||
if (words)
|
||||
words = words->wl_next; // skip targ
|
||||
|
||||
if (measure_parse_when(measFind, words, errbuf) ==0) {
|
||||
measure_errMessage(mName, mFunction, "WHEN", errbuf);
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
com_measure_when(measFind);
|
||||
|
||||
if (measFind->m_measured == 0.0e0) {
|
||||
sprintf(errbuf,"out of interval\n");
|
||||
measure_errMessage(mName, mFunction, "WHEN", errbuf);
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
measure_at(measFind, measFind->m_measured);
|
||||
meas->m_measured = measFind->m_measured;
|
||||
|
||||
} else {
|
||||
measure_at(meas, meas->m_at);
|
||||
}
|
||||
|
||||
if (meas->m_measured == 0.0e0) {
|
||||
sprintf(errbuf,"out of interval\n");
|
||||
measure_errMessage(mName, mFunction, "WHEN", errbuf);
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
// print results
|
||||
printf("%-20s= %e\n", mName, meas->m_measured);
|
||||
return meas->m_measured;
|
||||
}
|
||||
case AT_WHEN:
|
||||
{
|
||||
measure *meas;
|
||||
meas = (struct measure*)malloc(sizeof(struct measure));
|
||||
|
||||
if (measure_parse_when(meas, words, errbuf) ==0) {
|
||||
measure_errMessage(mName, mFunction, "WHEN", errbuf);
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
com_measure_when(meas);
|
||||
|
||||
if (meas->m_measured == 0.0e0) {
|
||||
sprintf(errbuf,"out of interval\n");
|
||||
measure_errMessage(mName, mFunction, "WHEN", errbuf);
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
// print results
|
||||
printf("%-20s= %e\n", mName, meas->m_measured);
|
||||
|
||||
return (meas->m_measured);
|
||||
}
|
||||
case AT_RMS:
|
||||
printf("\tmeasure '%s' failed\n", mName);
|
||||
printf("Error: measure %s :\n", mName);
|
||||
printf("\tfunction '%s' currently not supported\n", mFunction);
|
||||
break;
|
||||
case AT_AVG:
|
||||
{
|
||||
// trig parameters
|
||||
measure *meas;
|
||||
meas = (struct measure*)malloc(sizeof(struct measure));
|
||||
|
||||
if (measure_parse_trigtarg(meas, words , NULL, "trig", errbuf)==0) {
|
||||
measure_errMessage(mName, mFunction, "TRIG", errbuf);
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
// measure
|
||||
measure_minMaxAvg(meas, mFunctionType);
|
||||
|
||||
if (meas->m_measured == 0.0e0) {
|
||||
sprintf(errbuf,"out of interval\n");
|
||||
measure_errMessage(mName, mFunction, "TRIG", errbuf); // ??
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
if (meas->m_at == -1)
|
||||
meas->m_at = 0.0e0;
|
||||
|
||||
// print results
|
||||
printf("%-20s= %e from= %e to= %e\n", mName, meas->m_measured, meas->m_at, meas->m_measured_at);
|
||||
return meas->m_measured;
|
||||
|
||||
}
|
||||
case AT_MIN:
|
||||
case AT_MAX:
|
||||
{
|
||||
// trig parameters
|
||||
measure *measTrig;
|
||||
measTrig = (struct measure*)malloc(sizeof(struct measure));
|
||||
|
||||
if (measure_parse_trigtarg(measTrig, words , NULL, "trig", errbuf)==0) {
|
||||
measure_errMessage(mName, mFunction, "TRIG", errbuf);
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
// measure
|
||||
if (mFunctionType == AT_MIN)
|
||||
measure_minMaxAvg(measTrig, AT_MIN);
|
||||
else
|
||||
measure_minMaxAvg(measTrig, AT_MAX);
|
||||
|
||||
|
||||
if (measTrig->m_measured == 0.0e0) {
|
||||
sprintf(errbuf,"out of interval\n");
|
||||
measure_errMessage(mName, mFunction, "TRIG", errbuf); // ??
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
// print results
|
||||
printf("%-20s= %e at= %e\n", mName, measTrig->m_measured, measTrig->m_measured_at);
|
||||
return measTrig->m_measured;
|
||||
}
|
||||
case AT_PP:
|
||||
{
|
||||
float minValue, maxValue;
|
||||
|
||||
measure *measTrig;
|
||||
measTrig = (struct measure*)malloc(sizeof(struct measure));
|
||||
|
||||
if (measure_parse_trigtarg(measTrig, words , NULL, "trig", errbuf)==0) {
|
||||
measure_errMessage(mName, mFunction, "TRIG", errbuf);
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
// measure min
|
||||
measure_minMaxAvg(measTrig, AT_MIN);
|
||||
if (measTrig->m_measured == 0.0e0) {
|
||||
sprintf(errbuf,"out of interval\n");
|
||||
measure_errMessage(mName, mFunction, "TRIG", errbuf); // ??
|
||||
return 0.0e0;
|
||||
}
|
||||
minValue = measTrig->m_measured;
|
||||
|
||||
// measure max
|
||||
measure_minMaxAvg(measTrig, AT_MAX);
|
||||
if (measTrig->m_measured == 0.0e0) {
|
||||
sprintf(errbuf,"out of interval\n");
|
||||
measure_errMessage(mName, mFunction, "TRIG", errbuf); // ??
|
||||
return 0.0e0;
|
||||
}
|
||||
maxValue = measTrig->m_measured;
|
||||
|
||||
// print results
|
||||
printf("%-20s= %e from= %e to= %e\n", mName, (maxValue - minValue), measTrig->m_from, measTrig->m_to);
|
||||
return (maxValue - minValue);
|
||||
}
|
||||
case AT_INTEG:
|
||||
case AT_DERIV:
|
||||
case AT_ERR:
|
||||
case AT_ERR1:
|
||||
case AT_ERR2:
|
||||
case AT_ERR3:
|
||||
{
|
||||
printf("\tmeasure '%s' failed\n", mName);
|
||||
printf("Error: measure %s :\n", mName);
|
||||
printf("\tfunction '%s' currently not supported\n", mFunction);
|
||||
break;
|
||||
}
|
||||
}
|
||||
return 0.0e0;
|
||||
}
|
||||
|
||||
void com_measure2(wordlist *wl) {
|
||||
get_measure2(wl);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
#ifndef _COM_MEASURE_H
|
||||
#define _COM_MEASURE_H
|
||||
|
||||
#include <config.h>
|
||||
|
||||
void com_measure2(wordlist *wl);
|
||||
float get_measure2(wordlist *wl);
|
||||
|
||||
#endif
|
||||
|
|
@ -16,3 +16,14 @@ com_plot(wordlist *wl)
|
|||
plotit(wl, (char *) NULL, (char *) NULL);
|
||||
return;
|
||||
}
|
||||
|
||||
#ifdef TCL_MODULE
|
||||
void
|
||||
com_bltplot(wordlist *wl)
|
||||
{
|
||||
plotit(wl, (char *) NULL, "blt");
|
||||
return;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
|||
|
|
@ -2,5 +2,7 @@
|
|||
#define _COM_PLOT_H
|
||||
|
||||
void com_plot(wordlist *wl);
|
||||
|
||||
#ifdef TCL_MODULE
|
||||
void com_bltplot(wordlist *wl);
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -118,10 +118,21 @@ struct comm spcp_coms[] = {
|
|||
{ 0, 0, 0, 0 }, E_DEFHMASK, 3, LOTS,
|
||||
(void (*)()) NULL,
|
||||
"spec name pat ... : Redefine vector and plot types.\n" } ,
|
||||
#ifdef TCL_MODULE
|
||||
{ "bltplot", com_bltplot, FALSE, FALSE, TRUE,
|
||||
{ 041000, 041000, 041000, 041000 }, E_BEGINNING | E_HASPLOTS, 1, LOTS,
|
||||
arg_plot,
|
||||
"expr ... [vs expr] [xl xlo xhi] [yl ylo yhi] : Plot things." },
|
||||
{ "plot", com_bltplot, FALSE, FALSE, TRUE,
|
||||
{ 041000, 041000, 041000, 041000 }, E_BEGINNING | E_HASPLOTS, 1, LOTS,
|
||||
arg_plot,
|
||||
"expr ... [vs expr] [xl xlo xhi] [yl ylo yhi] : Plot things." },
|
||||
#else
|
||||
{ "plot", com_plot, FALSE, FALSE, TRUE,
|
||||
{ 041000, 041000, 041000, 041000 }, E_BEGINNING | E_HASPLOTS, 1, LOTS,
|
||||
arg_plot,
|
||||
"expr ... [vs expr] [xl xlo xhi] [yl ylo yhi] : Plot things." },
|
||||
#endif
|
||||
{ "display", com_display, FALSE, FALSE, TRUE,
|
||||
{ 040000, 040000, 040000, 040000 }, E_BEGINNING, 0, LOTS,
|
||||
arg_display,
|
||||
|
|
|
|||
|
|
@ -11,6 +11,10 @@ $Id$
|
|||
#include <cpdefs.h> /* for VT_STRING */
|
||||
#include <ftedefs.h> /* for mylog() */
|
||||
|
||||
#ifdef TCL_MODULE
|
||||
#include <tclspice.h>
|
||||
#endif
|
||||
|
||||
#include "display.h"
|
||||
#include "variable.h"
|
||||
#include "error.h"
|
||||
|
|
@ -70,6 +74,15 @@ DISPDEVICE device[] = {
|
|||
gen_DatatoScreen,}, /* WPRINT_DiagramReady */
|
||||
#endif
|
||||
|
||||
#ifdef TCL_MODULE
|
||||
{"Tk", 0, 0, 1024, 864, 0, 0, sp_Tk_Init, sp_Tk_NewViewport,
|
||||
sp_Tk_Close, sp_Tk_Clear,
|
||||
sp_Tk_DrawLine, sp_Tk_Arc, sp_Tk_Text, sp_Tk_DefineColor, sp_Tk_DefineLinestyle,
|
||||
sp_Tk_SetLinestyle, sp_Tk_SetColor, sp_Tk_Update,
|
||||
nodev, nodev, nodev, nodev,
|
||||
gen_DatatoScreen,},
|
||||
#endif
|
||||
|
||||
{"plot5", 0, 0, 1000, 1000, 0, 0, Plt5_Init, Plt5_NewViewport,
|
||||
Plt5_Close, Plt5_Clear,
|
||||
Plt5_DrawLine, Plt5_Arc, Plt5_Text, (void*)nodev, (void*)nodev,
|
||||
|
|
@ -151,6 +164,10 @@ DevInit(void)
|
|||
}
|
||||
#endif
|
||||
|
||||
#ifdef TCL_MODULE
|
||||
dispdev = FindDev("Tk");
|
||||
#endif
|
||||
|
||||
if (!dispdev) {
|
||||
externalerror(
|
||||
"no graphics interface; please check compiling instructions");
|
||||
|
|
|
|||
|
|
@ -2,9 +2,9 @@
|
|||
|
||||
if !NO_X
|
||||
|
||||
noinst_LIBRARIES = libhlp.a
|
||||
noinst_LTLIBRARIES = libhlp.la
|
||||
|
||||
libhlp_a_SOURCES = \
|
||||
libhlp_la_SOURCES = \
|
||||
help.c \
|
||||
provide.c \
|
||||
readhelp.c \
|
||||
|
|
|
|||
|
|
@ -2,9 +2,9 @@
|
|||
|
||||
EXTRA_DIST = downgrad.txt ngconfig.sh readme.txt nupatest.c washprog.c
|
||||
|
||||
noinst_LIBRARIES = libnumparam.a
|
||||
noinst_LTLIBRARIES = libnumparam.la
|
||||
|
||||
libnumparam_a_SOURCES = \
|
||||
libnumparam_la_SOURCES = \
|
||||
spicenum.c \
|
||||
xpressn.c \
|
||||
mystring.c \
|
||||
|
|
|
|||
|
|
@ -58,6 +58,12 @@ static bool name_eq(char *n1, char *n2);
|
|||
static bool getSpecial(dataDesc *desc, runDesc *run, IFvalue *val);
|
||||
static void freeRun(runDesc *run);
|
||||
|
||||
/*Output data to spice module saj*/
|
||||
#ifdef TCL_MODULE
|
||||
#include "tclspice.h"
|
||||
#endif
|
||||
/*saj*/
|
||||
|
||||
|
||||
#define DOUBLE_PRECISION 15
|
||||
|
||||
|
|
@ -354,6 +360,10 @@ beginPlot(void *analysisPtr, void *circuitPtr, char *cktName, char *analName, ch
|
|||
run->runPlot->pl_ndims = 1;
|
||||
}
|
||||
}
|
||||
/*Start BLT, initilises the blt vectors saj*/
|
||||
#ifdef TCL_MODULE
|
||||
blt_init(run);
|
||||
#endif
|
||||
return (OK);
|
||||
}
|
||||
|
||||
|
|
@ -435,6 +445,9 @@ OUTpData(void *plotPtr, IFvalue *refValue, IFvalue *valuePtr)
|
|||
#endif /* PARALLEL_ARCH */
|
||||
|
||||
run->pointCount++;
|
||||
#ifdef TCL_MODULE
|
||||
steps_completed = run->pointCount;
|
||||
#endif
|
||||
|
||||
if (run->writeOut) {
|
||||
if (run->pointCount == 1)
|
||||
|
|
@ -473,6 +486,9 @@ OUTpData(void *plotPtr, IFvalue *refValue, IFvalue *valuePtr)
|
|||
for (i = 0; i < run->numData; i++) {
|
||||
/* we've already printed reference vec first */
|
||||
if (run->data[i].outIndex == -1) continue;
|
||||
#ifdef TCL_MODULE
|
||||
blt_add(i,refValue->rValue);
|
||||
#endif
|
||||
|
||||
if (run->data[i].regular) {
|
||||
if(run->data[i].type == IF_REAL)
|
||||
|
|
@ -518,6 +534,10 @@ OUTpData(void *plotPtr, IFvalue *refValue, IFvalue *valuePtr)
|
|||
else
|
||||
fprintf(stderr, "OUTpData: unsupported data type\n");
|
||||
}
|
||||
#ifdef TCL_MODULE
|
||||
blt_add(i,valuePtr->v.vec.rVec
|
||||
[run->data[i].outIndex]);
|
||||
#endif
|
||||
}
|
||||
fileEndPoint(run->fp, run->binary);
|
||||
|
||||
|
|
@ -546,6 +566,10 @@ OUTpData(void *plotPtr, IFvalue *refValue, IFvalue *valuePtr)
|
|||
}
|
||||
#endif
|
||||
for (i = 0; i < run->numData; i++) {
|
||||
#ifdef TCL_MODULE
|
||||
/*Locks the blt vector to stop access*/
|
||||
blt_lockvec(i);
|
||||
#endif
|
||||
if (run->data[i].outIndex == -1) {
|
||||
if (run->data[i].type == IF_REAL)
|
||||
plotAddRealValue(&run->data[i],
|
||||
|
|
@ -575,6 +599,10 @@ OUTpData(void *plotPtr, IFvalue *refValue, IFvalue *valuePtr)
|
|||
else
|
||||
fprintf(stderr, "OUTpData: unsupported data type\n");
|
||||
}
|
||||
#ifdef TCL_MODULE
|
||||
/*relinks and unlocks vector*/
|
||||
blt_relink(i,(run->data[i]).vec);
|
||||
#endif
|
||||
}
|
||||
gr_iplot(run->runPlot);
|
||||
}
|
||||
|
|
@ -582,6 +610,11 @@ OUTpData(void *plotPtr, IFvalue *refValue, IFvalue *valuePtr)
|
|||
if (ft_bpcheck(run->runPlot, run->pointCount) == FALSE)
|
||||
shouldstop = TRUE;
|
||||
|
||||
#ifdef TCL_MODULE
|
||||
Tcl_ExecutePerLoop();
|
||||
#endif
|
||||
|
||||
|
||||
return (OK);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libparser.a
|
||||
noinst_LTLIBRARIES = libparser.la
|
||||
|
||||
libparser_a_SOURCES = \
|
||||
libparser_la_SOURCES = \
|
||||
backq.c \
|
||||
backq.h \
|
||||
complete.c \
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
noinst_LIBRARIES = libplotting.a
|
||||
noinst_LTLIBRARIES = libplotting.la
|
||||
|
||||
libplotting_a_SOURCES = \
|
||||
libplotting_la_SOURCES = \
|
||||
plotting.c \
|
||||
plotting.h \
|
||||
agraf.c \
|
||||
|
|
@ -25,7 +25,7 @@ libplotting_a_SOURCES = \
|
|||
plotit.h
|
||||
|
||||
if !NO_X
|
||||
libplotting_a_SOURCES += \
|
||||
libplotting_la_SOURCES += \
|
||||
x11.c \
|
||||
x11.h \
|
||||
xgraph.c \
|
||||
|
|
|
|||
|
|
@ -21,6 +21,7 @@ $Id$
|
|||
#include <graph.h>
|
||||
#include "ftedbgra.h"
|
||||
#include "ftedev.h"
|
||||
#include <terminal.h>
|
||||
#include <variable.h>
|
||||
#include "graf.h"
|
||||
#include "graphdb.h"
|
||||
|
|
|
|||
|
|
@ -21,7 +21,9 @@
|
|||
static wordlist *wl_root;
|
||||
static bool sameflag;
|
||||
|
||||
|
||||
#ifdef TCL_MODULE
|
||||
#include <tclspice.h>
|
||||
#endif
|
||||
|
||||
/* This routine gets parameters from the command line, which are of
|
||||
* the form "name number ..." It returns a pointer to the parameter
|
||||
|
|
@ -976,7 +978,17 @@ plotit(wordlist *wl, char *hcopy, char *devname)
|
|||
goto quit;
|
||||
}
|
||||
|
||||
|
||||
#ifdef TCL_MODULE
|
||||
if (devname && eq(devname, "blt")) {
|
||||
/* Just send the pairs to Tcl/Tk */
|
||||
for (d = vecs; d; d = d->v_link2) {
|
||||
blt_plot(d, oneval ? (struct dvec *) NULL : d->v_scale,(d==vecs?1:0));
|
||||
}
|
||||
rtn = TRUE;
|
||||
goto quit;
|
||||
}
|
||||
#endif
|
||||
|
||||
for (d = vecs, i = 0; d; d = d->v_link2)
|
||||
i++;
|
||||
|
||||
|
|
|
|||
|
|
@ -44,7 +44,17 @@ $Id$
|
|||
#include "variable.h"
|
||||
#include "terminal.h"
|
||||
|
||||
/* out_printf doesn't handle double arguments correctly, so we
|
||||
sprintf into this buf and call out_send w/ it */
|
||||
char out_pbuf[8*BSIZE_SP];
|
||||
|
||||
bool out_moremode = TRUE;
|
||||
bool out_isatty = TRUE;
|
||||
|
||||
#ifndef TCL_MODULE
|
||||
|
||||
#ifdef HAVE_TERMCAP
|
||||
|
||||
static char *motion_chars;
|
||||
static char *clear_chars;
|
||||
static char *home_chars;
|
||||
|
|
@ -54,17 +64,11 @@ static char *cleol_chars;
|
|||
#define DEF_SCRHEIGHT 24
|
||||
#define DEF_SCRWIDTH 80
|
||||
|
||||
bool out_moremode = TRUE;
|
||||
bool out_isatty = TRUE;
|
||||
|
||||
static int xsize, ysize;
|
||||
static int xpos, ypos;
|
||||
static bool noprint, nopause;
|
||||
|
||||
|
||||
/* out_printf doesn't handle double arguments correctly, so we
|
||||
sprintf into this buf and call out_send w/ it */
|
||||
char out_pbuf[8*BSIZE_SP];
|
||||
|
||||
/* Start output... */
|
||||
|
||||
|
|
@ -345,3 +349,23 @@ term_cleol(void)
|
|||
tputs(cleol_chars, 1, outfn);
|
||||
#endif
|
||||
}
|
||||
|
||||
#else
|
||||
|
||||
void out_init(void) {}
|
||||
void outbufputc(void) {}
|
||||
void promptreturn(void) {}
|
||||
void term_clear(void) {}
|
||||
void term_home(void) {}
|
||||
void term_cleol(void) {}
|
||||
void tcap_init(void) {}
|
||||
|
||||
void out_send(char *string) {fprintf(cp_out,string);}
|
||||
|
||||
void
|
||||
out_printf(char *fmt, char *s1, char *s2, char *s3, char *s4, char *s5,
|
||||
char *s6, char *s7, char *s8, char *s9, char *s10) {
|
||||
fprintf(cp_out,fmt, s1, s2, s3, s4, s5, s6, s7, s8, s9, s10);
|
||||
}
|
||||
|
||||
#endif /* TCL_MODULE */
|
||||
|
|
|
|||
|
|
@ -1,9 +1,9 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
## $Id$
|
||||
|
||||
noinst_LIBRARIES = libwindisp.a
|
||||
noinst_LTLIBRARIES = libwindisp.la
|
||||
|
||||
libwindisp_a_SOURCES = \
|
||||
libwindisp_la_SOURCES = \
|
||||
windisp.c \
|
||||
windisp.h \
|
||||
winprint.c \
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
## $Id$
|
||||
|
||||
noinst_HEADERS = \
|
||||
tclspice.h \
|
||||
acdefs.h \
|
||||
bdrydefs.h \
|
||||
bool.h \
|
||||
|
|
|
|||
|
|
@ -207,6 +207,21 @@ extern char *Lib_Path;
|
|||
extern int ARCHme; /* My logical process number */
|
||||
extern int ARCHsize; /* Total number of processes */
|
||||
|
||||
#ifdef TCL_MODULE
|
||||
|
||||
#include <errno.h>
|
||||
|
||||
extern int tcl_printf(const char *format, ...);
|
||||
extern int tcl_fprintf(FILE *f, const char *format, ...);
|
||||
|
||||
#undef printf
|
||||
#define printf tcl_printf
|
||||
|
||||
#undef perror
|
||||
#define perror(string) fprintf(stderr,"%s: %s\n",string,sys_errlist[errno])
|
||||
|
||||
#endif
|
||||
|
||||
#ifdef CIDER
|
||||
/* Definitions of globals for Machine Accuracy Limits
|
||||
* Imported from cider
|
||||
|
|
|
|||
|
|
@ -0,0 +1,33 @@
|
|||
/*Include file to allow spice to export certain data */
|
||||
#ifndef TCLSPICE_H
|
||||
#define TCLSPICE_H
|
||||
|
||||
extern int steps_completed;
|
||||
extern void blt_init(void *run);
|
||||
extern void blt_add(int index,double value);
|
||||
extern void blt_relink(int index, void* v);
|
||||
extern void blt_lockvec(int index);
|
||||
|
||||
/* For things to do per loop */
|
||||
int Tcl_ExecutePerLoop();
|
||||
|
||||
/* For tk ploting */
|
||||
extern int sp_Tk_Init(void);
|
||||
#include <graph.h>
|
||||
extern int sp_Tk_NewViewport(GRAPH *graph);
|
||||
extern int sp_Tk_Close(void);
|
||||
extern int sp_Tk_Clear(void);
|
||||
extern int sp_Tk_DrawLine(int x1, int y1, int x2, int y2);
|
||||
extern int sp_Tk_Arc(int x0, int y0, int radius, double theta1, double theta2);
|
||||
extern int sp_Tk_Text(char *text, int x, int y);
|
||||
extern int sp_Tk_DefineColor(int colorid, double red, double green, double blue);
|
||||
extern int sp_Tk_DefineLinestyle(int linestyleid, int mask);
|
||||
extern int sp_Tk_SetLinestyle(int linestyleid);
|
||||
extern int sp_Tk_SetColor(int colorid);
|
||||
extern int sp_Tk_Update(void);
|
||||
|
||||
/* The blt callback method */
|
||||
#include <dvec.h>
|
||||
extern int blt_plot(struct dvec *y,struct dvec *x,int new);
|
||||
|
||||
#endif
|
||||
56
src/main.c
56
src/main.c
|
|
@ -153,7 +153,7 @@ struct variable *(*if_getparam)( );
|
|||
static int started = FALSE;
|
||||
|
||||
/* static functions */
|
||||
static int SIMinit(IFfrontEnd *frontEnd, IFsimulator **simulator);
|
||||
int SIMinit(IFfrontEnd *frontEnd, IFsimulator **simulator);
|
||||
static int sp_shutdown(int exitval);
|
||||
static void app_rl_readlines(void);
|
||||
|
||||
|
|
@ -190,12 +190,37 @@ bool ft_nutmeg = FALSE;
|
|||
extern struct comm spcp_coms[ ];
|
||||
struct comm *cp_coms = spcp_coms;
|
||||
|
||||
|
||||
extern int OUTpBeginPlot(), OUTpData(), OUTwBeginPlot(), OUTwReference();
|
||||
extern int OUTwData(), OUTwEnd(), OUTendPlot(), OUTbeginDomain();
|
||||
extern int OUTendDomain(), OUTstopnow(), OUTerror(), OUTattributes();
|
||||
|
||||
|
||||
|
||||
IFfrontEnd nutmeginfo = {
|
||||
IFnewUid,
|
||||
IFdelUid,
|
||||
OUTstopnow,
|
||||
seconds,
|
||||
OUTerror,
|
||||
OUTpBeginPlot,
|
||||
OUTpData,
|
||||
OUTwBeginPlot,
|
||||
OUTwReference,
|
||||
OUTwData,
|
||||
OUTwEnd,
|
||||
OUTendPlot,
|
||||
OUTbeginDomain,
|
||||
OUTendDomain,
|
||||
OUTattributes
|
||||
};;
|
||||
|
||||
#else /* SIMULATOR */
|
||||
|
||||
bool ft_nutmeg = TRUE;
|
||||
extern struct comm nutcp_coms[ ];
|
||||
struct comm *cp_coms = nutcp_coms;
|
||||
static IFfrontEnd nutmeginfo;
|
||||
IFfrontEnd nutmeginfo;
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
int
|
||||
|
|
@ -320,7 +345,7 @@ IFfrontEnd *SPfrontEnd = NULL;
|
|||
int DEVmaxnum = 0;
|
||||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
static int
|
||||
int
|
||||
SIMinit(IFfrontEnd *frontEnd, IFsimulator **simulator)
|
||||
{
|
||||
#ifdef SIMULATOR
|
||||
|
|
@ -616,11 +641,6 @@ read_initialisation_file(char * dir, char * name)
|
|||
|
||||
/* -------------------------------------------------------------------------- */
|
||||
|
||||
#ifdef SIMULATOR
|
||||
extern int OUTpBeginPlot(), OUTpData(), OUTwBeginPlot(), OUTwReference();
|
||||
extern int OUTwData(), OUTwEnd(), OUTendPlot(), OUTbeginDomain();
|
||||
extern int OUTendDomain(), OUTstopnow(), OUTerror(), OUTattributes();
|
||||
#endif /* SIMULATOR */
|
||||
|
||||
int
|
||||
#ifdef HAS_WINDOWS
|
||||
|
|
@ -639,23 +659,7 @@ main(int argc, char **argv)
|
|||
#ifdef SIMULATOR
|
||||
int error2;
|
||||
|
||||
static IFfrontEnd nutmeginfo = {
|
||||
IFnewUid,
|
||||
IFdelUid,
|
||||
OUTstopnow,
|
||||
seconds,
|
||||
OUTerror,
|
||||
OUTpBeginPlot,
|
||||
OUTpData,
|
||||
OUTwBeginPlot,
|
||||
OUTwReference,
|
||||
OUTwData,
|
||||
OUTwEnd,
|
||||
OUTendPlot,
|
||||
OUTbeginDomain,
|
||||
OUTendDomain,
|
||||
OUTattributes
|
||||
};
|
||||
|
||||
#else /* ~ SIMULATOR */
|
||||
bool gdata = TRUE;
|
||||
#endif /* ~ SIMULATOR */
|
||||
|
|
@ -1116,4 +1120,4 @@ evl:
|
|||
#endif /* ~ SIMULATOR */
|
||||
|
||||
return sp_shutdown(EXIT_NORMAL);
|
||||
}
|
||||
}
|
||||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libcmaths.a
|
||||
noinst_LTLIBRARIES = libcmaths.la
|
||||
|
||||
libcmaths_a_SOURCES = \
|
||||
libcmaths_la_SOURCES = \
|
||||
cmath.h \
|
||||
cmath1.c \
|
||||
cmath1.h \
|
||||
|
|
@ -22,22 +22,25 @@ test_cx_ph_SOURCES = \
|
|||
test_cx_ph.c
|
||||
|
||||
test_cx_ph_LDADD = \
|
||||
libcmaths.a \
|
||||
../../misc/libmisc.a
|
||||
libcmaths.la \
|
||||
../../misc/libmisc.la \
|
||||
$(TCL_LIB_SPEC)
|
||||
|
||||
test_cx_mag_SOURCES = \
|
||||
test_cx_mag.c
|
||||
|
||||
test_cx_mag_LDADD = \
|
||||
libcmaths.a \
|
||||
../../misc/libmisc.a
|
||||
libcmaths.la \
|
||||
../../misc/libmisc.la \
|
||||
$(TCL_LIB_SPEC)
|
||||
|
||||
test_cx_j_SOURCES = \
|
||||
test_cx_j.c
|
||||
|
||||
test_cx_j_LDADD = \
|
||||
libcmaths.a \
|
||||
../../misc/libmisc.a
|
||||
libcmaths.la \
|
||||
../../misc/libmisc.la \
|
||||
$(TCL_LIB_SPEC)
|
||||
|
||||
TESTS = test_cx_mag test_cx_j test_cx_ph
|
||||
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libderiv.a
|
||||
noinst_LTLIBRARIES = libderiv.la
|
||||
|
||||
libderiv_a_SOURCES = \
|
||||
libderiv_la_SOURCES = \
|
||||
atander.c \
|
||||
cosderiv.c \
|
||||
cubeder.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libni.a
|
||||
noinst_LTLIBRARIES = libni.la
|
||||
|
||||
libni_a_SOURCES = \
|
||||
libni_la_SOURCES = \
|
||||
niaciter.c \
|
||||
niaciter.h \
|
||||
nicomcof.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libpoly.a
|
||||
noinst_LTLIBRARIES = libpoly.la
|
||||
|
||||
libpoly_a_SOURCES = \
|
||||
libpoly_la_SOURCES = \
|
||||
interpolate.c \
|
||||
interpolate.h \
|
||||
polyfit.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libsparse.a
|
||||
noinst_LTLIBRARIES = libsparse.la
|
||||
|
||||
libsparse_a_SOURCES = \
|
||||
libsparse_la_SOURCES = \
|
||||
spalloc.c \
|
||||
spbuild.c \
|
||||
spcombin.c \
|
||||
|
|
|
|||
|
|
@ -1,10 +1,10 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
## $Id$
|
||||
|
||||
noinst_LIBRARIES = libmisc.a
|
||||
noinst_LTLIBRARIES = libmisc.la
|
||||
|
||||
|
||||
libmisc_a_SOURCES = \
|
||||
libmisc_la_SOURCES = \
|
||||
getopt1.c \
|
||||
getopt.c \
|
||||
getopt.h \
|
||||
|
|
|
|||
|
|
@ -13,6 +13,11 @@ $Id$
|
|||
#include <stdio.h>
|
||||
#include <memory.h>
|
||||
|
||||
/*saj For Tcl module locking*/
|
||||
#ifdef TCL_MODULE
|
||||
#include <tcl.h>
|
||||
//#include <tclDecls.h>
|
||||
#endif
|
||||
|
||||
/* Malloc num bytes and initialize to zero. Fatal error if the space can't
|
||||
* be tmalloc'd. Return NULL for a request for 0 bytes.
|
||||
|
|
@ -24,9 +29,22 @@ void *
|
|||
tmalloc(size_t num)
|
||||
{
|
||||
void *s;
|
||||
/*saj*/
|
||||
#ifdef TCL_MODULE
|
||||
Tcl_Mutex *alloc;
|
||||
alloc = Tcl_GetAllocMutex();
|
||||
#endif
|
||||
if (!num)
|
||||
return NULL;
|
||||
/*saj*/
|
||||
#ifdef TCL_MODULE
|
||||
Tcl_MutexLock(alloc);
|
||||
#endif
|
||||
s = calloc(num,1);
|
||||
/*saj*/
|
||||
#ifdef TCL_MODULE
|
||||
Tcl_MutexUnlock(alloc);
|
||||
#endif
|
||||
if (!s){
|
||||
fprintf(stderr,"malloc: Internal Error: can't allocate %ld bytes. \n",(long)num);
|
||||
exit(EXIT_BAD);
|
||||
|
|
@ -38,7 +56,11 @@ void *
|
|||
trealloc(void *ptr, size_t num)
|
||||
{
|
||||
void *s;
|
||||
|
||||
/*saj*/
|
||||
#ifdef TCL_MODULE
|
||||
Tcl_Mutex *alloc;
|
||||
alloc = Tcl_GetAllocMutex();
|
||||
#endif
|
||||
if (!num) {
|
||||
if (ptr)
|
||||
free(ptr);
|
||||
|
|
@ -47,9 +69,17 @@ trealloc(void *ptr, size_t num)
|
|||
|
||||
if (!ptr)
|
||||
s = tmalloc(num);
|
||||
else
|
||||
else {
|
||||
/*saj*/
|
||||
#ifdef TCL_MODULE
|
||||
Tcl_MutexLock(alloc);
|
||||
#endif
|
||||
s = realloc(ptr, num);
|
||||
|
||||
/*saj*/
|
||||
#ifdef TCL_MODULE
|
||||
Tcl_MutexUnlock(alloc);
|
||||
#endif
|
||||
}
|
||||
if (!s) {
|
||||
fprintf(stderr,"realloc: Internal Error: can't allocate %ld bytes.\n",(long)num);
|
||||
exit(EXIT_BAD);
|
||||
|
|
@ -111,8 +141,18 @@ trealloc(void *str, size_t num)
|
|||
void
|
||||
txfree(void *ptr)
|
||||
{
|
||||
/*saj*/
|
||||
#ifdef TCL_MODULE
|
||||
Tcl_Mutex *alloc;
|
||||
alloc = Tcl_GetAllocMutex();
|
||||
Tcl_MutexLock(alloc);
|
||||
#endif
|
||||
if (ptr)
|
||||
free(ptr);
|
||||
/*saj*/
|
||||
#ifdef TCL_MODULE
|
||||
Tcl_MutexUnlock(alloc);
|
||||
#endif
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -0,0 +1,122 @@
|
|||
|
||||
proc Loadspice { version dir } {
|
||||
|
||||
package require BLT
|
||||
|
||||
set suffix [info sharedlibextension]
|
||||
|
||||
set library spice${suffix}
|
||||
|
||||
global tcl_platform
|
||||
if { $tcl_platform(platform) == "unix" } {
|
||||
set library [file join $dir lib${library}]
|
||||
}
|
||||
load $library spice
|
||||
|
||||
blt::vector create ::spice::X_Data
|
||||
blt::vector create ::spice::Y_Data
|
||||
|
||||
namespace eval spice {
|
||||
namespace export ac help save alias sens alter altermod iplot setcirc asciiplot jobs setplot aspice setscale bg let settype linearize shell bug listing shift show cdump maxstep showmod compose newhelp noise spec cross oldhelp spice dc op spice_data define spice_header deftype plot state delete plot_datapoints status delta plot_date step plot_get_value stop diff plot_name strcmp display plot_nvars tf disto plot_title dowhile plot_variables tran dump print transpose echo pz tutorial edit quit unalias else rehash undefine end repeat unlet reset fourier reshape version spicetoblt resume where get_output rspice get_param run write goto running xgraph hardcopy rusage steps_completed blt_vnum codemodel halt loadsnap savesnap getplot
|
||||
|
||||
}
|
||||
|
||||
# Callback functions for the plot command
|
||||
# Warning: if any of these functions return an error then
|
||||
# spice will probably segfault as tcl/tk will overflow somewhere
|
||||
# Note: color is actually spelt COLOUR, which looks much better
|
||||
# Note: they don't work in namespace so have to make global
|
||||
|
||||
proc spice_gr_NewViewport { } {
|
||||
set width 1000
|
||||
set height 400
|
||||
set fontwidth 12
|
||||
set fontheight 24
|
||||
canvas .c -width $width -height $height -background white
|
||||
pack .c
|
||||
return "$width $height $fontwidth $fontheight"
|
||||
}
|
||||
proc spice_gr_Close { } {
|
||||
}
|
||||
proc spice_gr_Clear { } {
|
||||
}
|
||||
proc spice_gr_DrawLine { x1 y1 x2 y2 } {
|
||||
puts "draw"
|
||||
.c create line [expr $x1 + 25] [expr 375 - $y1] [expr $x2 + 25] [expr 375 - $y2]
|
||||
}
|
||||
proc spice_gr_Arc { x0 y0 radius theta1 theta2 } {
|
||||
.c create arc [expr $x0 - $radius + 25] [expr 375 - $y0 - $radius] \
|
||||
[expr $x1 + $radius + 25 ] [expr 375 - $y1 + $radius] \
|
||||
-start $theta1 -extent $theta2
|
||||
}
|
||||
proc spice_gr_Text {text x y} {
|
||||
.c create text [expr $x + 25] [expr 375 - $y] -text $text
|
||||
}
|
||||
|
||||
proc spice_gr_SetLinestyle {linestyleid} {
|
||||
puts "SetLinestyle $linestyleid"
|
||||
}
|
||||
proc spice_gr_SetColor {colorid } {
|
||||
puts "SetColor $colorid $color"
|
||||
}
|
||||
|
||||
proc spice_gr_Update { } {
|
||||
}
|
||||
|
||||
|
||||
# These seem to never be called /*
|
||||
proc spice_gr_DefineColor {colorid red green blue} {
|
||||
puts "DefineColor $colorid $red $green $blue"
|
||||
}
|
||||
proc spice_gr_DefineLinestyle {linestyleid mask} {
|
||||
puts "DefineLinestyle $linestyleid $mask"
|
||||
}
|
||||
|
||||
proc spice_init_gui { fileName {gui 0} {batchMode 0} {rawFileName ""}} {
|
||||
|
||||
# source tclcode
|
||||
if {[info procs spicewish::plot] == ""} {
|
||||
source [file join $::spice_library "spice/spicewish.tcl"]
|
||||
}
|
||||
|
||||
if {!$batchMode} { spice::version }
|
||||
|
||||
if {$fileName != ""} {
|
||||
|
||||
switch [file extension $fileName] {
|
||||
".tcl" {
|
||||
source $fileName
|
||||
}
|
||||
".raw" {
|
||||
spice::load $fileName
|
||||
}
|
||||
default {
|
||||
spice::source $fileName
|
||||
|
||||
if {$batchMode} {
|
||||
spice::run
|
||||
if {$rawFileName != ""} {
|
||||
spice::set filetype=binary
|
||||
spice::write $rawFileName
|
||||
}
|
||||
exit
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if {$gui == 1} { spicewish::gui }
|
||||
wm withdraw .
|
||||
}
|
||||
|
||||
set ::spice_version $version
|
||||
set ::spice_library $dir
|
||||
}
|
||||
|
||||
proc q { } { exit }
|
||||
|
||||
|
||||
set version "%VERSION%"
|
||||
set libdir "%LIB_DIR%"
|
||||
|
||||
package ifneeded spice $version [list Loadspice $version $libdir]
|
||||
|
||||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libckt.a
|
||||
noinst_LTLIBRARIES = libckt.la
|
||||
|
||||
libckt_a_SOURCES = \
|
||||
libckt_la_SOURCES = \
|
||||
acan.c \
|
||||
acaskq.c \
|
||||
acsetp.c \
|
||||
|
|
|
|||
|
|
@ -117,9 +117,9 @@ DIST_SUBDIRS = \
|
|||
numos
|
||||
|
||||
|
||||
noinst_LIBRARIES = libdev.a
|
||||
noinst_LTLIBRARIES = libdev.la
|
||||
|
||||
libdev_a_SOURCES = \
|
||||
libdev_la_SOURCES = \
|
||||
dev.c \
|
||||
dev.h \
|
||||
devsup.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libasrc.a
|
||||
noinst_LTLIBRARIES = libasrc.la
|
||||
|
||||
libasrc_a_SOURCES = \
|
||||
libasrc_la_SOURCES = \
|
||||
asrc.c \
|
||||
asrcacld.c \
|
||||
asrcask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbjt.a
|
||||
noinst_LTLIBRARIES = libbjt.la
|
||||
|
||||
libbjt_a_SOURCES = \
|
||||
libbjt_la_SOURCES = \
|
||||
bjt.c \
|
||||
bjtacld.c \
|
||||
bjtask.c \
|
||||
|
|
|
|||
|
|
@ -4,9 +4,9 @@
|
|||
## work.
|
||||
## Sensitivity analysis not compiled in.
|
||||
|
||||
noinst_LIBRARIES = libbjt2.a
|
||||
noinst_LTLIBRARIES = libbjt2.la
|
||||
|
||||
libbjt2_a_SOURCES = \
|
||||
libbjt2_la_SOURCES = \
|
||||
bjt2.c \
|
||||
bjt2acld.c \
|
||||
bjt2ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim1.a
|
||||
noinst_LTLIBRARIES = libbsim1.la
|
||||
|
||||
libbsim1_a_SOURCES = \
|
||||
libbsim1_la_SOURCES = \
|
||||
b1.c \
|
||||
b1acld.c \
|
||||
b1ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim2.a
|
||||
noinst_LTLIBRARIES = libbsim2.la
|
||||
|
||||
libbsim2_a_SOURCES = \
|
||||
libbsim2_la_SOURCES = \
|
||||
b2.c \
|
||||
b2acld.c \
|
||||
b2ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim3.a
|
||||
noinst_LTLIBRARIES = libbsim3.la
|
||||
|
||||
libbsim3_a_SOURCES = \
|
||||
libbsim3_la_SOURCES = \
|
||||
b3.c \
|
||||
b3acld.c \
|
||||
b3ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim3soi.a
|
||||
noinst_LTLIBRARIES = libbsim3soi.la
|
||||
|
||||
libbsim3soi_a_SOURCES = \
|
||||
libbsim3soi_la_SOURCES = \
|
||||
b4soi.c \
|
||||
b4soiacld.c \
|
||||
b4soiask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim3soidd.a
|
||||
noinst_LTLIBRARIES = libbsim3soidd.la
|
||||
|
||||
libbsim3soidd_a_SOURCES = \
|
||||
libbsim3soidd_la_SOURCES = \
|
||||
b3soidd.c \
|
||||
b3soiddacld.c \
|
||||
b3soiddask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim3soifd.a
|
||||
noinst_LTLIBRARIES = libbsim3soifd.la
|
||||
|
||||
libbsim3soifd_a_SOURCES = \
|
||||
libbsim3soifd_la_SOURCES = \
|
||||
b3soifd.c \
|
||||
b3soifdacld.c \
|
||||
b3soifdask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim3soipd.a
|
||||
noinst_LTLIBRARIES = libbsim3soipd.la
|
||||
|
||||
libbsim3soipd_a_SOURCES = \
|
||||
libbsim3soipd_la_SOURCES = \
|
||||
b3soipd.c \
|
||||
b3soipdacld.c \
|
||||
b3soipdask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim3v0.a
|
||||
noinst_LTLIBRARIES = libbsim3v0.la
|
||||
|
||||
libbsim3v0_a_SOURCES = \
|
||||
libbsim3v0_la_SOURCES = \
|
||||
b3v0.c \
|
||||
b3v0acld.c \
|
||||
b3v0ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim3v1.a
|
||||
noinst_LTLIBRARIES = libbsim3v1.la
|
||||
|
||||
libbsim3v1_a_SOURCES = \
|
||||
libbsim3v1_la_SOURCES = \
|
||||
b3v1.c \
|
||||
b3v1acld.c \
|
||||
b3v1ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim3v1a.a
|
||||
noinst_LTLIBRARIES = libbsim3v1a.la
|
||||
|
||||
libbsim3v1a_a_SOURCES = \
|
||||
libbsim3v1a_la_SOURCES = \
|
||||
b3v1a.c \
|
||||
b3v1aacld.c \
|
||||
b3v1aask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim3v1s.a
|
||||
noinst_LTLIBRARIES = libbsim3v1s.la
|
||||
|
||||
libbsim3v1s_a_SOURCES = \
|
||||
libbsim3v1s_la_SOURCES = \
|
||||
b3v1s.c \
|
||||
b3v1sacld.c \
|
||||
b3v1sask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim3v32.a
|
||||
noinst_LTLIBRARIES = libbsim3v32.la
|
||||
|
||||
libbsim3v32_a_SOURCES = \
|
||||
libbsim3v32_la_SOURCES = \
|
||||
b3v32.c \
|
||||
b3v32acld.c \
|
||||
b3v32ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim4.a
|
||||
noinst_LTLIBRARIES = libbsim4.la
|
||||
|
||||
libbsim4_a_SOURCES = \
|
||||
libbsim4_la_SOURCES = \
|
||||
b4.c \
|
||||
b4acld.c \
|
||||
b4ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim4v2.a
|
||||
noinst_LTLIBRARIES = libbsim4v2.la
|
||||
|
||||
libbsim4v2_a_SOURCES = \
|
||||
libbsim4v2_la_SOURCES = \
|
||||
b4v2.c \
|
||||
b4v2acld.c \
|
||||
b4v2ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim4v3.a
|
||||
noinst_LTLIBRARIES = libbsim4v3.la
|
||||
|
||||
libbsim4v3_a_SOURCES = \
|
||||
libbsim4v3_la_SOURCES = \
|
||||
b4v3.c \
|
||||
b4v3acld.c \
|
||||
b4v3ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim4v4.a
|
||||
noinst_LTLIBRARIES = libbsim4v4.la
|
||||
|
||||
libbsim4v4_a_SOURCES = \
|
||||
libbsim4v4_la_SOURCES = \
|
||||
b4v4.c \
|
||||
b4v4acld.c \
|
||||
b4v4ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libbsim4v5.a
|
||||
noinst_LTLIBRARIES = libbsim4v5.la
|
||||
|
||||
libbsim4v5_a_SOURCES = \
|
||||
libbsim4v5_la_SOURCES = \
|
||||
b4v5.c \
|
||||
b4v5acld.c \
|
||||
b4v5ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libcap.a
|
||||
noinst_LTLIBRARIES = libcap.la
|
||||
|
||||
libcap_a_SOURCES = \
|
||||
libcap_la_SOURCES = \
|
||||
cap.c \
|
||||
capacld.c \
|
||||
capask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libcccs.a
|
||||
noinst_LTLIBRARIES = libcccs.la
|
||||
|
||||
libcccs_a_SOURCES = \
|
||||
libcccs_la_SOURCES = \
|
||||
cccs.c \
|
||||
cccsask.c \
|
||||
cccsdefs.h \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libccvs.a
|
||||
noinst_LTLIBRARIES = libccvs.la
|
||||
|
||||
libccvs_a_SOURCES = \
|
||||
libccvs_la_SOURCES = \
|
||||
ccvs.c \
|
||||
ccvsask.c \
|
||||
ccvsdefs.h \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libcpl.a
|
||||
noinst_LTLIBRARIES = libcpl.la
|
||||
|
||||
libcpl_a_SOURCES = \
|
||||
libcpl_la_SOURCES = \
|
||||
cpl.c \
|
||||
cplask.c \
|
||||
cpldefs.h \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libcsw.a
|
||||
noinst_LTLIBRARIES = libcsw.la
|
||||
|
||||
libcsw_a_SOURCES = \
|
||||
libcsw_la_SOURCES = \
|
||||
csw.c \
|
||||
cswacld.c \
|
||||
cswask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libdio.a
|
||||
noinst_LTLIBRARIES = libdio.la
|
||||
|
||||
libdio_a_SOURCES = \
|
||||
libdio_la_SOURCES = \
|
||||
dio.c \
|
||||
dioacld.c \
|
||||
dioask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libhfet.a
|
||||
noinst_LTLIBRARIES = libhfet.la
|
||||
|
||||
libhfet_a_SOURCES = \
|
||||
libhfet_la_SOURCES = \
|
||||
hfet.c \
|
||||
hfetacl.c \
|
||||
hfetask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libhfet2.a
|
||||
noinst_LTLIBRARIES = libhfet2.la
|
||||
|
||||
libhfet2_a_SOURCES = \
|
||||
libhfet2_la_SOURCES = \
|
||||
hfet2.c \
|
||||
hfet2acl.c \
|
||||
hfet2ask.c \
|
||||
|
|
|
|||
|
|
@ -2,9 +2,9 @@
|
|||
|
||||
EXTRA_DIST = hsm1eval1_0.c hsm1eval1_1.c
|
||||
|
||||
noinst_LIBRARIES = libhisim.a
|
||||
noinst_LTLIBRARIES = libhisim.la
|
||||
|
||||
libhisim_a_SOURCES = hisim.h \
|
||||
libhisim_la_SOURCES = hisim.h \
|
||||
hsm1.c \
|
||||
hsm1acld.c \
|
||||
hsm1ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libind.a
|
||||
noinst_LTLIBRARIES = libind.la
|
||||
|
||||
libind_a_SOURCES = \
|
||||
libind_la_SOURCES = \
|
||||
ind.c \
|
||||
indacld.c \
|
||||
indask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libisrc.a
|
||||
noinst_LTLIBRARIES = libisrc.la
|
||||
|
||||
libisrc_a_SOURCES = \
|
||||
libisrc_la_SOURCES = \
|
||||
isrc.c \
|
||||
isrcacct.c \
|
||||
isrcacld.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libjfet.a
|
||||
noinst_LTLIBRARIES = libjfet.la
|
||||
|
||||
libjfet_a_SOURCES = \
|
||||
libjfet_la_SOURCES = \
|
||||
jfet.c \
|
||||
jfetacld.c \
|
||||
jfetask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libjfet2.a
|
||||
noinst_LTLIBRARIES = libjfet2.la
|
||||
|
||||
libjfet2_a_SOURCES = \
|
||||
libjfet2_la_SOURCES = \
|
||||
jfet2.c \
|
||||
jfet2acld.c \
|
||||
jfet2ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libltra.a
|
||||
noinst_LTLIBRARIES = libltra.la
|
||||
|
||||
libltra_a_SOURCES = \
|
||||
libltra_la_SOURCES = \
|
||||
ltra.c \
|
||||
ltraacct.c \
|
||||
ltraacld.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libmes.a
|
||||
noinst_LTLIBRARIES = libmes.la
|
||||
|
||||
libmes_a_SOURCES = \
|
||||
libmes_la_SOURCES = \
|
||||
mes.c \
|
||||
mesacl.c \
|
||||
mesask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libmesa.a
|
||||
noinst_LTLIBRARIES = libmesa.la
|
||||
|
||||
libmesa_a_SOURCES = \
|
||||
libmesa_la_SOURCES = \
|
||||
mesa.c \
|
||||
mesaacl.c \
|
||||
mesaask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libmos1.a
|
||||
noinst_LTLIBRARIES = libmos1.la
|
||||
|
||||
libmos1_a_SOURCES = \
|
||||
libmos1_la_SOURCES = \
|
||||
mos1.c \
|
||||
mos1acld.c \
|
||||
mos1ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libmos2.a
|
||||
noinst_LTLIBRARIES = libmos2.la
|
||||
|
||||
libmos2_a_SOURCES = \
|
||||
libmos2_la_SOURCES = \
|
||||
mos2.c \
|
||||
mos2acld.c \
|
||||
mos2ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libmos3.a
|
||||
noinst_LTLIBRARIES = libmos3.la
|
||||
|
||||
libmos3_a_SOURCES = \
|
||||
libmos3_la_SOURCES = \
|
||||
mos3.c \
|
||||
mos3acld.c \
|
||||
mos3ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libmos6.a
|
||||
noinst_LTLIBRARIES = libmos6.la
|
||||
|
||||
libmos6_a_SOURCES = \
|
||||
libmos6_la_SOURCES = \
|
||||
mos6.c \
|
||||
mos6ask.c \
|
||||
mos6conv.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libmos9.a
|
||||
noinst_LTLIBRARIES = libmos9.la
|
||||
|
||||
libmos9_a_SOURCES = \
|
||||
libmos9_la_SOURCES = \
|
||||
mos9.c \
|
||||
mos9acld.c \
|
||||
mos9ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libnbjt.a
|
||||
noinst_LTLIBRARIES = libnbjt.la
|
||||
|
||||
libnbjt_a_SOURCES = \
|
||||
libnbjt_la_SOURCES = \
|
||||
nbjt.c \
|
||||
nbjtacld.c \
|
||||
nbjtask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libnbjt2.a
|
||||
noinst_LTLIBRARIES = libnbjt2.la
|
||||
|
||||
libnbjt2_a_SOURCES = \
|
||||
libnbjt2_la_SOURCES = \
|
||||
nbt2.c \
|
||||
nbt2acld.c \
|
||||
nbt2ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libndev.a
|
||||
noinst_LTLIBRARIES = libndev.la
|
||||
|
||||
libndev_a_SOURCES = \
|
||||
libndev_la_SOURCES = \
|
||||
ndev.c \
|
||||
ndevacld.c \
|
||||
ndevaccept.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libnumd.a
|
||||
noinst_LTLIBRARIES = libnumd.la
|
||||
|
||||
libnumd_a_SOURCES = \
|
||||
libnumd_la_SOURCES = \
|
||||
numd.c \
|
||||
numdacld.c \
|
||||
numdask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libnumd2.a
|
||||
noinst_LTLIBRARIES = libnumd2.la
|
||||
|
||||
libnumd2_a_SOURCES = \
|
||||
libnumd2_la_SOURCES = \
|
||||
nud2.c \
|
||||
nud2acld.c \
|
||||
nud2ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libnumos.a
|
||||
noinst_LTLIBRARIES = libnumos.la
|
||||
|
||||
libnumos_a_SOURCES = \
|
||||
libnumos_la_SOURCES = \
|
||||
numm.c \
|
||||
nummacld.c \
|
||||
nummask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libres.a
|
||||
noinst_LTLIBRARIES = libres.la
|
||||
|
||||
libres_a_SOURCES = \
|
||||
libres_la_SOURCES = \
|
||||
res.c \
|
||||
resask.c \
|
||||
resdefs.h \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libsoi3.a
|
||||
noinst_LTLIBRARIES = libsoi3.la
|
||||
|
||||
libsoi3_a_SOURCES = \
|
||||
libsoi3_la_SOURCES = \
|
||||
soi3.c \
|
||||
soi3acld.c \
|
||||
soi3ask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libsw.a
|
||||
noinst_LTLIBRARIES = libsw.la
|
||||
|
||||
libsw_a_SOURCES = \
|
||||
libsw_la_SOURCES = \
|
||||
sw.c \
|
||||
swacload.c \
|
||||
swask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libtra.a
|
||||
noinst_LTLIBRARIES = libtra.la
|
||||
|
||||
libtra_a_SOURCES = \
|
||||
libtra_la_SOURCES = \
|
||||
tra.c \
|
||||
traacct.c \
|
||||
traacld.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libtxl.a
|
||||
noinst_LTLIBRARIES = libtxl.la
|
||||
|
||||
libtxl_a_SOURCES = \
|
||||
libtxl_la_SOURCES = \
|
||||
txl.c \
|
||||
txlacct.c \
|
||||
txlask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = liburc.a
|
||||
noinst_LTLIBRARIES = liburc.la
|
||||
|
||||
liburc_a_SOURCES = \
|
||||
liburc_la_SOURCES = \
|
||||
urc.c \
|
||||
urcask.c \
|
||||
urcdefs.h \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libvbic.a
|
||||
noinst_LTLIBRARIES = libvbic.la
|
||||
|
||||
libvbic_a_SOURCES = \
|
||||
libvbic_la_SOURCES = \
|
||||
vbic.c \
|
||||
vbicacld.c \
|
||||
vbicask.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libvccs.a
|
||||
noinst_LTLIBRARIES = libvccs.la
|
||||
|
||||
libvccs_a_SOURCES = \
|
||||
libvccs_la_SOURCES = \
|
||||
vccs.c \
|
||||
vccsask.c \
|
||||
vccsdefs.h \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libvcvs.a
|
||||
noinst_LTLIBRARIES = libvcvs.la
|
||||
|
||||
libvcvs_a_SOURCES = \
|
||||
libvcvs_la_SOURCES = \
|
||||
vcvs.c \
|
||||
vcvsask.c \
|
||||
vcvsdefs.h \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libvsrc.a
|
||||
noinst_LTLIBRARIES = libvsrc.la
|
||||
|
||||
libvsrc_a_SOURCES = \
|
||||
libvsrc_la_SOURCES = \
|
||||
vsrc.c \
|
||||
vsrcacct.c \
|
||||
vsrcacld.c \
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
## Process this file with automake to produce Makefile.in
|
||||
|
||||
noinst_LIBRARIES = libinp.a
|
||||
noinst_LTLIBRARIES = libinp.la
|
||||
|
||||
libinp_a_SOURCES = \
|
||||
libinp_la_SOURCES = \
|
||||
ifeval.c \
|
||||
ifnewuid.c \
|
||||
inp2b.c \
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -0,0 +1,5 @@
|
|||
TCLSPICE_0.2
|
||||
{
|
||||
global: Spice_Init;
|
||||
local: *;
|
||||
};
|
||||
|
|
@ -2,9 +2,9 @@
|
|||
#
|
||||
# JW 3/9/01 - had a go and makeing an autoconf script.
|
||||
|
||||
noinst_LIBRARIES = libcmxsp.a
|
||||
noinst_LTLIBRARIES = libcmxsp.la
|
||||
|
||||
libcmxsp_a_SOURCES = \
|
||||
libcmxsp_la_SOURCES = \
|
||||
cm.c \
|
||||
cmevt.c \
|
||||
cmmeters.c \
|
||||
|
|
|
|||
|
|
@ -2,9 +2,9 @@
|
|||
#
|
||||
# JW 3/9/01 - had a go and makeing an autoconf script.
|
||||
|
||||
noinst_LIBRARIES = libenhxsp.a
|
||||
noinst_LTLIBRARIES = libenhxsp.la
|
||||
|
||||
libenhxsp_a_SOURCES = \
|
||||
libenhxsp_la_SOURCES = \
|
||||
enh.c \
|
||||
enhtrans.c
|
||||
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue