X-Git-Url: https://git.hcoop.net/bpt/emacs.git/blobdiff_plain/8a1f4a98c1b8e3abaf1b46394a88d09531ce4c2d..0566bc954097aae81a0efda950c4567be3139c23:/nt/nmake.defs diff --git a/nt/nmake.defs b/nt/nmake.defs index a771f1df5d..ec6f5102f4 100644 --- a/nt/nmake.defs +++ b/nt/nmake.defs @@ -1,6 +1,5 @@ # -*- Makefile -*- definition file for building GNU Emacs on Windows NT. -# Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, -# 2008, 2009, 2010, 2011 Free Software Foundation, Inc. +# Copyright (C) 2000-2012 Free Software Foundation, Inc. # This file is part of GNU Emacs. @@ -28,6 +27,7 @@ MAKETYPE=nmake CURDIR = $(MAKEDIR:\=/) THISDIR = $(MAKEDIR) +DIRNAME = ALL_DEPS = $** @@ -110,7 +110,15 @@ RC = rc RC_OUT = -Fo RC_INCLUDE = -i -libc = libc.lib +USE_CRT_DLL = 1 + +!ifdef USE_CRT_DLL +libc = msvcrt$(D).lib +EMACS_EXTRA_C_FLAGS= -D_DLL -D_MT -DUSE_CRT_DLL=1 +!else +libc = libcmt$(D).lib +EMACS_EXTRA_C_FLAGS= -D_MT +!endif baselibs = O = obj A = lib @@ -137,17 +145,19 @@ DEBUG_CFLAGS = -DEMACSDEBUG DEBUG_CFLAGS = !endif -!ifdef ENABLECHECKS -CHECKING_CFLAGS = -DENABLE_CHECKING -DXASSERTS -!else -CHECKING_CFLAGS = -!endif +MWINDOWS = -subsystem:windows -entry:mainCRTStartup CFLAGS = -I. $(ARCH_CFLAGS) \ - $(DEBUG_CFLAGS) $(CHECKING_CFLAGS) $(USER_CFLAGS) $(LOCAL_FLAGS) -EMACS_EXTRA_C_FLAGS = + $(DEBUG_CFLAGS) $(USER_CFLAGS) $(LOCAL_FLAGS) +ESC_CFLAGS = -I. $(ARCH_CFLAGS) \ + $(DEBUG_CFLAGS) $(ESC_USER_CFLAGS) $(LOCAL_FLAGS) -SYS_LDFLAGS = -nologo -release -incremental:no -version:3.10 -swaprun:cd -swaprun:net setargv.obj +#SYS_LDFLAGS = -nologo -release -incremental:no -version:3.10 -swaprun:cd -swaprun:net setargv.obj +!ifdef NOOPT +SYS_LDFLAGS = -nologo -manifest -dynamicbase:no -debug -incremental:no -version:3.10 -swaprun:cd -swaprun:net setargv.obj +!else +SYS_LDFLAGS = -nologo -manifest -dynamicbase:no -release -incremental:no -version:3.10 -swaprun:cd -swaprun:net setargv.obj +!endif # see comments in allocate_heap in w32heap.c before changing any of the # -stack, -heap, or -base settings. @@ -168,7 +178,7 @@ COMPILER_TEMP_FILES = *.pdb CP = cp -f CP_DIR = cp -rf -IFNOTSAMEDIR = if not exist ..\same-dir.tst +IFNOTSAMEDIR = if not exist ..\$(DIRNAME)_same-dir.tst ENDIF = FOREACH = for %%f in ( FORVAR = %%f @@ -183,16 +193,23 @@ DEL_TREE = rm -r !ifdef NODEBUG DEBUG_FLAG = DEBUG_LINK = +D = !else DEBUG_FLAG = -Zi -DEBUG_LINK = -debug:full +DEBUG_LINK = -debug +D = d !endif +# gcc-specific pragma (ignore for MSVC) +PRAGMA_SYSTEM_HEADER = + !if "$(ARCH)" == "i386" !ifdef NOOPT -ARCH_CFLAGS = -nologo -c -Zel -W2 -H63 -Od -G3d -Zp8 $(DEBUG_FLAG) +#ARCH_CFLAGS = -nologo -c -Zel -W2 -H63 -Od -G3d -Zp8 $(DEBUG_FLAG) +ARCH_CFLAGS = -nologo -D_X86_=1 -c -Zl -Zp8 -W2 -Od -Gd $(DEBUG_FLAG) !else -ARCH_CFLAGS = -nologo -c -Zel -W2 -H63 -Oxsb2 -Oy- -G6dF -Zp8 $(DEBUG_FLAG) +#ARCH_CFLAGS = -nologo -c -Zel -W2 -H63 -Oxsb2 -Oy- -G6dF -Zp8 $(DEBUG_FLAG) +ARCH_CFLAGS = -nologo -D_X86_=1 -c -Zl -Zp8 -W2 -Oi -Ot -Oy- -Ob2 -GF -Gy -Gd $(DEBUG_FLAG) !endif ARCH_LDFLAGS = $(SYS_LDFLAGS) @@ -246,4 +263,3 @@ EXTRA_LINK = -profile $(CC) $(CFLAGS) -Fo$(BLD)\ $< !ENDIF -# arch-tag: fefa49b0-c23c-46c7-9094-cab2a405058e