Fixed call to geometry factory.
[geos.git] / acinclude.m4
blobd6bb136fc395924ff12ee20fbe603c81f5d6df8c
1 ##
2 ##
3 ##
4 AC_DEFUN([AC_CXX_NAMESPACES],
5 [AC_CACHE_CHECK(whether the compiler implements namespaces,
6 ac_cv_cxx_namespaces,
7 [AC_LANG_SAVE
8  AC_LANG_CPLUSPLUS
9  AC_TRY_COMPILE([namespace Outer { namespace Inner { int i = 0; }}],
10                 [using namespace Outer::Inner; return i;],
11  ac_cv_cxx_namespaces=yes, ac_cv_cxx_namespaces=no)
12  AC_LANG_RESTORE
14 if test "$ac_cv_cxx_namespaces" = yes; then
15   AC_DEFINE(HAVE_NAMESPACES,,[define if the compiler implements namespaces])
19 AC_DEFUN([AC_CXX_HAVE_STL],
20 [AC_CACHE_CHECK(whether the compiler supports Standard Template Library,
21 ac_cv_cxx_have_stl,
22 [AC_REQUIRE([AC_CXX_NAMESPACES])
23  AC_LANG_SAVE
24  AC_LANG_CPLUSPLUS
25  AC_TRY_COMPILE([#include <list>
26 #include <deque>
27 #ifdef HAVE_NAMESPACES
28 using namespace std;
29 #endif],[list<int> x; x.push_back(5);
30 list<int>::iterator iter = x.begin(); if (iter != x.end()) ++iter; return 
31 0;],
32  ac_cv_cxx_have_stl=yes, ac_cv_cxx_have_stl=no)
33  AC_LANG_RESTORE
35 if test "$ac_cv_cxx_have_stl" = yes; then
36   AC_DEFINE(HAVE_STL,,[define if the compiler supports Standard Template Library