Changed BidEndianOrdered to BigEndianOrdered in datstrm.h
Seek and Tell do the right thing in wxIn/OutputStream now Check for GNU extension in configure.in: this is needed for GLIBC 2.1/GCC 2.95 -> this enables _GNU_SOURCE git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@3293 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
d7cb14cec9
commit
60b6c062f8
@ -53,6 +53,7 @@
|
||||
#undef __ULTRIX__
|
||||
#undef __DATA_GENERAL__
|
||||
#undef __EMX__
|
||||
#undef _GNU_SOURCE
|
||||
|
||||
#undef __WINDOWS__
|
||||
#undef __WIN95__
|
||||
|
24
acinclude.m4
24
acinclude.m4
@ -397,3 +397,27 @@ AC_DEFUN(WX_ARG_ENABLE,
|
||||
fi
|
||||
])
|
||||
|
||||
dnl -
|
||||
dnl - GNU libc extension (added by GL)
|
||||
dnl -
|
||||
|
||||
AC_DEFUN(WX_GNU_EXTENSIONS,
|
||||
[
|
||||
AC_MSG_CHECKING([if you need GNU extensions])
|
||||
AC_CACHE_VAL(wx_cv_gnu_extensions,[
|
||||
AC_TRY_COMPILE([#include <features.h>],[
|
||||
|
||||
#ifndef __GNU_LIBRARY__
|
||||
Compile error wanted
|
||||
#endif
|
||||
|
||||
],
|
||||
[wx_cv_gnu_extensions=yes],
|
||||
[wx_cv_gnu_extensions=no])
|
||||
])
|
||||
|
||||
AC_MSG_RESULT($wx_cv_gnu_extensions)
|
||||
if test "$wx_cv_gnu_extensions" = "yes"; then
|
||||
AC_DEFINE_UNQUOTED(_GNU_SOURCE)
|
||||
fi
|
||||
])
|
||||
|
@ -1250,6 +1250,9 @@ WX_CPP_BOOL
|
||||
dnl check whether overloading on size_t/int parameter works
|
||||
WX_CPP_SIZE_T_IS_NOT_INT
|
||||
|
||||
dnl check whether we should define _GNU_SOURCE
|
||||
WX_GNU_EXTENSIONS
|
||||
|
||||
dnl ---------------------------------------------------------------------------
|
||||
dnl Check for functions
|
||||
dnl ---------------------------------------------------------------------------
|
||||
|
@ -41,7 +41,7 @@ public:
|
||||
wxDataInputStream& operator>>(double& i);
|
||||
wxDataInputStream& operator>>(float& f);
|
||||
|
||||
void BidEndianOrdered(bool be_order) { m_be_order = be_order; }
|
||||
void BigEndianOrdered(bool be_order) { m_be_order = be_order; }
|
||||
protected:
|
||||
wxInputStream *m_input;
|
||||
bool m_be_order;
|
||||
@ -69,7 +69,7 @@ class WXDLLEXPORT wxDataOutputStream {
|
||||
wxDataOutputStream& operator<<(double f);
|
||||
wxDataOutputStream& operator<<(float f);
|
||||
|
||||
void BidEndianOrdered(bool be_order) { m_be_order = be_order; }
|
||||
void BigEndianOrdered(bool be_order) { m_be_order = be_order; }
|
||||
protected:
|
||||
wxOutputStream *m_output;
|
||||
bool m_be_order;
|
||||
|
@ -574,12 +574,12 @@ wxInputStream& wxInputStream::Read(wxOutputStream& stream_out)
|
||||
|
||||
off_t wxInputStream::SeekI(off_t pos, wxSeekMode mode)
|
||||
{
|
||||
return wxInvalidOffset;
|
||||
return OnSysSeek(pos, mode);
|
||||
}
|
||||
|
||||
off_t wxInputStream::TellI() const
|
||||
{
|
||||
return wxInvalidOffset;
|
||||
return OnSysTell();
|
||||
}
|
||||
|
||||
// --------------------
|
||||
@ -622,12 +622,12 @@ wxOutputStream& wxOutputStream::Write(wxInputStream& stream_in)
|
||||
|
||||
off_t wxOutputStream::TellO() const
|
||||
{
|
||||
return wxInvalidOffset;
|
||||
return OnSysTell();
|
||||
}
|
||||
|
||||
off_t wxOutputStream::SeekO(off_t pos, wxSeekMode mode)
|
||||
{
|
||||
return wxInvalidOffset;
|
||||
return OnSysSeek(pos, mode);
|
||||
}
|
||||
|
||||
void wxOutputStream::Sync()
|
||||
|
@ -626,7 +626,7 @@ if (socket->m_iocalls[event] && \
|
||||
new_ival.it_interval.tv_sec = socket->m_timeout / 1000; \
|
||||
new_ival.it_interval.tv_usec = (socket->m_timeout % 1000) * 1000; \
|
||||
setitimer(ITIMER_REAL, &new_ival, &old_ival); \
|
||||
old_timer_sig = signal(SIGALRM, _GSocket_Timer);
|
||||
old_timer_sig = signal(SIGALRM, SIG_DFL);
|
||||
|
||||
#define DISABLE_TIMEOUT(socket) \
|
||||
signal(SIGALRM, old_timer_sig); \
|
||||
|
Loading…
Reference in New Issue
Block a user