Small fixes for compiling Cygwin (with --disable-sockets)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@32860 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -326,7 +326,7 @@ Metrowerks CodeWarrior compilation
|
|||||||
Cygwin/MinGW compilation
|
Cygwin/MinGW compilation
|
||||||
------------------------
|
------------------------
|
||||||
|
|
||||||
wxWidgets 2 supports Cygwin (formerly GnuWin32) betas and
|
wxWidgets supports Cygwin (formerly GnuWin32) betas and
|
||||||
releases, and MinGW. Cygwin can be downloaded from:
|
releases, and MinGW. Cygwin can be downloaded from:
|
||||||
|
|
||||||
http://sources.redhat.com/cygwin/
|
http://sources.redhat.com/cygwin/
|
||||||
@@ -339,6 +339,8 @@ Both Cygwin and MinGW can be used with configure (assuming you have MSYS
|
|||||||
installed in case of MinGW). You will need new enough MinGW version, preferably
|
installed in case of MinGW). You will need new enough MinGW version, preferably
|
||||||
MinGW 2.0 (ships with gcc3) or at least 1.0 (gcc-2.95.3). GCC versions older
|
MinGW 2.0 (ships with gcc3) or at least 1.0 (gcc-2.95.3). GCC versions older
|
||||||
than 2.95.3 don't work; you can use wxWidgets 2.4 with them.
|
than 2.95.3 don't work; you can use wxWidgets 2.4 with them.
|
||||||
|
If using Cygwin, you must pass --disable-sockets to configure due to a header
|
||||||
|
conflict in Cygwin.
|
||||||
|
|
||||||
NOTE: some notes specific to old Cygwin (< 1.1.x) are at the end of this
|
NOTE: some notes specific to old Cygwin (< 1.1.x) are at the end of this
|
||||||
section (see OLD VERSIONS)
|
section (see OLD VERSIONS)
|
||||||
|
@@ -23,7 +23,7 @@
|
|||||||
|
|
||||||
#include "wx/msw/wrapwin.h"
|
#include "wx/msw/wrapwin.h"
|
||||||
|
|
||||||
#ifdef __WXWINCE__
|
#if defined(__WXWINCE__)
|
||||||
#include <winsock.h>
|
#include <winsock.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@@ -282,7 +282,7 @@ public:
|
|||||||
virtual bool IsEditable() const = 0;
|
virtual bool IsEditable() const = 0;
|
||||||
|
|
||||||
// more readable flag testing methods
|
// more readable flag testing methods
|
||||||
bool IsSingleLine() const { return !(GetWindowStyle() & wxTE_MULTILINE); }
|
bool IsSingleLine() const { return !HasFlag(wxTE_MULTILINE); }
|
||||||
bool IsMultiLine() const { return !IsSingleLine(); }
|
bool IsMultiLine() const { return !IsSingleLine(); }
|
||||||
|
|
||||||
// If the return values from and to are the same, there is no selection.
|
// If the return values from and to are the same, there is no selection.
|
||||||
|
@@ -57,6 +57,7 @@
|
|||||||
|
|
||||||
#ifdef __WXMSW__
|
#ifdef __WXMSW__
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
|
#include "wx/msw/winundef.h"
|
||||||
|
|
||||||
// FIXME - Mingw32 1.0 has both _getdrive() and _chdrive(). For now, let's assume
|
// FIXME - Mingw32 1.0 has both _getdrive() and _chdrive(). For now, let's assume
|
||||||
// older releases don't, but it should be verified and the checks modified
|
// older releases don't, but it should be verified and the checks modified
|
||||||
|
@@ -45,6 +45,7 @@
|
|||||||
|
|
||||||
#ifdef __WXMSW__
|
#ifdef __WXMSW__
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
|
#include "wx/msw/winundef.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
|
@@ -48,6 +48,7 @@
|
|||||||
|
|
||||||
#ifdef __WXMSW__
|
#ifdef __WXMSW__
|
||||||
#include <windows.h> // for DLGC_WANTARROWS
|
#include <windows.h> // for DLGC_WANTARROWS
|
||||||
|
#include "wx/msw/winundef.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef __WXMOTIF__
|
#ifdef __WXMOTIF__
|
||||||
|
@@ -40,8 +40,8 @@
|
|||||||
#include "wx/msw/private.h" // includes <windows.h>
|
#include "wx/msw/private.h" // includes <windows.h>
|
||||||
#include "wx/msw/missing.h" // CHARSET_HANGUL
|
#include "wx/msw/missing.h" // CHARSET_HANGUL
|
||||||
|
|
||||||
#if defined(__GNUWIN32_OLD__) || defined(__WXWINCE__) \
|
// Doesn't work with Cygwin at present
|
||||||
|| defined(__CYGWIN32__)
|
#if wxUSE_SOCKETS && (defined(__GNUWIN32_OLD__) || defined(__WXWINCE__) || defined(__CYGWIN32__))
|
||||||
// apparently we need to include winsock.h to get WSADATA and other stuff
|
// apparently we need to include winsock.h to get WSADATA and other stuff
|
||||||
// used in wxGetFullHostName() with the old mingw32 versions
|
// used in wxGetFullHostName() with the old mingw32 versions
|
||||||
#include <winsock.h>
|
#include <winsock.h>
|
||||||
@@ -148,7 +148,7 @@ bool wxGetHostName(wxChar *buf, int maxSize)
|
|||||||
// get full hostname (with domain name if possible)
|
// get full hostname (with domain name if possible)
|
||||||
bool wxGetFullHostName(wxChar *buf, int maxSize)
|
bool wxGetFullHostName(wxChar *buf, int maxSize)
|
||||||
{
|
{
|
||||||
#if !defined( __WXMICROWIN__) && wxUSE_DYNAMIC_LOADER
|
#if !defined( __WXMICROWIN__) && wxUSE_DYNAMIC_LOADER && wxUSE_SOCKETS
|
||||||
// TODO should use GetComputerNameEx() when available
|
// TODO should use GetComputerNameEx() when available
|
||||||
|
|
||||||
// we don't want to always link with Winsock DLL as we might not use it at
|
// we don't want to always link with Winsock DLL as we might not use it at
|
||||||
|
Reference in New Issue
Block a user