[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/trunk r109872: * configure.ac (_setjmp, _lo
From: |
Paul Eggert |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/trunk r109872: * configure.ac (_setjmp, _longjmp): Check by compiling |
Date: |
Mon, 03 Sep 2012 23:25:44 -0700 |
User-agent: |
Bazaar (2.5.0) |
------------------------------------------------------------
revno: 109872
committer: Paul Eggert <address@hidden>
branch nick: trunk
timestamp: Mon 2012-09-03 23:25:44 -0700
message:
* configure.ac (_setjmp, _longjmp): Check by compiling
instead of by guessing. The guesses were wrong for
recent versions of Solaris, such as Solaris 11.
modified:
ChangeLog
configure.ac
=== modified file 'ChangeLog'
--- a/ChangeLog 2012-09-03 19:34:49 +0000
+++ b/ChangeLog 2012-09-04 06:25:44 +0000
@@ -1,3 +1,9 @@
+2012-09-04 Paul Eggert <address@hidden>
+
+ * configure.ac (_setjmp, _longjmp): Check by compiling
+ instead of by guessing. The guesses were wrong for
+ recent versions of Solaris, such as Solaris 11.
+
2012-09-03 Paul Eggert <address@hidden>
* configure.ac (WARN_CFLAGS): Omit -Wjump-misses-init.
=== modified file 'configure.ac'
--- a/configure.ac 2012-09-03 19:34:49 +0000
+++ b/configure.ac 2012-09-04 06:25:44 +0000
@@ -3791,13 +3791,27 @@
esac
fi dnl GCC?
+AC_CACHE_CHECK([for _setjmp], [emacs_cv_func__setjmp],
+ [AC_LINK_IFELSE(
+ [AC_LANG_PROGRAM(
+ [[#include <setjmp.h>
+ ]],
+ [[jmp_buf j;
+ if (! _setjmp (j))
+ _longjmp (j, 1);]])],
+ [emacs_cv_func__setjmp=yes],
+ [emacs_cv_func__setjmp=no])])
+if test $emacs_cv_func__setjmp = no; then
+ AC_DEFINE([_setjmp], [setjmp],
+ [Define to setjmp if _setjmp and _longjmp do not work. See _longjmp.])
+ AC_DEFINE([_longjmp], [longjmp],
+ [Define to longjmp if _setjmp and _longjmp do not work.
+ Because longjmp may alter signal masks, callers of _longjmp
+ should not assume that it leaves signal masks alone.])
+fi
case $opsys in
sol2* | unixware )
- dnl setjmp and longjmp can safely replace _setjmp and _longjmp,
- dnl but they will run more slowly.
- AC_DEFINE(_setjmp, setjmp, [Some platforms redefine this.])
- AC_DEFINE(_longjmp, longjmp, [Some platforms redefine this.])
dnl TIOCGPGRP is broken in SysVr4, so we can't send signals to PTY
dnl subprocesses the usual way. But TIOCSIGNAL does work for PTYs,
dnl and this is all we need.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/trunk r109872: * configure.ac (_setjmp, _longjmp): Check by compiling,
Paul Eggert <=