Enable compiling with --enable-sp for RF SPICE

Set preprocessor flag RFSPICE
Add new files and directory 'dense' ('dense' is still buggy)
This commit is contained in:
Holger Vogt 2022-01-08 18:07:53 +01:00
parent 5b8ed0a84e
commit 3b0eb41c74
6 changed files with 39 additions and 5 deletions

View File

@ -52,14 +52,14 @@ if test "$1" = "d"; then
echo "configuring for 64 bit debug"
echo
# You may add --enable-adms to the following command for adding adms generated devices
../configure --with-x --enable-xspice --enable-cider --with-readline=yes --enable-openmp CFLAGS="-g -m64 -O0 -Wall -Wno-unused-but-set-variable" LDFLAGS="-m64 -g"
../configure --with-x --enable-xspice --enable-cider --with-readline=yes --enable-openmp --enable-sp CFLAGS="-g -m64 -O0 -Wall -Wno-unused-but-set-variable" LDFLAGS="-m64 -g"
else
cd release
if [ $? -ne 0 ]; then echo "cd release failed"; exit 1 ; fi
echo "configuring for 64 bit release"
echo
# You may add --enable-adms to the following command for adding adms generated devices
../configure --with-x --enable-xspice --enable-cider --with-readline=yes --enable-openmp --disable-debug CFLAGS="-m64 -O2" LDFLAGS="-m64 -s"
../configure --with-x --enable-xspice --enable-cider --with-readline=yes --enable-openmp --enable-sp --disable-debug CFLAGS="-m64 -O2" LDFLAGS="-m64 -s"
fi
if [ $? -ne 0 ]; then echo "../configure failed"; exit 1 ; fi

View File

@ -53,14 +53,14 @@ if test "$1" = "d"; then
echo "configuring for 64 bit debug"
echo
# You may add --enable-adms to the following command for adding adms generated devices
../configure --with-wingui --enable-xspice --enable-cider --enable-openmp prefix="C:/Spice64d" CFLAGS="-g -m64 -O0 -Wall -Wno-unused-but-set-variable" LDFLAGS="-g -m64"
../configure --with-wingui --enable-xspice --enable-cider --enable-openmp --enable-sp prefix="C:/Spice64d" CFLAGS="-g -m64 -O0 -Wall -Wno-unused-but-set-variable" LDFLAGS="-g -m64"
else
cd release
if [ $? -ne 0 ]; then echo "cd release failed"; exit 1 ; fi
echo "configuring for 64 bit release"
echo
# You may add --enable-adms to the following command for adding adms generated devices
../configure --with-wingui --enable-xspice --enable-cider --enable-openmp --disable-debug prefix="C:/Spice64" CFLAGS="-m64 -O2" LDFLAGS="-m64 -s"
../configure --with-wingui --enable-xspice --enable-cider --enable-openmp --enable-sp --disable-debug prefix="C:/Spice64" CFLAGS="-m64 -O2" LDFLAGS="-m64 -s"
fi
if [ $? -ne 0 ]; then echo "../configure failed"; exit 1 ; fi

View File

@ -158,6 +158,10 @@ AC_ARG_ENABLE([adms],
AC_ARG_ENABLE([pss],
[AS_HELP_STRING([--enable-pss], [Enable PSS Analysis, (experimental)])])
# --enable-sp: enable S Parameter Analysis
AC_ARG_ENABLE([sp],
[AS_HELP_STRING([--enable-sp], [Enable S parameter Analysis])])
# --enable-relpath: Relative path for binary and data. Default is "no".
# ngspice shared may want relative paths for spinit etc.
AC_ARG_ENABLE([relpath],
@ -1161,12 +1165,20 @@ if test "x$enable_cider" = xyes; then
AC_DEFINE([CIDER], [1], [The CIDER enhancements])
fi
# Add S parameter analysis to ngspice.
if test "x$enable_sp" = xyes; then
AC_MSG_RESULT([S parameter analysis enabled])
AC_DEFINE([RFSPICE], [1], [S parameter analysis])
fi
AM_CONDITIONAL([CIDER_WANTED], [test "x$enable_cider" = xyes])
AM_CONDITIONAL([NUMDEV_WANTED], [test "x$enable_cider" = xyes])
AM_CONDITIONAL([PSS_WANTED], [test "x$enable_pss" = xyes])
AM_CONDITIONAL([SP_WANTED], [test "x$enable_sp" = xyes])
AM_CONDITIONAL([SENSE2_WANTED], [test "x$enable_sense2" = xyes])
# adms option

View File

@ -185,6 +185,11 @@ ngspice_LDADD += \
maths/sparse/libsparse.la \
misc/libmisc.la
if SP_WANTED
ngspice_LDADD += \
maths/dense/libdense.la
endif
if !WINGUI
if !NO_X
ngspice_LDADD += frontend/help/libhlp.la
@ -463,6 +468,11 @@ libspice_la_LIBADD += \
misc/libmisc.la \
$(LIBS)
if SP_WANTED
libspice_la_LIBADD += \
maths/dense/libdense.la
endif
libspice_la_CFLAGS = -shared
libspice_la_LDFLAGS = -shared -Wl,--version-script=$(srcdir)/tclspice.map
if TCLWIN

View File

@ -1,6 +1,10 @@
## Process this file with automake
SUBDIRS = cmaths ni sparse poly deriv misc fft
DIST_SUBDIRS = cmaths ni sparse poly deriv misc fft
DIST_SUBDIRS = cmaths ni sparse poly deriv misc fft dense
if SP_WANTED
SUBDIRS += dense
endif
MAINTAINERCLEANFILES = Makefile.in

View File

@ -108,6 +108,14 @@ libckt_la_SOURCES += \
psssetp.c
endif
if SP_WANTED
libckt_la_SOURCES += \
cktspdum.c \
span.c \
spaskq.c \
spsetp.c
endif
AM_CPPFLAGS = @AM_CPPFLAGS@ -I$(top_srcdir)/src/include -I$(top_srcdir)/src/spicelib/devices
AM_CFLAGS = $(STATIC)