From ccdf09a21255d154bf88b5f57266d096b999c98f Mon Sep 17 00:00:00 2001 From: pnenzi Date: Mon, 1 Sep 2008 21:10:18 +0000 Subject: [PATCH] capzerobypass enabled by default --- ChangeLog | 4 + configure.in | 245 +++++++++++++++++++++++++++------------------------ 2 files changed, 134 insertions(+), 115 deletions(-) diff --git a/ChangeLog b/ChangeLog index a7ad1d66e..34969b763 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2008-09-01 + * configure.in: CAPZEROBYPASS is enabled by default now. To disable it you + can add --disable-capzerobypass to configure command. + 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 diff --git a/configure.in b/configure.in index 451fd305d..bf23c1a79 100644 --- a/configure.in +++ b/configure.in @@ -62,9 +62,21 @@ dnl --enable-capbypass: define CAPBYPASS for the code AC_ARG_ENABLE(capbypass, AS_HELP_STRING([--enable-capbypass],[Bypass calculation of cbd/cbs in the mosfets if the vbs/vbd voltages are unchanged])) -dnl --enable-capzerobypass: define CAPZEROBYPASS for the code AC_ARG_ENABLE(capzerobypass, - AS_HELP_STRING([--enable-capzerobypass],[Bypass all the cbd/cbs calculations if Czero is zero])) + AS_HELP_STRING([--enable-capzerobypass],[Bypass all the cbd/cbs calculations if Czero is zero. (default=enabled)]), + [],[enable_capzerobypass=yes]) + + +dnl if test x"$enable_capzerobypass" = "xyes" +dnl then AC_MSG_RESULT([yes]) +dnl AC_DEFINE(CAPZEROBYPASS, 1, [Use capzerobypass.]) +dnl else +dnl AC_MSG_RESULT([not yet]) +dnl AC_DEFINE(CAPZEROBYPASS, 0, [Use capzerobypass.]) + dnl fi + dnl ]) + +MY_ARG_ENABLE_CAPZEROBYPASS dnl --enable-nodelimiting: define NODELIMITING for the code AC_ARG_ENABLE(nodelimiting, @@ -285,6 +297,122 @@ case $with_windows in CFLAGS="$CFLAGS -mwindows";; * ) + +dnl Check for /proc (virtual process information file system) +AC_CHECK_HEADERS( /proc/meminfo) + +dnl Checks for X11 header files and libraries - X11 support can be disabled +dnl by passing the '--without-x' option to configure: + +dnl Try to locate the X-Windows include files and libraries +AC_PATH_X +AC_PATH_XTRA + +# Checks for typedefs, structures, and compiler characteristics. +AC_HEADER_STDBOOL +AC_TYPE_SIZE_T + +# Checks for library functions. +AC_FUNC_ALLOCA +AC_FUNC_MALLOC +AC_FUNC_REALLOC +AC_FUNC_CLOSEDIR_VOID +AC_FUNC_SELECT_ARGTYPES +AC_FUNC_SETVBUF_REVERSED +AC_FUNC_VPRINTF + +dnl Check if the user wants to use the appropriate rpath commands to compile in +dnl the shared library path for the X libraries. This is off by default since +dnl that is how it has been historically. Using --enable-rpath will turn this on + +_use_rpath=no +AC_MSG_CHECKING([if hardcoding of the X11 runtime library path is desired]) +AC_ARG_ENABLE([rpath], + [ --enable-rpath Enable hardcoding the X11 runtime library path [default=disabled]], + [ + if test "X$enable_rpath" = "Xno" ; then + AC_MSG_RESULT([no]) + _use_rpath=no + else + AC_MSG_RESULT([yes]) + _use_rpath=yes + fi + ], + [ + AC_MSG_RESULT([no]) + _use_rpath=no + ] +) + +if test "X$_use_rpath" = "Xyes" ; then + # Try to figure out if we need -Rpath for finding X11 libs + # at runtime. Why autoconf doesn't already do this, I don't + # know... + xlib_path="" + for p in $X_LDFLAGS ; do + case $p in + -L*) + xlib_path="$xlib_path $p" + ;; + esac + done + + _save_LIBS=$LIBS + LIBS="$LIBS $X_LDFLAGS" + rpath="" + for fl in "-Wl,-rpath " "-Wl,--rpath " "-rpath " "--rpath " "-Wl,-R" "-R" "-R " ; do + xlib_rpath=`echo $xlib_path | sed "s/-L/$fl/g"` + LIBS="$_save_LIBS $X_LIBS $xlib_rpath" + AC_MSG_CHECKING([if the compiler accepts ${fl}path for runtime libraries]) + AC_LINK_IFELSE([AC_LANG_PROGRAM()], + AC_MSG_RESULT([yes]) + rpath=$fl, + AC_MSG_RESULT([no])) + test -n "$rpath" && break + done + if test -n "$rpath"; then + X_LDFLAGS="$X_LDFLAGS $xlib_rpath" + fi + LIBS=$_save_LIBS +fi + +dnl Checks for X libraries - if X11 wasn't found then don't make following +dnl tests and compile without X11 support - otherwise, check if the following +dnl libraries are present (error if they are not) +dnl In CYGWIN library ordering has to be changed. Is this compatible to LINUX? +dnl XShmAttach is a struct in CYGWIN, not a function +dnl SJB: 13th march 2005 +dnl Library order is giving linker warnings on MacOSX +dnl It's not clear to me which order is required for Cygwin (see comment above) +dnl and neither can I find any authoritative answer for the correct link order +dnl for MacOSX or Linux, but +dnl -lXaw -lXmu -lXt -lXext -lX11 +dnl seems to be the popular choice. +dnl (The previous order was -lX11 -lXt -lXext -lXmu -lXaw) +if test "x$enable_x" = "xno"; then + no_x = "no" +fi +if test ! "$no_x" = "yes" ; then + AC_CHECK_LIB(Xaw,main,X_LIBS="$X_LIBS -lXaw",AC_MSG_ERROR(Couldn't find Xaw library),$X_LIBS $X_EXTRA_LIBS) + AC_CHECK_LIB(Xmu,main,X_LIBS="$X_LIBS -lXmu",AC_MSG_ERROR(Couldn't find Xmu library), $X_LIBS $X_EXTRA_LIBS) + X_LIBS="$X_LIBS -lXt" + AC_CHECK_LIB(Xext, XShmAttach,X_LIBS="$X_LIBS -lXext",AC_MSG_ERROR(Couldn't find Xext library), $X_LIBS $X_EXTRA_LIBS) + X_LIBS="$X_LIBS -lX11" + AM_CONDITIONAL(NO_X, false) +else + AC_DEFINE(X_DISPLAY_MISSING) + AC_MSG_RESULT(No X display!) + AM_CONDITIONAL(NO_X, true) +fi + +if ( test "x$enable_help" = "xyes" ) && ! ( test "$no_x" = "yes" ) ; then + AM_CONDITIONAL(NO_HELP, false) +else + AM_CONDITIONAL(NO_HELP, true) +fi ;; + +esac + ########################################################################## # # tcl libraries test @@ -412,120 +540,7 @@ AC_SUBST(TCL_LIB_SPEC) # ################################################################# -dnl Check for /proc (virtual process information file system) -AC_CHECK_HEADERS( /proc/meminfo) -dnl Checks for X11 header files and libraries - X11 support can be disabled -dnl by passing the '--without-x' option to configure: - -dnl Try to locate the X-Windows include files and libraries -AC_PATH_X -AC_PATH_XTRA - -# Checks for typedefs, structures, and compiler characteristics. -AC_HEADER_STDBOOL -AC_TYPE_SIZE_T - -# Checks for library functions. -AC_FUNC_ALLOCA -AC_FUNC_MALLOC -AC_FUNC_REALLOC -AC_FUNC_CLOSEDIR_VOID -AC_FUNC_SELECT_ARGTYPES -AC_FUNC_SETVBUF_REVERSED -AC_FUNC_VPRINTF - -dnl Check if the user wants to use the appropriate rpath commands to compile in -dnl the shared library path for the X libraries. This is off by default since -dnl that is how it has been historically. Using --enable-rpath will turn this on - -_use_rpath=no -AC_MSG_CHECKING([if hardcoding of the X11 runtime library path is desired]) -AC_ARG_ENABLE([rpath], - [ --enable-rpath Enable hardcoding the X11 runtime library path [default=disabled]], - [ - if test "X$enable_rpath" = "Xno" ; then - AC_MSG_RESULT([no]) - _use_rpath=no - else - AC_MSG_RESULT([yes]) - _use_rpath=yes - fi - ], - [ - AC_MSG_RESULT([no]) - _use_rpath=no - ] -) - -if test "X$_use_rpath" = "Xyes" ; then - # Try to figure out if we need -Rpath for finding X11 libs - # at runtime. Why autoconf doesn't already do this, I don't - # know... - xlib_path="" - for p in $X_LDFLAGS ; do - case $p in - -L*) - xlib_path="$xlib_path $p" - ;; - esac - done - - _save_LIBS=$LIBS - LIBS="$LIBS $X_LDFLAGS" - rpath="" - for fl in "-Wl,-rpath " "-Wl,--rpath " "-rpath " "--rpath " "-Wl,-R" "-R" "-R " ; do - xlib_rpath=`echo $xlib_path | sed "s/-L/$fl/g"` - LIBS="$_save_LIBS $X_LIBS $xlib_rpath" - AC_MSG_CHECKING([if the compiler accepts ${fl}path for runtime libraries]) - AC_LINK_IFELSE([AC_LANG_PROGRAM()], - AC_MSG_RESULT([yes]) - rpath=$fl, - AC_MSG_RESULT([no])) - test -n "$rpath" && break - done - if test -n "$rpath"; then - X_LDFLAGS="$X_LDFLAGS $xlib_rpath" - fi - LIBS=$_save_LIBS -fi - -dnl Checks for X libraries - if X11 wasn't found then don't make following -dnl tests and compile without X11 support - otherwise, check if the following -dnl libraries are present (error if they are not) -dnl In CYGWIN library ordering has to be changed. Is this compatible to LINUX? -dnl XShmAttach is a struct in CYGWIN, not a function -dnl SJB: 13th march 2005 -dnl Library order is giving linker warnings on MacOSX -dnl It's not clear to me which order is required for Cygwin (see comment above) -dnl and neither can I find any authoritative answer for the correct link order -dnl for MacOSX or Linux, but -dnl -lXaw -lXmu -lXt -lXext -lX11 -dnl seems to be the popular choice. -dnl (The previous order was -lX11 -lXt -lXext -lXmu -lXaw) -if test "x$enable_x" = "xno"; then - no_x = "no" -fi -if test ! "$no_x" = "yes" ; then - AC_CHECK_LIB(Xaw,main,X_LIBS="$X_LIBS -lXaw",AC_MSG_ERROR(Couldn't find Xaw library),$X_LIBS $X_EXTRA_LIBS) - AC_CHECK_LIB(Xmu,main,X_LIBS="$X_LIBS -lXmu",AC_MSG_ERROR(Couldn't find Xmu library), $X_LIBS $X_EXTRA_LIBS) - X_LIBS="$X_LIBS -lXt" - AC_CHECK_LIB(Xext, XShmAttach,X_LIBS="$X_LIBS -lXext",AC_MSG_ERROR(Couldn't find Xext library), $X_LIBS $X_EXTRA_LIBS) - X_LIBS="$X_LIBS -lX11" - AM_CONDITIONAL(NO_X, false) -else - AC_DEFINE(X_DISPLAY_MISSING) - AC_MSG_RESULT(No X display!) - AM_CONDITIONAL(NO_X, true) -fi - -if ( test "x$enable_help" = "xyes" ) && ! ( test "$no_x" = "yes" ) ; then - AM_CONDITIONAL(NO_HELP, false) -else - AM_CONDITIONAL(NO_HELP, true) -fi ;; - -esac dnl Check for a few typdefs: AC_TYPE_PID_T