-XPMOBJECTS = $(XPMDIR)/crbuffri.o\
- $(XPMDIR)/crdatfri.o\
- $(XPMDIR)/create.o $(XPMDIR)/crifrbuf.o\
- $(XPMDIR)/crifrdat.o\
- $(XPMDIR)/data.o\
- $(XPMDIR)/hashtab.o $(XPMDIR)/misc.o\
- $(XPMDIR)/parse.o $(XPMDIR)/rdftodat.o\
- $(XPMDIR)/rdftoi.o\
- $(XPMDIR)/rgb.o $(XPMDIR)/scan.o\
- $(XPMDIR)/simx.o $(XPMDIR)/wrffrdat.o\
- $(XPMDIR)/wrffrp.o $(XPMDIR)/wrffri.o
-
-OBJECTS = $(MSWOBJS) $(COMMONOBJS) $(GENERICOBJS) $(HTMLOBJS) \
- $(JPEGOBJS) $(PNGOBJS) $(ZLIBOBJS) # $(XPMOBJECTS)
-
-all: $(OBJECTS) $(WXLIB)
+TIFFOBJS = $(TIFFDIR)/tif_aux.o \
+ $(TIFFDIR)/tif_close.o \
+ $(TIFFDIR)/tif_codec.o \
+ $(TIFFDIR)/tif_compress.o \
+ $(TIFFDIR)/tif_dir.o \
+ $(TIFFDIR)/tif_dirinfo.o \
+ $(TIFFDIR)/tif_dirread.o \
+ $(TIFFDIR)/tif_dirwrite.o \
+ $(TIFFDIR)/tif_dumpmode.o \
+ $(TIFFDIR)/tif_error.o \
+ $(TIFFDIR)/tif_fax3.o \
+ $(TIFFDIR)/tif_fax3sm.o \
+ $(TIFFDIR)/tif_flush.o \
+ $(TIFFDIR)/tif_getimage.o \
+ $(TIFFDIR)/tif_jpeg.o \
+ $(TIFFDIR)/tif_luv.o \
+ $(TIFFDIR)/tif_lzw.o \
+ $(TIFFDIR)/tif_next.o \
+ $(TIFFDIR)/tif_open.o \
+ $(TIFFDIR)/tif_packbits.o \
+ $(TIFFDIR)/tif_pixarlog.o \
+ $(TIFFDIR)/tif_predict.o \
+ $(TIFFDIR)/tif_print.o \
+ $(TIFFDIR)/tif_read.o \
+ $(TIFFDIR)/tif_strip.o \
+ $(TIFFDIR)/tif_swab.o \
+ $(TIFFDIR)/tif_thunder.o \
+ $(TIFFDIR)/tif_tile.o \
+ $(TIFFDIR)/tif_version.o \
+ $(TIFFDIR)/tif_warning.o \
+ $(TIFFDIR)/tif_win32.o \
+ $(TIFFDIR)/tif_write.o \
+ $(TIFFDIR)/tif_zip.o
+
+ifeq "$(strip $(RECENT_MINGW))" "yes"
+ OBJECTS = $(MSWOBJS) $(COMMONOBJS) $(GENERICOBJS) $(HTMLOBJS) $(DIRDLGOBJ) $(ADVANCEDOBJS)
+else
+ OBJECTS = $(MSWOBJS) $(COMMONOBJS) $(GENERICOBJS) $(HTMLOBJS) $(DIRDLGOBJ)
+endif
+ifeq ($(wxUSE_GUI),0)
+ OBJECTS = $(MSWOBJS_BASE) $(COMMONOBJS_BASE) $(COMMONOBJS_BASEONLY) $(GENERICOBJS_BASE)
+endif
+
+# how do you do "VAR=\" ? BLEAGH!
+BACKSLASH=$(subst a,\,a)
+ifeq (,$(findstring $(OSTYPE),"cygwin!msys"))
+ PATH_SEPARATOR:=$(BACKSLASH)
+ PATH_SUBST=/
+else
+ PATH_SEPARATOR=/
+ PATH_SUBST:=$(BACKSLASH)
+endif
+
+#ARCHINCDIR=$(subst $(PATH_SUBST),$(PATH_SEPARATOR),$(WXDIR)/lib/msw$(INCEXT))
+ARCHINCDIR=$(WXDIR)/lib/$(TOOLKIT)$(INCEXT)
+
+SETUP_H=$(ARCHINCDIR)/wx/setup.h
+
+ifndef WXMAKINGDLL
+all: $(SETUP_H) $(OBJECTS) $(WXLIB) $(ZLIBLIB) $(PNGLIB) $(JPEGLIB) $(TIFFLIB) $(REGEXLIB)
+else
+all: $(SETUP_H) $(OBJECTS) $(ZLIBLIB) $(PNGLIB) $(JPEGLIB) $(TIFFLIB) $(REGEXLIB) $(WXDLL)
+endif
+
+$(ARCHINCDIR)/wx:
+ mkdir $(subst $(PATH_SUBST),$(PATH_SEPARATOR),$(ARCHINCDIR))
+ mkdir $(subst $(PATH_SUBST),$(PATH_SEPARATOR),$(ARCHINCDIR)/wx)
+
+# Copy ALWAYS uses forward slashes now.
+
+$(SETUP_H): $(ARCHINCDIR)/wx $(WXDIR)/include/wx/msw/setup.h
+ $(COPY) $(WXDIR)/include/wx/msw/setup.h $(subst $(BACKSLASH),/,$@)
+
+# $(COPY) $(WXDIR)/include/wx/msw/setup.h $@
+# $(COPY) $(subst $(PATH_SUBST),$(PATH_SEPARATOR),$(WXDIR)/include/wx/msw/setup.h) $(subst $(PATH_SUBST),$(PATH_SEPARATOR),$@)
+
+ifndef WXMAKINGDLL