Modified hash_map and hash_set configuration so that they are not

regenerated on every run of configure.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16509 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
John Criswell
2004-09-24 18:28:00 +00:00
parent 0c96766c90
commit 9f011866e9
6 changed files with 142 additions and 76 deletions

View File

@@ -44,10 +44,10 @@ AC_CONFIG_HEADERS(include/llvm/Config/config.h)
dnl Configure other output file
AC_CONFIG_FILES(Makefile.config
include/llvm/Support/ThreadSupport.h
include/llvm/ADT/hash_map
include/llvm/ADT/hash_set
include/llvm/ADT/iterator)
AC_CONFIG_HEADERS([include/llvm/Support/DataTypes.h])
AC_CONFIG_HEADERS([include/llvm/ADT/hash_map])
AC_CONFIG_HEADERS([include/llvm/ADT/hash_set])
dnl Do special configuration of Makefiles
AC_CONFIG_MAKEFILE(Makefile)

View File

@@ -10,12 +10,13 @@ AC_DEFUN([AC_CXX_HAVE_STD_EXT_HASH_MAP],
using namespace std;
#endif]], [[hash_map<int, int> t;]])],[ac_cv_cxx_have_std_ext_hash_map=yes],[ac_cv_cxx_have_std_ext_hash_map=no])
AC_LANG_POP([C++])])
HAVE_STD_EXT_HASH_MAP=0
if test "$ac_cv_cxx_have_std_ext_hash_map" = yes
then
HAVE_STD_EXT_HASH_MAP=1
AC_DEFINE(HAVE_STD_EXT_HASH_MAP,1,[Have ext/hash_map>])
else
AC_DEFINE(HAVE_STD_EXT_HASH_MAP,0,[Does not have ext/hash_map>])
fi
AC_SUBST(HAVE_STD_EXT_HASH_MAP)])
])
AC_DEFUN([AC_CXX_HAVE_GNU_EXT_HASH_MAP],
[AC_CACHE_CHECK([whether the compiler has <ext/hash_map> defining template class __gnu_cxx::hash_map],
@@ -27,12 +28,13 @@ AC_DEFUN([AC_CXX_HAVE_GNU_EXT_HASH_MAP],
using namespace __gnu_cxx;
#endif]], [[hash_map<int,int> t; ]])],[ac_cv_cxx_have_gnu_ext_hash_map=yes],[ac_cv_cxx_have_gnu_ext_hash_map=no])
AC_LANG_POP([C++])])
HAVE_GNU_EXT_HASH_MAP=0
if test "$ac_cv_cxx_have_gnu_ext_hash_map" = yes
then
HAVE_GNU_EXT_HASH_MAP=1
AC_DEFINE(HAVE_GNU_EXT_HASH_MAP,1,[Have ext/hash_map])
else
AC_DEFINE(HAVE_GNU_EXT_HASH_MAP,0,[Does not have ext/hash_map])
fi
AC_SUBST(HAVE_GNU_EXT_HASH_MAP)])
])
AC_DEFUN([AC_CXX_HAVE_GLOBAL_HASH_MAP],
[AC_CACHE_CHECK([whether the compiler has <hash_map> defining template class ::hash_map],
@@ -41,12 +43,13 @@ AC_DEFUN([AC_CXX_HAVE_GLOBAL_HASH_MAP],
AC_LANG_PUSH([C++])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <hash_map>]], [[hash_map<int,int> t; ]])],[ac_cv_cxx_have_global_hash_map=yes],[ac_cv_cxx_have_global_hash_map=no])
AC_LANG_POP([C++])])
HAVE_GLOBAL_HASH_MAP=0
if test "$ac_cv_cxx_have_global_hash_map" = yes
then
HAVE_GLOBAL_HASH_MAP=1
AC_DEFINE(HAVE_GLOBAL_HASH_MAP,1,[Have <hash_map>])
else
AC_DEFINE(HAVE_GLOBAL_HASH_MAP,0,[Does not have <hash_map>])
fi
AC_SUBST(HAVE_GLOBAL_HASH_MAP)])
])
AC_DEFUN([AC_CXX_HAVE_HASH_MAP],
[AC_CXX_HAVE_STD_EXT_HASH_MAP

View File

@@ -10,12 +10,13 @@ AC_DEFUN([AC_CXX_HAVE_STD_EXT_HASH_SET],
using namespace std;
#endif]], [[hash_set<int> t; ]])],[ac_cv_cxx_have_std_ext_hash_set=yes],[ac_cv_cxx_have_std_ext_hash_set=no])
AC_LANG_POP([C++])])
HAVE_STD_EXT_HASH_SET=0
if test "$ac_cv_cxx_have_std_ext_hash_set" = yes
then
HAVE_STD_EXT_HASH_SET=1
AC_DEFINE(HAVE_STD_EXT_HASH_SET,1,[Have hash_set in std namespace])
else
AC_DEFINE(HAVE_STD_EXT_HASH_SET,0,[Does not have hash_set in std namespace])
fi
AC_SUBST(HAVE_STD_EXT_HASH_SET)])
])
AC_DEFUN([AC_CXX_HAVE_GNU_EXT_HASH_SET],
[AC_CACHE_CHECK(
@@ -28,12 +29,13 @@ AC_DEFUN([AC_CXX_HAVE_GNU_EXT_HASH_SET],
using namespace __gnu_cxx;
#endif]], [[hash_set<int> t; ]])],[ac_cv_cxx_have_gnu_ext_hash_set=yes],[ac_cv_cxx_have_gnu_ext_hash_set=no])
AC_LANG_POP([C++])])
HAVE_GNU_EXT_HASH_SET=0
if test "$ac_cv_cxx_have_gnu_ext_hash_set" = yes
then
HAVE_GNU_EXT_HASH_SET=1
AC_DEFINE(HAVE_GNU_EXT_HASH_SET,1,[Have hash_set in gnu namespace])
else
AC_DEFINE(HAVE_GNU_EXT_HASH_SET,0,[Does not have hash_set in gnu namespace])
fi
AC_SUBST(HAVE_GNU_EXT_HASH_SET)])
])
AC_DEFUN([AC_CXX_HAVE_GLOBAL_HASH_SET],
[AC_CACHE_CHECK([whether the compiler has <hash_set> defining template class ::hash_set],
@@ -42,12 +44,13 @@ AC_DEFUN([AC_CXX_HAVE_GLOBAL_HASH_SET],
AC_LANG_PUSH([C++])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <hash_set>]], [[hash_set<int> t; return 0;]])],[ac_cv_cxx_have_global_hash_set=yes],[ac_cv_cxx_have_global_hash_set=no])
AC_LANG_POP([C++])])
HAVE_GLOBAL_HASH_SET=0
if test "$ac_cv_cxx_have_global_hash_set" = yes
then
HAVE_GLOBAL_HASH_SET=1
AC_DEFINE(HAVE_GLOBAL_HASH_SET,1,[Have hash_set in global namespace])
else
AC_DEFINE(HAVE_GLOBAL_HASH_SET,0,[Does not have hash_set in global namespace])
fi
AC_SUBST(HAVE_GLOBAL_HASH_SET)])
])
AC_DEFUN([AC_CXX_HAVE_HASH_SET],
[AC_CXX_HAVE_STD_EXT_HASH_SET