// check if to use precompiled headers: do it for most Windows compilers unless
// adding DigitalMars here appears to amke it slower!
// explicitly disabled by defining NOPCH
-#if ((defined(__BORLANDC__) || defined(__VISUALC__) || defined(__WATCOMC__)) && defined(__WXMSW__)) || defined(__VISAGECPP__) || defined(__MWERKS__)
+#if ((defined(__BORLANDC__) || defined(__VISUALC__) || defined(__DIGITALMARS__) || defined(__WATCOMC__)) && defined(__WXMSW__)) || defined(__VISAGECPP__) || defined(__MWERKS__)
#if !defined(NOPCH)
#define WX_PRECOMP
#endif
-# Symantec C++ makefile
-WXDIR = ..\..
-EXTRALIBS=
+#Makefile from wxHatch for Symantec/Digital Mars compiler
+WXDIR=..\..\..\wxWindows.25
TARGET=dialogs
-OBJECTS = $(TARGET).obj
+OBJECTS = $(TARGET).obj
+EXTRALIBS =
include $(WXDIR)\src\makeprog.sc
-
}
#if defined(__WXMSW__)
-#ifdef __DIGITALMARS__
-extern "C"
-#endif
+
size_t wxDataObjectComposite::GetBufferOffset( const wxDataFormat& format )
{
wxDataObjectSimple *dataObj = GetObject(format);
return dataObj->GetBufferOffset( format );
}
-#ifdef __DIGITALMARS__
-extern "C"
-#endif
+
const void* wxDataObjectComposite::GetSizeFromBuffer( const void* buffer,
size_t* size,
const wxDataFormat& format )
return dataObj->GetSizeFromBuffer( buffer, size, format );
}
-#ifdef __DIGITALMARS__
-extern "C"
-#endif
+
void* wxDataObjectComposite::SetSizeInBuffer( void* buffer, size_t size,
const wxDataFormat& format )
{
// This causes a conflict with jmorecfg.h header from libjpeg, so we have
// to make sure libjpeg won't try to define boolean itself. This is done by
// defining HAVE_BOOLEAN.
-#if defined(__WXMSW__) && (defined(__MWERKS__) || (defined(__WATCOMC__) && __WATCOMC__ < 1200))
+#if defined(__WXMSW__) && (defined(__MWERKS__) || defined(__DIGITALMARS__) || (defined(__WATCOMC__) && __WATCOMC__ < 1200))
#define HAVE_BOOLEAN
#include <windows.h>
#endif
SC_SUFFIX=_sc
####WXDIR = $(WXWIN)
+WXOUTDIR=$(WXDIR)\d_mars
INCDIR = $(WXDIR)\include
CONTRIBINCDIR = $(WXDIR)\contrib\include
MSWINCDIR = $(WXDIR)\include\wx\msw
# WIN32 settings
# -H ... fix to use directory
-CFLAGS = -o -mn -W -H -D__NT__ -DWIN32 -D__WIN32__ -D__WIN95__ -D__WINDOWS__ -D__WXMSW__ -D__SC__ -D__WXDEBUG__ $(EXTRACPPFLAGS)
+##CFLAGS = -o -mn -W -H -D__NT__ -DWIN32 -D__WIN32__ -D__WIN95__ -D__WINDOWS__ -D__WXMSW__ -D__SC__ -D__WXDEBUG__ $(EXTRACPPFLAGS)
+CFLAGS = -mn -D_WINDOWS -6 -a8 -Nc -c -H -HD$(WXOUTDIR) -HO- -DWXMSW -D__WIN32__ -D__WIN95__ -D__WXDEBUG__ $(EXTRACPPFLAGS)
+CPPFLAGS = -cpp -Ae -Ar
+
LINKER = link
# possible bug with putting d on any extralibs if we have debug and release versions one day
LDFLAGS = $(EXTRALDFLAGS)
.$(SRCSUFF).obj:
- *$(CC) -c $(CFLAGS) $(INCLUDE) $(OPTIONS) $< -o$@
+ *$(CC) -c $(CPPFLAGS) $(CFLAGS) $(INCLUDE) $(OPTIONS) $< -o$@
# -Jm: relaxed type checking only for .C files
.c.obj:
HBRUSH wxDisableButtonBrush = (HBRUSH) 0;
-#ifdef __DIGITALMARS__
-extern "C" LRESULT WXDLLEXPORT APIENTRY wxWndProc(HWND, UINT, WPARAM, LPARAM);
-#else
LRESULT WXDLLEXPORT APIENTRY wxWndProc(HWND, UINT, WPARAM, LPARAM);
-#endif
// FIXME wxUSE_ON_FATAL_EXCEPTION is only supported for VC++ now because it
// needs compiler support for Win32 SEH. Others (especially Borland)
}
}
-#ifdef __DIGITALMARS__
-extern "C" HGLOBAL wxDIB::ConvertFromBitmap(HBITMAP hbmp);
-#endif
-
bool wxSetClipboardData(wxDataFormat dataFormat,
const void *data,
}
/* static */
-#ifdef __DIGITALMARS__
-extern "C"
-#endif
HGLOBAL wxDIB::ConvertFromBitmap(HBITMAP hbmp)
{
// first calculate the size needed
# Add $(NONESSENTIALOBJS) if wanting generic dialogs, PostScript etc.
OBJECTS = $(COMMONOBJS) $(GENERICOBJS) $(MSWOBJS) $(HTMLOBJS)
-all: MAKEARCHDIR MAKELIBS $(LIBTARGET) zlib png jpeg tiff regex
+all: MAKEARCHDIR MAKELIBS PCH $(LIBTARGET) zlib png jpeg tiff regex
MAKEARCHDIR:
@if not exist $(MSWINCDIR)\setup.h copy $(MSWINCDIR)\setup0.h $(MSWINCDIR)\setup.h
@if not exist $(ARCHINCDIR)\wx\setup.h mkdir $(ARCHINCDIR)
@if not exist $(ARCHINCDIR)\wx\setup.h mkdir $(ARCHINCDIR)\wx
@if not exist $(ARCHINCDIR)\wx\setup.h copy $(MSWINCDIR)\setup.h $(ARCHINCDIR)\wx\setup.h
+ @if not exist $(WXOUTDIR)\nul mkdir $(WXOUTDIR)
#build our own copies of missing libraries
MAKELIBS:
-del $(LIBTARGET)
*lib /PAGESIZE:512 $(LIBTARGET) y $(OBJECTS), nul;
-clean: clean_msw clean_zlib clean_png clean_jpeg clean_tiff clean_regex
+clean: clean_msw clean_zlib clean_png clean_jpeg clean_tiff clean_regex clean_pch
clean_msw:
-del $(COMMDIR)\*.obj
-del ole\*.obj
-del $(LIBTARGET)
+PCH: $(INCDIR)\wx\wxprec.h
+ dmc $(CPPFLAGS) $(CFLAGS) $(INCLUDE) -HF$(WXOUTDIR)\wxprec.SYM -o$(WXOUTDIR)\wxprec.PCO $(INCDIR)\wx\wxprec.h
+
+clean_pch:
+ del $(WXOUTDIR)\*.sym
+ del $(WXOUTDIR)\*.PCO
+
png:
make -f $(WXDIR)\src\png\makefile.sc FINAL=$(FINAL)
extern const wxChar *wxMDIFrameClassName; // from app.cpp
extern const wxChar *wxMDIChildFrameClassName;
extern const wxChar *wxMDIChildFrameClassNameNoRedraw;
-#ifdef __DIGITALMARS__
-extern "C" void wxAssociateWinWithHandle(HWND hWnd, wxWindow *win);
-#else
extern void wxAssociateWinWithHandle(HWND hWnd, wxWindow *win);
-#endif
extern void wxRemoveHandleAssociation(wxWindow *win);
static HWND invalidHandle = 0;
return S_OK;
}
-#ifdef __DIGITALMARS__
-extern "C"
-size_t wxDataObjectComposite::GetBufferOffset( const wxDataFormat& format );
-
-extern "C"
-const void* wxDataObjectComposite::GetSizeFromBuffer( const void* buffer,
- size_t* size,
- const wxDataFormat& format ) ;
-extern "C"
-void* wxDataObjectComposite::SetSizeInBuffer( void* buffer, size_t size,
- const wxDataFormat& format ) ;
-
-#endif
// set data functions
STDMETHODIMP wxIDataObject::SetData(FORMATETC *pformatetc,
static HCURSOR gs_wxBusyCursorOld = 0; // old cursor
static int gs_wxBusyCursorCount = 0;
-#ifdef __DIGITALMARS__
-extern "C" HCURSOR wxGetCurrentBusyCursor()
-#else
extern HCURSOR wxGetCurrentBusyCursor()
-#endif
{
return gs_wxBusyCursor;
}
// ---------------------------------------------------------------------------
// the window proc for all our windows
-#ifdef __DIGITALMARS__
-extern "C" LRESULT WXDLLEXPORT APIENTRY _EXPORT wxWndProc(HWND hWnd, UINT message,
- WPARAM wParam, LPARAM lParam);
-#else
LRESULT WXDLLEXPORT APIENTRY _EXPORT wxWndProc(HWND hWnd, UINT message,
WPARAM wParam, LPARAM lParam);
-#endif
#ifdef __WXDEBUG__
#endif //__WXDEBUG__
void wxRemoveHandleAssociation(wxWindowMSW *win);
-#ifdef __DIGITALMARS__
-extern "C" void wxAssociateWinWithHandle(HWND hWnd, wxWindowMSW *win);
-#else
extern void wxAssociateWinWithHandle(HWND hWnd, wxWindowMSW *win);
-#endif
wxWindow *wxFindWinFromHandle(WXHWND hWnd);
// this magical function is used to translate VK_APPS key presses to right
long wxWindowMSW::MSWDefWindowProc(WXUINT nMsg, WXWPARAM wParam, WXLPARAM lParam)
{
if ( m_oldWndProc )
-#ifdef __DIGITALMARS__
- return ::CallWindowProc( (FARPROC) m_oldWndProc, GetHwnd(), (UINT) nMsg, (WPARAM) wParam, (LPARAM) lParam);
-#else
return ::CallWindowProc(CASTWNDPROC m_oldWndProc, GetHwnd(), (UINT) nMsg, (WPARAM) wParam, (LPARAM) lParam);
-#endif
else
return ::DefWindowProc(GetHwnd(), nMsg, wParam, lParam);
}
#endif
}
-#ifdef __DIGITALMARS__
-extern "C" HCURSOR wxGetCurrentBusyCursor();
-#endif
bool wxWindowMSW::HandleSetCursor(WXHWND WXUNUSED(hWnd),
short nHitTest,
*/
#ifndef MACOS
# if (defined(__MWERKS__) && defined(macintosh)) || defined(applec) || \
- defined(THINK_C) || defined(__SC__) || defined(TARGET_OS_MAC)
+ defined(THINK_C) || (defined(__SC__) && !defined(__DMC__))|| defined(TARGET_OS_MAC)
# define MACOS
# endif
#endif
#endif
/* Some Mac compilers merge all .h files incorrectly: */
-#if defined(__MWERKS__) || defined(applec) ||defined(THINK_C) ||defined(__SC__)
+#if defined(__MWERKS__) || defined(applec) ||defined(THINK_C) ||(defined(__SC__) && !defined(__DMC__))
# define NO_DUMMY_DECL
#endif