diff options
author | Steve Hay <SteveHay@planit.com> | 2005-10-05 15:34:18 +0000 |
---|---|---|
committer | Steve Hay <SteveHay@planit.com> | 2005-10-05 15:34:18 +0000 |
commit | bb275e7208fde6cd3835f1057d07fa69e22b40a4 (patch) | |
tree | 9b44c354b7e71b88fbe16201f231a362564bfbeb /win32 | |
parent | 44f8325f4c9b3aaf24b47f4da7dce3e8170dcf42 (diff) | |
download | perl-bb275e7208fde6cd3835f1057d07fa69e22b40a4.tar.gz |
Fix $Config{ccflags} for Win32 perls built with dmake
The nmake makefile (win32/Makefile) currently adds -nologo, $(STRPOOL)
and -W3 to the ccflags in CFG_VARS, but the dmake makefile
(win32/makefile.mk) doesn't. This means that extensions built with
perls built with VC++ and dmake spit out damn M$ logo messages and use
a lower warning level.
The reason for the difference is probably that the dmake makefile
supports multiple compilers. Therefore, put the extra ccflags into a
new macro, and set it appropriately for each compiler. Add the new
macro to the nmake makefile too for orthogonality.
p4raw-id: //depot/perl@25694
Diffstat (limited to 'win32')
-rw-r--r-- | win32/Makefile | 5 | ||||
-rw-r--r-- | win32/makefile.mk | 7 |
2 files changed, 8 insertions, 4 deletions
diff --git a/win32/Makefile b/win32/Makefile index e66ef740f2..c4c41d8202 100644 --- a/win32/Makefile +++ b/win32/Makefile @@ -443,7 +443,8 @@ LIBBASEFILES = $(LIBBASEFILES) odbc32.lib odbccp32.lib # we add LIBC here, since we may be using PerlCRT.dll LIBFILES = $(LIBBASEFILES) $(LIBC) -CFLAGS = -nologo $(STRPOOL) -W3 $(INCLUDES) $(DEFINES) $(LOCDEFS) \ +EXTRACFLAGS = -nologo $(STRPOOL) -W3 +CFLAGS = $(EXTRACFLAGS) $(INCLUDES) $(DEFINES) $(LOCDEFS) \ $(PCHFLAGS) $(OPTIMIZE) LINK_FLAGS = -nologo -nodefaultlib $(LINK_DBG) \ -libpath:"$(INST_COREDIR)" \ @@ -864,7 +865,7 @@ CFG_VARS = \ "archname=$(ARCHNAME)" \ "cc=$(CC)" \ "ld=$(LINK32)" \ - "ccflags=-nologo $(STRPOOL) -W3 $(OPTIMIZE:"=\") $(DEFINES) $(BUILDOPT)" \ + "ccflags=$(EXTRACFLAGS) $(OPTIMIZE:"=\") $(DEFINES) $(BUILDOPT)" \ "cf_email=$(EMAIL)" \ "d_crypt=$(D_CRYPT)" \ "d_mymalloc=$(PERL_MALLOC)" \ diff --git a/win32/makefile.mk b/win32/makefile.mk index a08afe1af1..c05b4a1f5a 100644 --- a/win32/makefile.mk +++ b/win32/makefile.mk @@ -404,6 +404,7 @@ OPTIMIZE = -O2 -D_RTLDLL LINK_DBG = .ENDIF +EXTRACFLAGS = CFLAGS = -w -g0 -tWM -tWD $(INCLUDES) $(DEFINES) $(LOCDEFS) \ $(PCHFLAGS) $(OPTIMIZE) LINK_FLAGS = $(LINK_DBG) -L"$(INST_COREDIR)" -L"$(CCLIBDIR)" \ @@ -460,6 +461,7 @@ OPTIMIZE = -s -O2 LINK_DBG = -s .ENDIF +EXTRACFLAGS = CFLAGS = $(INCLUDES) $(DEFINES) $(LOCDEFS) $(OPTIMIZE) LINK_FLAGS = $(LINK_DBG) -L"$(INST_COREDIR)" -L"$(CCLIBDIR)" OBJOUT_FLAG = -o @@ -552,7 +554,8 @@ LIBBASEFILES += odbc32.lib odbccp32.lib # we add LIBC here, since we may be using PerlCRT.dll LIBFILES = $(LIBBASEFILES) $(LIBC) -CFLAGS = -nologo $(STRPOOL) -W3 $(INCLUDES) $(DEFINES) $(LOCDEFS) \ +EXTRACFLAGS = -nologo $(STRPOOL) -W3 +CFLAGS = $(EXTRACFLAGS) $(INCLUDES) $(DEFINES) $(LOCDEFS) \ $(PCHFLAGS) $(OPTIMIZE) LINK_FLAGS = -nologo -nodefaultlib $(LINK_DBG) \ -libpath:"$(INST_COREDIR)" \ @@ -903,7 +906,7 @@ CFG_VARS = \ archname=$(ARCHNAME) ~ \ cc=$(CC) ~ \ ld=$(LINK32) ~ \ - ccflags=$(OPTIMIZE) $(DEFINES) $(BUILDOPT) ~ \ + ccflags=$(EXTRACFLAGS) $(OPTIMIZE) $(DEFINES) $(BUILDOPT) ~ \ cf_email=$(EMAIL) ~ \ d_crypt=$(D_CRYPT) ~ \ d_mymalloc=$(PERL_MALLOC) ~ \ |