[ANNOUNCEMENT] Server Test 95

Ralf Habacker Ralf.Habacker@freenet.de
Mon Aug 4 19:18:00 GMT 2003


Hi,

there is a little problem with gcc 2.95.x. In some files I've got a compiling
error like mentioned below:

wingc.c: In function `winValidateGCNativeGDI':
wingc.c:155: parse error before `fDebugProcMsg'
wingc.c:156: `fDebugProcMsg' undeclared (first use in this function)
wingc.c:156: (Each undeclared identifier is reported only once
wingc.c:156: for each function it appears in.)
make: *** [wingc.o] Error 1

The reason is, that gcc2 is not able to deal with variable definitions after
code in a function. A workaround is to change the lines

-  DEBUG_FN_NAME("winSetSpans");
-  DEBUGVARS;
-  DEBUGPROC_MSG;

into

+  DEBUGVARS;
+  DEBUG_FN_NAME("winSetSpans");
+  DEBUGPROC_MSG;

Cheers

Ralf

Changelog
2003-08-04		Ralf Habacker <ralf.habacker@freenet.de>

	* winfillsp.c(winFillSpansNativeGDI),
	* wingc.c(winValidateGCNativeGDI),
	* winsetsp.c(winSetSpansNativeGDI): fix gcc2
      compiling problems.


----------------------------------------------------------------------------
diff -up xwin95_org/winfillsp.c xwin95/winfillsp.c
--- xwin95_org/winfillsp.c      2003-07-31 00:34:53.000000000 +0200
+++ xwin95/winfillsp.c  2003-08-04 10:01:24.000000000 +0200
@@ -56,8 +56,8 @@ winFillSpansNativeGDI (DrawablePtr    pDraw
   HDC                  hdcStipple = NULL;
   BYTE                 *pbbitsFilledStipple = NULL;
   int                  iX;
-  DEBUG_FN_NAME("winFillSpans");
   DEBUGVARS;
+  DEBUG_FN_NAME("winFillSpans");
   DEBUGPROC_MSG;

   /* Branch on the type of drawable we have */
diff -up xwin95_org/wingc.c xwin95/wingc.c
--- xwin95_org/wingc.c  2003-07-31 00:34:54.000000000 +0200
+++ xwin95/wingc.c      2003-08-04 10:01:28.000000000 +0200
@@ -151,8 +151,8 @@ winValidateGCNativeGDI (GCPtr pGC,
   PixmapPtr            pStipple = NULL;
   winPrivPixmapPtr     pStipplePriv = NULL;
   int                  i;
-  DEBUG_FN_NAME("winValidateGC");
   DEBUGVARS;
+  DEBUG_FN_NAME("winValidateGC");
   DEBUGPROC_MSG;

   /* Branch on drawable type */
diff -up xwin95_org/winsetsp.c xwin95/winsetsp.c
--- xwin95_org/winsetsp.c       2003-07-31 00:34:54.000000000 +0200
+++ xwin95/winsetsp.c   2003-08-04 10:01:50.000000000 +0200
@@ -52,8 +52,8 @@ winSetSpansNativeGDI (DrawablePtr     pDrawa
   BITMAPINFOHEADER     *pbmih;
   HBITMAP              hBitmap = NULL;
   HBITMAP              hbmpOrig = NULL;
-  DEBUG_FN_NAME("winSetSpans");
   DEBUGVARS;
+  DEBUG_FN_NAME("winSetSpans");
   DEBUGPROC_MSG;

   /* Branch on the drawable type */




More information about the Cygwin-xfree mailing list