mirror of https://github.com/BOINC/boinc.git
modified SAH_HEADER_STDCXX to run quickly on machines that have all of the
C++ standard headers svn path=/trunk/boinc/; revision=5956
This commit is contained in:
parent
6d23cf3586
commit
61ad976802
|
@ -14,6 +14,40 @@ AC_DEFUN([SAH_HEADER_STDCXX],[
|
||||||
|
|
||||||
sah_stdcxx_headers="algorithm bitset cassert cctype cerrno cfloat climits clocale cmath complex csetjmp csignal cstdarg cstddef cstdio cstdlib cstring ctime deque fstream functional iomanip ios iosfwd iostream istream iterator limits list locale map memory numeric ostream queue set sstream stack stdexcept streambuf string utility valarray vector"
|
sah_stdcxx_headers="algorithm bitset cassert cctype cerrno cfloat climits clocale cmath complex csetjmp csignal cstdarg cstddef cstdio cstdlib cstring ctime deque fstream functional iomanip ios iosfwd iostream istream iterator limits list locale map memory numeric ostream queue set sstream stack stdexcept streambuf string utility valarray vector"
|
||||||
AC_LANG_PUSH(C++)
|
AC_LANG_PUSH(C++)
|
||||||
|
dnl First we'll check to see if they are all here in order to save time.
|
||||||
|
AC_MSG_CHECKING([standard C++ headers])
|
||||||
|
tmp_includes=
|
||||||
|
for header in $sah_stdcxx_headers
|
||||||
|
do
|
||||||
|
tmp_includes="$tmp_includes
|
||||||
|
#include <$header>
|
||||||
|
"
|
||||||
|
done
|
||||||
|
AC_COMPILE_IFELSE([
|
||||||
|
AC_LANG_PROGRAM([[
|
||||||
|
$tmp_includes
|
||||||
|
$ac_includes_default
|
||||||
|
]],
|
||||||
|
[]
|
||||||
|
)],
|
||||||
|
[
|
||||||
|
ac_includes_default="${ac_includes_default}
|
||||||
|
${tmp_includes}
|
||||||
|
"
|
||||||
|
sah_cxx_includes=${tmp_includes}
|
||||||
|
AC_MSG_RESULT(yes)
|
||||||
|
for header in $sah_stdcxx_headers
|
||||||
|
do
|
||||||
|
eval ac_cv_header_${header}=yes
|
||||||
|
ac_uc_defn=HAVE_`echo ${header} | sed -e 's/[^a-zA-Z0-9_]/_/g' \
|
||||||
|
-e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
|
||||||
|
AC_DEFINE_UNQUOTED([${ac_uc_defn}],1,[Define to 1 if you have the ${header} header])
|
||||||
|
AC_CACHE_CHECK([for C++ header <${header}>],[ac_cv_header_${header}])
|
||||||
|
done
|
||||||
|
],
|
||||||
|
[
|
||||||
|
ac_includes_default="$save_inc"
|
||||||
|
AC_MSG_RESULT(no)
|
||||||
AC_CHECK_HEADERS([$sah_stdcxx_headers])
|
AC_CHECK_HEADERS([$sah_stdcxx_headers])
|
||||||
for header in $sah_stdcxx_headers
|
for header in $sah_stdcxx_headers
|
||||||
do
|
do
|
||||||
|
@ -25,9 +59,11 @@ AC_DEFUN([SAH_HEADER_STDCXX],[
|
||||||
"
|
"
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
]
|
||||||
|
)
|
||||||
|
ac_includes_default="$save_inc"
|
||||||
AC_CACHE_SAVE
|
AC_CACHE_SAVE
|
||||||
AC_LANG_POP
|
AC_LANG_POP
|
||||||
ac_includes_default="$save_inc"
|
|
||||||
CONFIG_TEST=
|
CONFIG_TEST=
|
||||||
])
|
])
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue