From stolz@i2.informatik.rwth-aachen.de  Thu Oct 30 04:14:49 2003
Return-Path: <stolz@i2.informatik.rwth-aachen.de>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 6F86316A4CE
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 30 Oct 2003 04:14:49 -0800 (PST)
Received: from atlas.informatik.rwth-aachen.de (atlas.Informatik.RWTH-Aachen.DE [137.226.194.2])
	by mx1.FreeBSD.org (Postfix) with ESMTP id CF78743FAF
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 30 Oct 2003 04:14:47 -0800 (PST)
	(envelope-from stolz@i2.informatik.rwth-aachen.de)
Received: from menelaos.informatik.rwth-aachen.de (menelaos.Informatik.RWTH-Aachen.DE [137.226.194.73])
	by atlas.informatik.rwth-aachen.de (8.11.3/8.11.3/SuSE Linux 8.11.1-0.5-michaelw-20030918) with ESMTP id h9UCEie15319
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 30 Oct 2003 13:14:44 +0100
Received: (from stolz@localhost)
	by menelaos.informatik.rwth-aachen.de (8.12.9p2/8.12.9/Submit) id h9UCEkjv011755;
	Thu, 30 Oct 2003 13:14:46 +0100 (CET)
	(envelope-from stolz)
Message-Id: <200310301214.h9UCEkjv011755@menelaos.informatik.rwth-aachen.de>
Date: Thu, 30 Oct 2003 13:14:46 +0100 (CET)
From: Volker Stolz <stolz@i2.informatik.rwth-aachen.de>
Reply-To: Volker Stolz <stolz@i2.informatik.rwth-aachen.de>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: [patch] Unbreak x11-wm/fvwm95 on GCC3
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         58719
>Category:       ports
>Synopsis:       [patch] Unbreak x11-wm/fvwm95 on GCC3
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Oct 30 04:20:11 PST 2003
>Closed-Date:    Fri Oct 31 23:48:05 PST 2003
>Last-Modified:  Fri Oct 31 23:48:05 PST 2003
>Originator:     Volker Stolz
>Release:        FreeBSD 4.9-RC i386
>Organization:
Lehrstuhl fr Informatik II
>Environment:
System: FreeBSD menelaos.informatik.rwth-aachen.de 4.9-RC FreeBSD 4.9-RC #10: Tue Oct 7 12:32:25 CEST 2003 root@menelaos.informatik.rwth-aachen.de:/usr/obj/usr/src/sys/MENELAOS i386


>Description:
Fix gcc3-issues regarding ## in cpp. gcc33 now does the Right Thing
anyway.

Noticed by: bento
Tested on: -STABLE, gcc & gcc33
>How-To-Repeat:
>Fix:
Add new patch file patch-modules-FvwmIconMan-FvwmIconMan.c:
--- fvwm95 begins here ---
--- modules/FvwmIconMan/FvwmIconMan.c.orig	Thu Oct 30 12:53:01 2003
+++ modules/FvwmIconMan/FvwmIconMan.c	Thu Oct 30 13:10:36 2003
@@ -315,6 +315,23 @@
     return copy_string (s1, s2);
 }
 
+#if __GNUC__ > 2
+#define SET_MANAGER(manager,field,value)                           \
+   do {                                                            \
+     int id = manager;                                             \
+     if (id == -1) {                                               \
+       for (id = 0; id < globals.num_managers; id++) {             \
+	 globals.managers[id].field = value;                     \
+       }                                                           \
+     }                                                             \
+     else if (id < globals.num_managers) {                         \
+       globals.managers[id].field = value;                       \
+     }                                                             \
+     else {                                                        \
+       ConsoleMessage ("Internal error in SET_MANAGER: %d\n", id); \
+     }                                                             \
+   } while (0)
+#else 
 #define SET_MANAGER(manager,field,value)                           \
    do {                                                            \
      int id = manager;                                             \
@@ -330,6 +347,7 @@
        ConsoleMessage ("Internal error in SET_MANAGER: %d\n", id); \
      }                                                             \
    } while (0)
+#endif /* GCC 2 */
 
 static void read_in_resources (char *file)
 {
--- fvwm95 ends here ---


>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: glewis 
State-Changed-When: Fri Oct 31 23:47:51 PST 2003 
State-Changed-Why:  
Committed, thanks! 

http://www.freebsd.org/cgi/query-pr.cgi?pr=58719 
>Unformatted:
