1
1

Use newer AC_LANG* test compilation syntax

This commit was SVN r107.
Этот коммит содержится в:
Jeff Squyres 2004-01-08 13:31:42 +00:00
родитель 6b7513431c
Коммит 295e3f7614
2 изменённых файлов: 3 добавлений и 3 удалений

Просмотреть файл

@ -43,13 +43,13 @@ elif test "$GXX" = "yes"; then
AC_LANG_SAVE
AC_LANG_CPLUSPLUS
AC_TRY_COMPILE(, [try { int i = 0; } catch(...) { int j = 2; }], lam_happy=1, lam_happy=0)
AC_COMPILE_IFELSE(AC_LANG_PROGRAM([[]], [[try { int i = 0; } catch(...) { int j = 2; }]]), lam_happy=1, lam_happy=0)
if test "$lam_happy" = "1"; then
lam_exflags="-fexceptions";
else
CXXFLAGS="$CXXFLAGS_SAVE -fhandle-exceptions"
AC_TRY_COMPILE(, [try { int i = 0; } catch(...) { int j = 2; }], lam_happy=1, lam_happy=0)
AC_COMPILE_IFELSE(AC_LANG_PROGRAM([[]], [[try { int i = 0; } catch(...) { int j = 2; }]]), lam_happy=1, lam_happy=0)
if test "$lam_happy" = "1"; then
lam_exflags="-fhandle-exceptions";
fi

Просмотреть файл

@ -17,7 +17,7 @@ define([LAM_CXX_HAVE_EXCEPTIONS],[
AC_MSG_CHECKING([for throw/catch])
AC_LANG_SAVE
AC_LANG_CPLUSPLUS
AC_TRY_COMPILE(, int i=1; throw(i);,
AC_COMPILE_IFELSE(AC_LANG_PROGRAM([[]], [[int i=1; throw(i);]]),
LAM_CXX_EXCEPTIONS=1, LAM_CXX_EXCPTIONS=0)
if test "$LAM_CXX_EXCEPTIONS" = "1"; then
AC_MSG_RESULT([yes])