Patch from Yves to check whether C functions are defined in std:: namespace

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@1209 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Jean-Marc Lasgouttes 2000-11-10 12:33:01 +00:00
parent f542eaaa6e
commit 9c798989d9
5 changed files with 35 additions and 3 deletions

View File

@ -1,3 +1,17 @@
2000-11-10 Jean-Marc Lasgouttes <Jean-Marc.Lasgouttes@inria.fr>
* lib/CREDITS: add Yves Bastide
2000-11-03 Yves Bastide <stid@libd-pc11.univ-bpclermont.fr>
* config/lyxinclude.m4 (LYX_CXX_GLOBAL_CSTD): new function to
check whether C library functions are in the global namespace.
* configure.in: calls it.
* src/support/lstrings.C: #ifndef CXX_GLOBAL_CSTD instead of
#ifndef __GLIBCPP__.
2000-11-08 Dekel Tsur <dekelts@tau.ac.il>
* src/frontends/xforms/FormParagraph.C (updateLanguage): Check

View File

@ -519,6 +519,22 @@ if test $lyx_cv_cxx_cheaders = no ; then
LYX_ADD_INC_DIR(lyx_cppflags,\$(top_srcdir)/src/cheaders)
fi])
dnl Usage: LYX_CXX_GLOBAL_CSTD: checks whether C library functions
dnl are already in the global namespace
AC_DEFUN(LYX_CXX_GLOBAL_CSTD,[
AC_CACHE_CHECK(whether C library functions are already in the global namespace,
lyx_cv_cxx_global_cstd,
[AC_TRY_COMPILE([
#include <cctype>
using std::tolower;
],[
return 0;
],[lyx_cv_cxx_global_cstd=no],[lyx_cv_cxx_global_cstd=yes])])
if test x$lyx_cv_cxx_global_cstd = xyes; then
AC_DEFINE(CXX_GLOBAL_CSTD,1,
[Define if your C++ compiler puts C library functions in the global namespace])
fi
])
dnl Usage LYX_PATH_XPM: Checks for xpm library and header
AC_DEFUN(LYX_PATH_XPM,[

View File

@ -91,6 +91,7 @@ LYX_CXX_STL_STRING
LYX_CXX_GOOD_STD_STRING
LYX_CXX_NAMESPACES
LYX_CXX_CHEADERS
LYX_CXX_GLOBAL_CSTD
LYX_STD_COUNT
dnl we disable rtti for now
dnl LYX_CXX_RTTI

View File

@ -15,6 +15,9 @@
external style definition files,
linuxdoc sgml support and more
ftp-site ftp.lyx.org
@bYves Bastide
@iE-mail: stid@acm.org
Bug fixes
@bHeinrich Bauer
@iE-mail: heinrich.bauer@t-mobil.de
Fixes for dvi output

View File

@ -26,9 +26,7 @@
using std::count;
using std::transform;
#ifndef __GLIBCPP__
// The new glibstdc++-v3 has not worked out all the quirks regarding cctype
// yet. So currently it failes if the to using lines below are stated.
#ifndef CXX_GLOBAL_CSTD
using std::tolower;
using std::toupper;
#endif