--- mstools/h/ntwin32.mak 2018/08/09 18:23:08 1.1.1.2 +++ mstools/h/ntwin32.mak 2018/08/09 18:25:27 1.1.1.3 @@ -47,8 +47,13 @@ CPUTYPE = 1 CPUTYPE = 2 !ENDIF +# Digital Alpha AXP systems +!IF "$(CPU)" == "ALPHA" +CPUTYPE = 3 +!ENDIF + !IFNDEF CPUTYPE -!ERROR Must specify CPU environment variable ( CPU=i386 or CPU=MIPS ) +!ERROR Must specify CPU environment variable ( CPU=i386, CPU=MIPS, CPU=ALPHA) !ENDIF # ------------------------------------------------------------------------- @@ -73,6 +78,13 @@ cc = mcl cvtobj = REM !!! CVTOBJ is no longer necessary - please remove !!! !ENDIF +# binary declarations for use on self hosted Digital Alpha AXP systems +!IF "$(CPU)" == "ALPHA" +cc = claxp +# for compatibility with older-style makefiles +cvtobj = REM !!! CVTOBJ is no longer necessary - please remove !!! +!ENDIF + # binary declarations common to all platforms link = link32 implib = lib32 @@ -89,8 +101,8 @@ hc = hc # and global variables. # # Both compilers now use the same front end - you must still define either -# _X86_ or _MIPS_. These have replaced the i386 and MIPS definitions which -# are not ANSI compliant. +# _X86_, _MIPS_, or _ALPHA_. These have replaced the i386, MIPS, and ALPHA +# definitions which are not ANSI compliant. # # Common compiler flags: # -c - compile without linking @@ -138,10 +150,16 @@ hc = hc ccommon = -c -W3 !IF "$(CPU)" == "i386" -cflags = $(ccommon) -D_X86_=1 +cflags = $(ccommon) -D_X86_=1 -D_CRTAPI1=__cdecl -D_CRTAPI2=__cdecl -Dtry=__try -Dleave=__leave -Dexcept=__except -Dfinally=__finally scall = -Gz !ELSE +!IF "$(CPU)" == "MIPS" cflags = $(ccommon) -D_MIPS_=1 +!ELSE +!IF "$(CPU)" == "ALPHA" +cflags = $(ccommon) -D_ALPHA_=1 +!ENDIF +!ENDIF scall = !ENDIF @@ -176,8 +194,8 @@ cdebug = -Zi -Od # of a EXE and/or DLL target object. The appropriate compiler flag macros # that should be used for each combination are also listed. # -# Link EXE Create Exe Link DLL Create DLL -# with Using with Using +# Link EXE Create Exe Link DLL Create DLL +# with Using with Using # ---------------------------------------------------- # LIBC CVARS None None * # LIBC CVARS LIBC CVARS @@ -192,6 +210,13 @@ cdebug = -Zi -Od # # * - Denotes the Recommended Configuration # +# When building single-threaded applications you can link your executable +# with either LIBC, LIBCMT, or CRTDLL, although LIBC will provide the best +# performance. +# +# When building multi-threaded applications, either LIBCMT or CRTDLL can +# be used as the C-Runtime library, as both are multi-thread safe. +# # Note: Any executable which accesses a DLL linked with CRTDLL.LIB must # also link with CRTDLL.LIB instead of LIBC.LIB or LIBCMT.LIB. # When using DLLs, it is recommended that all of the modules be @@ -213,7 +238,7 @@ cvarsmt = $(cvars) -D_MT cvarsdll = $(cvarsmt) -D_DLL # for compatibility with older-style makefiles -cvarsdll = $(cvarsmt) -D_DLL +cvarsmtdll = $(cvarsmt) -D_DLL # for POSIX applications psxvars = -D_POSIX_ @@ -250,6 +275,12 @@ lflags = $(lcommon) -align:0x1000 DLLENTRY = lflags = $(lcommon) !ENDIF + +# declarations for use on self hosted Digital Alpha AXP systems +!IF "$(CPU)" == "ALPHA" +DLLENTRY = +lflags = $(lcommon) +!ENDIF # ------------------------------------------------------------------------- # Target Module Dependent Link Debug Flags - must be specified after $(link)