Fix for 687739, msvc32.mak overwrites CFLAGS

Alex Cherepanov <[email protected]> Thu, 07 Oct 2004 02:26:31 -0400
Newsgroups gmane.comp.printing.ghostscript.patches
Organization Coscript Software
Message-ID <[email protected]>
Don't overwrite CFLAGS variable if it is already defined.
Bug 687739

_______________________________________________
gs-code-review mailing list
[email protected]
http://www.ghostscript.com/mailman/listinfo/gs-code-review
687739.diff (text/plain, 926 B)
Index: gs/src/msvc32.mak
===================================================================
RCS file: /cvs/ghostscript/gs/src/msvc32.mak,v
retrieving revision 1.63
diff -b -u -r1.63 msvc32.mak
--- gs/src/msvc32.mak	26 Sep 2004 16:19:27 -0000	1.63
+++ gs/src/msvc32.mak	7 Oct 2004 06:14:50 -0000
@@ -255,6 +255,12 @@
 IJSEXECTYPE=win
 !endif
 
+# Define any other compilation flags.
+
+!ifndef CFLAGS
+CFLAGS=
+!endif
+
 # 1 --> Use 64 bits for gx_color_index.  This is required only for
 # non standard devices or DeviceN process color model devices.
 USE_LARGE_COLOR_INDEX=1
@@ -264,13 +270,7 @@
 LARGEST_UINTEGER_TYPE=unsigned __int64
 GX_COLOR_INDEX_TYPE=$(LARGEST_UINTEGER_TYPE)
 
-CFLAGS=/DGX_COLOR_INDEX_TYPE="$(GX_COLOR_INDEX_TYPE)"
-!endif
-
-# Define any other compilation flags.
-
-!ifndef CFLAGS
-CFLAGS=
+CFLAGS=$(CFLAGS) /DGX_COLOR_INDEX_TYPE="$(GX_COLOR_INDEX_TYPE)"
 !endif
 
 # -W3 generates too much noise.