Mercurial > hg > octave-nkf
changeset 5842:ecb61a521d5b
[project @ 2006-06-06 15:03:33 by jwe]
author | jwe |
---|---|
date | Tue, 06 Jun 2006 15:03:33 +0000 |
parents | fb4dea2184bf |
children | 393100dce990 |
files | aclocal.m4 configure.in |
diffstat | 2 files changed, 57 insertions(+), 57 deletions(-) [+] |
line wrap: on
line diff
--- a/aclocal.m4 +++ b/aclocal.m4 @@ -193,37 +193,36 @@ AC_MSG_CHECKING(for type of signal functions) AC_CACHE_VAL(octave_cv_signal_vintage, [ - AC_TRY_LINK([#include <signal.h>],[ - sigset_t ss; - struct sigaction sa; - sigemptyset(&ss); sigsuspend(&ss); - sigaction(SIGINT, &sa, (struct sigaction *) 0); - sigprocmask(SIG_BLOCK, &ss, (sigset_t *) 0); - ], octave_cv_signal_vintage=posix, - [ - AC_TRY_LINK([#include <signal.h>], [ - int mask = sigmask(SIGINT); - sigsetmask(mask); sigblock(mask); sigpause(mask); - ], octave_cv_signal_vintage=4.2bsd, - [ - AC_TRY_LINK([ - #include <signal.h> - RETSIGTYPE foo() { }], [ - int mask = sigmask(SIGINT); - sigset(SIGINT, foo); sigrelse(SIGINT); - sighold(SIGINT); sigpause(SIGINT); - ], octave_cv_signal_vintage=svr3, octave_cv_signal_vintage=v7 - )] - )] -) -]) + AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <signal.h>]], + [[sigset_t ss; + struct sigaction sa; + sigemptyset (&ss); + sigsuspend (&ss); + sigaction (SIGINT, &sa, (struct sigaction *) 0); + sigprocmask (SIG_BLOCK, &ss, (sigset_t *) 0);]])], + [octave_cv_signal_vintage=posix], + [AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <signal.h>]], + [[int mask = sigmask (SIGINT); + sigsetmask (mask); + sigblock (mask); + sigpause (mask);]])], + [octave_cv_signal_vintage=4.2bsd], + [AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <signal.h> + RETSIGTYPE foo() { }]])], + [[int mask = sigmask (SIGINT); + sigset (SIGINT, foo); + sigrelse (SIGINT); + sighold (SIGINT); + sigpause (SIGINT);]], + [octave_cv_signal_vintage=svr3], + [octave_cv_signal_vintage=v7])])])]) AC_MSG_RESULT($octave_cv_signal_vintage) if test "$octave_cv_signal_vintage" = posix; then -AC_DEFINE(HAVE_POSIX_SIGNALS,1,[Define if you have POSIX style signals.]) +AC_DEFINE(HAVE_POSIX_SIGNALS, 1, [Define if you have POSIX style signals.]) elif test "$octave_cv_signal_vintage" = "4.2bsd"; then -AC_DEFINE(HAVE_BSD_SIGNALS,1,[Define if you have BSD style signals.]) +AC_DEFINE(HAVE_BSD_SIGNALS, 1, [Define if you have BSD style signals.]) elif test "$octave_cv_signal_vintage" = svr3; then -AC_DEFINE(HAVE_USG_SIGHOLD,1,[Define if you have System V Release 3 signals.]) +AC_DEFINE(HAVE_USG_SIGHOLD, 1, [Define if you have System V Release 3 signals.]) fi ]) dnl @@ -308,13 +307,11 @@ return 0; } EOB - AC_TRY_LINK([#include "conftest.h"], [ - A a (1); - return a == A(1); - ], - octave_cv_cxx_new_friend_template_decl=no, - octave_cv_cxx_new_friend_template_decl=yes - ) + AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include "conftest.h"]], + [[A a (1); + return a == A(1);]])], + [octave_cv_cxx_new_friend_template_decl=no], + [octave_cv_cxx_new_friend_template_decl=yes]) AC_LANG_POP(C++) ]) AC_MSG_RESULT($octave_cv_cxx_new_friend_template_decl) @@ -632,15 +629,13 @@ utility valarray vector; do echo "#include <$inc>" >> conftest.h done - AC_TRY_LINK([#include "conftest.h"], [ - std::bitset<50> flags; + AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include "conftest.h"]], + [[std::bitset<50> flags; flags.set(); int digits = std::numeric_limits<unsigned long>::digits; - digits = 0; - ], - octave_cv_cxx_iso_compliant_library=yes, - octave_cv_cxx_iso_compliant_library=no - ) + digits = 0;]])], + [octave_cv_cxx_iso_compliant_library=yes], + [octave_cv_cxx_iso_compliant_library=no]) AC_LANG_POP(C++) ]) AC_MSG_RESULT($octave_cv_cxx_iso_compliant_library)
--- a/configure.in +++ b/configure.in @@ -29,7 +29,7 @@ EXTERN_CXXFLAGS="$CXXFLAGS" AC_INIT -AC_REVISION($Revision: 1.511 $) +AC_REVISION($Revision: 1.512 $) AC_PREREQ(2.57) AC_CONFIG_SRCDIR([src/octave.cc]) AC_CONFIG_HEADER(config.h) @@ -47,7 +47,7 @@ ### Path separator. sepchar=: AC_ARG_WITH(sepchar, - [AC_HELP_STRING([--with-sepchar=<char>], + [AS_HELP_STRING([--with-sepchar=<char>], [use <char> as the path separation character])]) case $with_sepchar in yes | "") @@ -1368,7 +1368,7 @@ if test "x$HAVE_TIMEVAL" = xyes; then AC_MSG_CHECKING(whether gettimeofday can't accept two arguments) -AC_TRY_LINK([#ifdef TIME_WITH_SYS_TIME +AC_LINK_IFELSE([AC_LANG_PROGRAM([[#ifdef TIME_WITH_SYS_TIME #include <sys/time.h> #include <time.h> #else @@ -1377,10 +1377,13 @@ #else #include <time.h> #endif -#endif],[struct timeval time; struct timezone dummy; - gettimeofday (&time, &dummy);], [AC_MSG_RESULT(no)], +#endif]], [[struct timeval time; + struct timezone dummy; + gettimeofday (&time, &dummy);]])], + [AC_MSG_RESULT(no)], [AC_MSG_RESULT(yes) - AC_DEFINE(GETTIMEOFDAY_NO_TZ, 1, [Define if your system has a single-arg prototype for gettimeofday.])]) + AC_DEFINE(GETTIMEOFDAY_NO_TZ, 1, + [Define if your system has a single-arg prototype for gettimeofday.])]) fi dnl Would like to get rid of this cruft, and just have @@ -1454,11 +1457,12 @@ OCTAVE_ENABLE_READLINE AC_MSG_CHECKING([for struct exception in math.h]) -AC_TRY_LINK([#include <math.h>], - [struct exception *x; x->type; x->name;], - AC_MSG_RESULT(yes) - AC_DEFINE(EXCEPTION_IN_MATH, 1, [Define if your math.h declares struct exception for matherr().]), - AC_MSG_RESULT(no)) +AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <math.h>]], + [[struct exception *x; x->type; x->name;]])], + [AC_MSG_RESULT(yes) + AC_DEFINE(EXCEPTION_IN_MATH, 1, + [Define if your math.h declares struct exception for matherr().])], + [AC_MSG_RESULT(no)]) ### Signal stuff. @@ -1467,11 +1471,12 @@ [AC_DEFINE(SYS_SIGLIST_DECLARED, 1, [Define if your system has a declaration of sys_siglist.])], [AC_CHECK_DECLS([sys_siglist])], [#include <signal.h>]) AC_MSG_CHECKING([for sys_siglist variable]) -AC_TRY_LINK([#include <stdio.h>], - [extern char *sys_siglist[]; printf ("%s\n", sys_siglist[1]);], - AC_MSG_RESULT(yes) - AC_DEFINE(HAVE_SYS_SIGLIST, 1, [Define if your system has a sys_siglist variable.]), - AC_MSG_RESULT(no)) +AC_LINK_IFELSE([[#include <stdio.h>]], + [[extern char *sys_siglist[]; printf ("%s\n", sys_siglist[1]);]])], + [AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_SYS_SIGLIST, 1, + [Define if your system has a sys_siglist variable.])], + [AC_MSG_RESULT(no)]) OCTAVE_SIGNAL_CHECK OCTAVE_REINSTALL_SIGHANDLERS