mirror of git://gcc.gnu.org/git/gcc.git
acinclude.m4 (GLIBCXX_CHECK_SYSTEM_ERROR): Add ENOLINK, EPROTO for netbsd.
2007-08-24 Benjamin Kosnik <bkoz@redhat.com> * acinclude.m4 (GLIBCXX_CHECK_SYSTEM_ERROR): Add ENOLINK, EPROTO for netbsd. * configure: Regenerate. * include/std/system_error: Guard. * testsuite/19_diagnostics/headers/system_error/ types_std_c++0x.cc: Same. * testsuite/19_diagnostics/error_category/cons/copy_neg.cc: Adjust line numbers. From-SVN: r127772
This commit is contained in:
parent
fa2050d266
commit
c6a8035acf
|
@ -1,3 +1,14 @@
|
||||||
|
2007-08-24 Benjamin Kosnik <bkoz@redhat.com>
|
||||||
|
|
||||||
|
* acinclude.m4 (GLIBCXX_CHECK_SYSTEM_ERROR): Add ENOLINK, EPROTO
|
||||||
|
for netbsd.
|
||||||
|
* configure: Regenerate.
|
||||||
|
* include/std/system_error: Guard.
|
||||||
|
* testsuite/19_diagnostics/headers/system_error/
|
||||||
|
types_std_c++0x.cc: Same.
|
||||||
|
* testsuite/19_diagnostics/error_category/cons/copy_neg.cc: Adjust
|
||||||
|
line numbers.
|
||||||
|
|
||||||
2007-08-23 Benjamin Kosnik <bkoz@redhat.com>
|
2007-08-23 Benjamin Kosnik <bkoz@redhat.com>
|
||||||
|
|
||||||
* include/std/system_error: New file.
|
* include/std/system_error: New file.
|
||||||
|
|
|
@ -1282,6 +1282,26 @@ AC_DEFUN([GLIBCXX_CHECK_SYSTEM_ERROR], [
|
||||||
AC_DEFINE(HAVE_ENOTRECOVERABLE, 1, [Define if ENOTRECOVERABLE exists.])
|
AC_DEFINE(HAVE_ENOTRECOVERABLE, 1, [Define if ENOTRECOVERABLE exists.])
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
AC_MSG_CHECKING([for ENOLINK])
|
||||||
|
AC_CACHE_VAL(ac_system_error3, [
|
||||||
|
AC_TRY_COMPILE([#include <errno.h>], [ int i = ENOLINK; ],
|
||||||
|
[ac_system_error3=yes], [ac_system_error3=no])
|
||||||
|
])
|
||||||
|
AC_MSG_RESULT($ac_system_error3)
|
||||||
|
if test x"$ac_system_error3" = x"yes"; then
|
||||||
|
AC_DEFINE(HAVE_ENOLINK, 1, [Define if ENOLINK exists.])
|
||||||
|
fi
|
||||||
|
|
||||||
|
AC_MSG_CHECKING([for EPROTO])
|
||||||
|
AC_CACHE_VAL(ac_system_error_4, [
|
||||||
|
AC_TRY_COMPILE([#include <errno.h>], [ int i = EPROTO; ],
|
||||||
|
[ac_system_error_4=yes], [ac_system_error_4=no])
|
||||||
|
])
|
||||||
|
AC_MSG_RESULT($ac_system_error_4)
|
||||||
|
if test x"$ac_system_error_4" = x"yes"; then
|
||||||
|
AC_DEFINE(HAVE_EPROTO, 1, [Define if EPROTO exists.])
|
||||||
|
fi
|
||||||
|
|
||||||
AC_MSG_CHECKING([for sys_nerr])
|
AC_MSG_CHECKING([for sys_nerr])
|
||||||
AC_CACHE_VAL(ac_system_error3, [
|
AC_CACHE_VAL(ac_system_error3, [
|
||||||
AC_TRY_COMPILE([#include <errno.h> ], [ int i = sys_nerr; ],
|
AC_TRY_COMPILE([#include <errno.h> ], [ int i = sys_nerr; ],
|
||||||
|
|
|
@ -63,12 +63,18 @@
|
||||||
/* Define to 1 if you have the <endian.h> header file. */
|
/* Define to 1 if you have the <endian.h> header file. */
|
||||||
#undef HAVE_ENDIAN_H
|
#undef HAVE_ENDIAN_H
|
||||||
|
|
||||||
|
/* Define if ENOLINK exists. */
|
||||||
|
#undef HAVE_ENOLINK
|
||||||
|
|
||||||
/* Define if ENOTRECOVERABLE exists. */
|
/* Define if ENOTRECOVERABLE exists. */
|
||||||
#undef HAVE_ENOTRECOVERABLE
|
#undef HAVE_ENOTRECOVERABLE
|
||||||
|
|
||||||
/* Define if EOWNERDEAD exists. */
|
/* Define if EOWNERDEAD exists. */
|
||||||
#undef HAVE_EOWNERDEAD
|
#undef HAVE_EOWNERDEAD
|
||||||
|
|
||||||
|
/* Define if EPROTO exists. */
|
||||||
|
#undef HAVE_EPROTO
|
||||||
|
|
||||||
/* Define to 1 if you have the `expf' function. */
|
/* Define to 1 if you have the `expf' function. */
|
||||||
#undef HAVE_EXPF
|
#undef HAVE_EXPF
|
||||||
|
|
||||||
|
|
|
@ -16661,6 +16661,134 @@ _ACEOF
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
echo "$as_me:$LINENO: checking for ENOLINK" >&5
|
||||||
|
echo $ECHO_N "checking for ENOLINK... $ECHO_C" >&6
|
||||||
|
if test "${ac_system_error3+set}" = set; then
|
||||||
|
echo $ECHO_N "(cached) $ECHO_C" >&6
|
||||||
|
else
|
||||||
|
|
||||||
|
cat >conftest.$ac_ext <<_ACEOF
|
||||||
|
/* confdefs.h. */
|
||||||
|
_ACEOF
|
||||||
|
cat confdefs.h >>conftest.$ac_ext
|
||||||
|
cat >>conftest.$ac_ext <<_ACEOF
|
||||||
|
/* end confdefs.h. */
|
||||||
|
#include <errno.h>
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
int i = ENOLINK;
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
_ACEOF
|
||||||
|
rm -f conftest.$ac_objext
|
||||||
|
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||||
|
(eval $ac_compile) 2>conftest.er1
|
||||||
|
ac_status=$?
|
||||||
|
grep -v '^ *+' conftest.er1 >conftest.err
|
||||||
|
rm -f conftest.er1
|
||||||
|
cat conftest.err >&5
|
||||||
|
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||||
|
(exit $ac_status); } &&
|
||||||
|
{ ac_try='test -z "$ac_c_werror_flag"
|
||||||
|
|| test ! -s conftest.err'
|
||||||
|
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||||
|
(eval $ac_try) 2>&5
|
||||||
|
ac_status=$?
|
||||||
|
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||||
|
(exit $ac_status); }; } &&
|
||||||
|
{ ac_try='test -s conftest.$ac_objext'
|
||||||
|
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||||
|
(eval $ac_try) 2>&5
|
||||||
|
ac_status=$?
|
||||||
|
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||||
|
(exit $ac_status); }; }; then
|
||||||
|
ac_system_error3=yes
|
||||||
|
else
|
||||||
|
echo "$as_me: failed program was:" >&5
|
||||||
|
sed 's/^/| /' conftest.$ac_ext >&5
|
||||||
|
|
||||||
|
ac_system_error3=no
|
||||||
|
fi
|
||||||
|
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "$as_me:$LINENO: result: $ac_system_error3" >&5
|
||||||
|
echo "${ECHO_T}$ac_system_error3" >&6
|
||||||
|
if test x"$ac_system_error3" = x"yes"; then
|
||||||
|
|
||||||
|
cat >>confdefs.h <<\_ACEOF
|
||||||
|
#define HAVE_ENOLINK 1
|
||||||
|
_ACEOF
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "$as_me:$LINENO: checking for EPROTO" >&5
|
||||||
|
echo $ECHO_N "checking for EPROTO... $ECHO_C" >&6
|
||||||
|
if test "${ac_system_error_4+set}" = set; then
|
||||||
|
echo $ECHO_N "(cached) $ECHO_C" >&6
|
||||||
|
else
|
||||||
|
|
||||||
|
cat >conftest.$ac_ext <<_ACEOF
|
||||||
|
/* confdefs.h. */
|
||||||
|
_ACEOF
|
||||||
|
cat confdefs.h >>conftest.$ac_ext
|
||||||
|
cat >>conftest.$ac_ext <<_ACEOF
|
||||||
|
/* end confdefs.h. */
|
||||||
|
#include <errno.h>
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
int i = EPROTO;
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
_ACEOF
|
||||||
|
rm -f conftest.$ac_objext
|
||||||
|
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
|
||||||
|
(eval $ac_compile) 2>conftest.er1
|
||||||
|
ac_status=$?
|
||||||
|
grep -v '^ *+' conftest.er1 >conftest.err
|
||||||
|
rm -f conftest.er1
|
||||||
|
cat conftest.err >&5
|
||||||
|
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||||
|
(exit $ac_status); } &&
|
||||||
|
{ ac_try='test -z "$ac_c_werror_flag"
|
||||||
|
|| test ! -s conftest.err'
|
||||||
|
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||||
|
(eval $ac_try) 2>&5
|
||||||
|
ac_status=$?
|
||||||
|
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||||
|
(exit $ac_status); }; } &&
|
||||||
|
{ ac_try='test -s conftest.$ac_objext'
|
||||||
|
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
|
||||||
|
(eval $ac_try) 2>&5
|
||||||
|
ac_status=$?
|
||||||
|
echo "$as_me:$LINENO: \$? = $ac_status" >&5
|
||||||
|
(exit $ac_status); }; }; then
|
||||||
|
ac_system_error_4=yes
|
||||||
|
else
|
||||||
|
echo "$as_me: failed program was:" >&5
|
||||||
|
sed 's/^/| /' conftest.$ac_ext >&5
|
||||||
|
|
||||||
|
ac_system_error_4=no
|
||||||
|
fi
|
||||||
|
rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "$as_me:$LINENO: result: $ac_system_error_4" >&5
|
||||||
|
echo "${ECHO_T}$ac_system_error_4" >&6
|
||||||
|
if test x"$ac_system_error_4" = x"yes"; then
|
||||||
|
|
||||||
|
cat >>confdefs.h <<\_ACEOF
|
||||||
|
#define HAVE_EPROTO 1
|
||||||
|
_ACEOF
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
echo "$as_me:$LINENO: checking for sys_nerr" >&5
|
echo "$as_me:$LINENO: checking for sys_nerr" >&5
|
||||||
echo $ECHO_N "checking for sys_nerr... $ECHO_C" >&6
|
echo $ECHO_N "checking for sys_nerr... $ECHO_C" >&6
|
||||||
if test "${ac_system_error3+set}" = set; then
|
if test "${ac_system_error3+set}" = set; then
|
||||||
|
@ -16767,7 +16895,7 @@ ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
|
||||||
|
|
||||||
# Fake what AC_TRY_COMPILE does. XXX Look at redoing this new-style.
|
# Fake what AC_TRY_COMPILE does. XXX Look at redoing this new-style.
|
||||||
cat > conftest.$ac_ext << EOF
|
cat > conftest.$ac_ext << EOF
|
||||||
#line 16770 "configure"
|
#line 16898 "configure"
|
||||||
int main()
|
int main()
|
||||||
{
|
{
|
||||||
// NB: _Atomic_word not necessarily int.
|
// NB: _Atomic_word not necessarily int.
|
||||||
|
|
|
@ -93,7 +93,9 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
|
||||||
network_unreachable = ENETUNREACH,
|
network_unreachable = ENETUNREACH,
|
||||||
no_buffer_space = ENOBUFS,
|
no_buffer_space = ENOBUFS,
|
||||||
no_child_process = ECHILD,
|
no_child_process = ECHILD,
|
||||||
|
#ifdef _GLIBCXX_HAVE_ENOLINK
|
||||||
no_link = ENOLINK,
|
no_link = ENOLINK,
|
||||||
|
#endif
|
||||||
no_lock_available = ENOLCK,
|
no_lock_available = ENOLCK,
|
||||||
no_message_available = ENODATA,
|
no_message_available = ENODATA,
|
||||||
no_message = ENOMSG,
|
no_message = ENOMSG,
|
||||||
|
@ -119,7 +121,9 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
|
||||||
owner_dead = EOWNERDEAD,
|
owner_dead = EOWNERDEAD,
|
||||||
#endif
|
#endif
|
||||||
permission_denied = EACCES,
|
permission_denied = EACCES,
|
||||||
|
#ifdef _GLIBCXX_HAVE_EPROTO
|
||||||
protocol_error = EPROTO,
|
protocol_error = EPROTO,
|
||||||
|
#endif
|
||||||
protocol_not_supported = EPROTONOSUPPORT,
|
protocol_not_supported = EPROTONOSUPPORT,
|
||||||
read_only_file_system = EROFS,
|
read_only_file_system = EROFS,
|
||||||
resource_deadlock_would_occur = EDEADLK,
|
resource_deadlock_would_occur = EDEADLK,
|
||||||
|
|
|
@ -50,7 +50,7 @@ int main()
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
// { dg-error "is private" "" { target *-*-* } 162 }
|
// { dg-error "is private" "" { target *-*-* } 166 }
|
||||||
// { dg-error "within this context" "" { target *-*-* } 29 }
|
// { dg-error "within this context" "" { target *-*-* } 29 }
|
||||||
// { dg-error "first required here" "" { target *-*-* } 48 }
|
// { dg-error "first required here" "" { target *-*-* } 48 }
|
||||||
// { dg-excess-errors "copy constructor" }
|
// { dg-excess-errors "copy constructor" }
|
||||||
|
|
|
@ -67,7 +67,11 @@ namespace gnu
|
||||||
using std::network_unreachable;
|
using std::network_unreachable;
|
||||||
using std::no_buffer_space;
|
using std::no_buffer_space;
|
||||||
using std::no_child_process;
|
using std::no_child_process;
|
||||||
|
|
||||||
|
#ifdef _GLIBCXX_HAVE_ENOLINK
|
||||||
using std::no_link;
|
using std::no_link;
|
||||||
|
#endif
|
||||||
|
|
||||||
using std::no_lock_available;
|
using std::no_lock_available;
|
||||||
using std::no_message_available;
|
using std::no_message_available;
|
||||||
using std::no_message;
|
using std::no_message;
|
||||||
|
@ -96,7 +100,11 @@ namespace gnu
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
using std::permission_denied;
|
using std::permission_denied;
|
||||||
|
|
||||||
|
#ifdef _GLIBCXX_HAVE_EPROTO
|
||||||
using std::protocol_error;
|
using std::protocol_error;
|
||||||
|
#endif
|
||||||
|
|
||||||
using std::protocol_not_supported;
|
using std::protocol_not_supported;
|
||||||
using std::read_only_file_system;
|
using std::read_only_file_system;
|
||||||
using std::resource_deadlock_would_occur;
|
using std::resource_deadlock_would_occur;
|
||||||
|
|
Loading…
Reference in New Issue