1
dnl @synopsis AC_CXX_HAVE_STL
3
dnl If the compiler supports the Standard Template Library, define HAVE_STL.
5
dnl @version $Id: ac_cxx_have_stl.m4,v 1.1 2002/09/20 21:06:54 jmwille Exp $
6
dnl @author Luc Maisonobe
8
AC_DEFUN([AC_CXX_HAVE_STL],
9
[AC_CACHE_CHECK(whether the compiler supports Standard Template Library,
11
[AC_REQUIRE([AC_CXX_NAMESPACES])
14
AC_TRY_COMPILE([#include <list>
16
#ifdef HAVE_NAMESPACES
18
#endif],[list<int> x; x.push_back(5);
19
list<int>::iterator iter = x.begin(); if (iter != x.end()) ++iter; return 0;],
20
ac_cv_cxx_have_stl=yes, ac_cv_cxx_have_stl=no)
23
if test "$ac_cv_cxx_have_stl" = yes; then
24
AC_DEFINE(HAVE_STL,,[define if the compiler supports Standard Template Library])