|
Revision 2007, 2.0 kB
(checked in by ensc, 4 years ago)
|
fixed typo
|
- Property svn:eol-style set to
native
- Property svn:keywords set to
Author Date Id Revision
|
| Line | |
|---|
| 1 |
|
|---|
| 2 |
|
|---|
| 3 |
|
|---|
| 4 |
|
|---|
| 5 |
|
|---|
| 6 |
|
|---|
| 7 |
|
|---|
| 8 |
|
|---|
| 9 |
|
|---|
| 10 |
|
|---|
| 11 |
|
|---|
| 12 |
|
|---|
| 13 |
|
|---|
| 14 |
|
|---|
| 15 |
|
|---|
| 16 |
|
|---|
| 17 |
|
|---|
| 18 |
AC_DEFUN([ENSC_CXXCOMPILER], |
|---|
| 19 |
[ |
|---|
| 20 |
AC_REQUIRE([AC_PROG_CXX]) |
|---|
| 21 |
|
|---|
| 22 |
AC_CACHE_CHECK([whether $CXX is a C++ compiler], [ensc_cv_cxx_cxxcompiler], |
|---|
| 23 |
[ |
|---|
| 24 |
AC_LANG_PUSH(C++) |
|---|
| 25 |
AC_COMPILE_IFELSE([ |
|---|
| 26 |
|
|---|
| 27 |
], |
|---|
| 28 |
[ensc_cv_cxx_cxxcompiler=yes], |
|---|
| 29 |
[ensc_cv_cxx_cxxcompiler=no]) |
|---|
| 30 |
AC_LANG_POP(C++) |
|---|
| 31 |
]) |
|---|
| 32 |
|
|---|
| 33 |
AM_CONDITIONAL(ENSC_HAVE_CXX_COMPILER, |
|---|
| 34 |
[test x"$ensc_cv_cxx_cxxcompiler" = xyes]) |
|---|
| 35 |
|
|---|
| 36 |
if test x"$ensc_cv_cxx_cxxcompiler" = xno; then |
|---|
| 37 |
AC_MSG_WARN([*** some programs will not be built because a C++ compiler is lacking]) |
|---|
| 38 |
fi |
|---|
| 39 |
]) |
|---|
| 40 |
|
|---|
| 41 |
AC_DEFUN([ENSC_C99COMPILER], |
|---|
| 42 |
[ |
|---|
| 43 |
AC_REQUIRE([AC_PROG_CC]) |
|---|
| 44 |
|
|---|
| 45 |
AC_CACHE_CHECK([whether $CC is a C99 compiler], [ensc_cv_c99_c99compiler], |
|---|
| 46 |
[ |
|---|
| 47 |
AC_LANG_PUSH(C) |
|---|
| 48 |
AC_COMPILE_IFELSE([ |
|---|
| 49 |
int main(int argc, char *argv[]) { |
|---|
| 50 |
struct { int x; } a = { .x = argc }; |
|---|
| 51 |
if (0) return 0; |
|---|
| 52 |
int b; |
|---|
| 53 |
} |
|---|
| 54 |
], |
|---|
| 55 |
[ensc_cv_c99_c99compiler=yes], |
|---|
| 56 |
[ensc_cv_c99_c99compiler=no]) |
|---|
| 57 |
AC_LANG_POP(C) |
|---|
| 58 |
]) |
|---|
| 59 |
|
|---|
| 60 |
AM_CONDITIONAL(ENSC_HAVE_C99_COMPILER, |
|---|
| 61 |
[test x"$ensc_cv_c99_c99compiler" = xyes]) |
|---|
| 62 |
|
|---|
| 63 |
if test x"$ensc_cv_c99_c99compiler" = xno; then |
|---|
| 64 |
AC_MSG_WARN([*** some programs will not be built because system is lacking a C99 compiler]) |
|---|
| 65 |
fi |
|---|
| 66 |
]) |
|---|