# HG changeset patch # User jld # Date 1048095543 0 # Node ID 8bf039d894d81ac61441d1e7a84f9cace773d7f1 # Parent fa9a9d22a594e841abf56a60fe29fd480b3f2699 * standalone/wxwin/appsettings.cpp, standalone/wxwin/makefile.gnu, standalone/wxwin/configtooldoc.cpp, standalone/wxwin/ecpch.h, standalone/wxwin/filename.cpp, standalone/wxwin/configtool.rc: Allow configtool to build against wxWindows 2.4.0 using Cygwin GCC. diff --git a/host/tools/configtool/ChangeLog b/host/tools/configtool/ChangeLog --- a/host/tools/configtool/ChangeLog +++ b/host/tools/configtool/ChangeLog @@ -1,3 +1,13 @@ +2003-03-19 John Dallaway + + * standalone/wxwin/appsettings.cpp, + standalone/wxwin/configtooldoc.cpp, + standalone/wxwin/ecpch.h, + standalone/wxwin/filename.cpp, + standalone/wxwin/configtool.rc, + standalone/wxwin/makefile.gnu: Allow configtool to build against + wxWindows 2.4.0 using Cygwin GCC. + 2003-03-18 John Dallaway * standalone/wxwin/appsettings.cpp, diff --git a/host/tools/configtool/standalone/wxwin/appsettings.cpp b/host/tools/configtool/standalone/wxwin/appsettings.cpp --- a/host/tools/configtool/standalone/wxwin/appsettings.cpp +++ b/host/tools/configtool/standalone/wxwin/appsettings.cpp @@ -75,7 +75,7 @@ #ifdef __WXMSW__ #include #include "wx/msw/winundef.h" -#if defined(GetTempPath) && !defined(__CYGWIN__) +#ifdef GetTempPath #undef GetTempPath #endif #endif diff --git a/host/tools/configtool/standalone/wxwin/configtool.rc b/host/tools/configtool/standalone/wxwin/configtool.rc --- a/host/tools/configtool/standalone/wxwin/configtool.rc +++ b/host/tools/configtool/standalone/wxwin/configtool.rc @@ -44,4 +44,4 @@ text ICON "bitmaps/t text_dis ICON "bitmaps/text_dis.ico" #include "wx/msw/wx.rc" -//#include "wx/html/msw/wxhtml.rc" + diff --git a/host/tools/configtool/standalone/wxwin/configtooldoc.cpp b/host/tools/configtool/standalone/wxwin/configtooldoc.cpp --- a/host/tools/configtool/standalone/wxwin/configtooldoc.cpp +++ b/host/tools/configtool/standalone/wxwin/configtooldoc.cpp @@ -73,7 +73,7 @@ #include #endif #include "wx/msw/winundef.h" -#if defined(CreateDirectory) && !defined(__CYGWIN__) +#ifdef CreateDirectory #undef CreateDirectory #endif #endif diff --git a/host/tools/configtool/standalone/wxwin/ecpch.h b/host/tools/configtool/standalone/wxwin/ecpch.h --- a/host/tools/configtool/standalone/wxwin/ecpch.h +++ b/host/tools/configtool/standalone/wxwin/ecpch.h @@ -51,9 +51,12 @@ #endif // include winsock2.h early to eliminate fd_set warning -#ifdef __CYGWIN__ -#include -#endif +// FIXME: including winsock2.h early causes build failures +// relating to the CreateDialog macro defined in the w32api. +// Need to find a better point to #include +//#ifdef __CYGWIN__ +//#include +//#endif #include "wx/wx.h" #include "wx/splitter.h" diff --git a/host/tools/configtool/standalone/wxwin/filename.cpp b/host/tools/configtool/standalone/wxwin/filename.cpp --- a/host/tools/configtool/standalone/wxwin/filename.cpp +++ b/host/tools/configtool/standalone/wxwin/filename.cpp @@ -48,7 +48,6 @@ #include #include "wx/msw/winundef.h" -#ifndef __CYGWIN__ #ifdef CreateDirectory #undef CreateDirectory #endif @@ -64,7 +63,6 @@ #ifdef GetTempPath #undef GetTempPath #endif -#endif #else diff --git a/host/tools/configtool/standalone/wxwin/makefile.gnu b/host/tools/configtool/standalone/wxwin/makefile.gnu --- a/host/tools/configtool/standalone/wxwin/makefile.gnu +++ b/host/tools/configtool/standalone/wxwin/makefile.gnu @@ -27,8 +27,8 @@ EXTRALDFLAGS=-L$(TCLDIR)/lib -L$(INSTALL ifeq "$(OSTYPE)" "cygwin" PROGRAM=configtool.exe - CPPFLAGS=-I$(WXDIR)/include -I$(WXDIR)/lib/wx/include -DSTRICT -DWINVER=0x0400 -D_WIN32 -D__GNUWIN32__ -D__WIN95__ -D__WIN32__ -D_X86_=1 -DWIN32 - LDFLAGS=-L$(WXDIR)/lib -lwx -lstdc++ -lwinspool -lwinmm -lshell32 -lcomctl32 -lctl3d32 -ladvapi32 -lwsock32 -lglu32 -lgdi32 -lcomdlg32 -lole32 -luuid -lshlwapi -lpng -lzlib + CPPFLAGS=`$(WXDIR)/bin/wx-config --cppflags` -D_WIN32 -D__WIN32__ -DSTRICT + LDFLAGS=`$(WXDIR)/bin/wx-config --libs` -lshlwapi EXTRAOBJECTS=$(CTBUILDDIR)/configtoolres.o else PROGRAM=configtool @@ -118,7 +118,7 @@ install: $(CTBUILDDIR)/$(PROGRAM) $(CC) $(CPPDEBUGOPTIONS) -c $(EXTRACPPFLAGS) $(CPPFLAGS) -o $@ $< $(CTBUILDDIR)/configtoolres.o: $(CTDIR)/configtool.rc - $(RESCOMP) -i $< -o $@ --preprocessor "$(CC) -c -E -xc-header -DRC_INVOKED" --include-dir $(WXDIR)/include --include-dir $(CTDIR) --define __WIN32__ --define __WIN95__ --define __GNUWIN32__ + $(RESCOMP) -i $< -o $@ --preprocessor "$(CC) -c -E -xc-header -DRC_INVOKED" --include-dir $(WXDIR)/include --include-dir $(CTDIR) --define __GNUWIN32__ clean: rm -f $(CTBUILDDIR)/$(PROGRAM) $(CTBUILDDIR)/*.o