File nethack-WINCHAIN-a-framework-allowing-multiple-processors-be.patch of Package nethack
From 7f6ee2f7598029570bb1cc671d51d67de7e0cfa6 Mon Sep 17 00:00:00 2001
From: keni <keni>
Date: Wed, 11 Jan 2012 18:23:35 +0000
Subject: [PATCH] WINCHAIN - a framework allowing multiple processors between
core and winport This is the code I built trying to figure out the large
window size issue. It completely compiles out if not needed (see -DWINCHAIN
in hints/macos10.7) and except for one call during setup has zero overhead if
compiled in and not used. See window.doc for more info.
Defs for UNUSED parms. I know this has been controversial, so use is isolated
to the chain code and windows.c (where it shouldn't be intrusive and saves about
50 warnings).
Hints file for 10.7, but the build process still needs to be migrated from
the branch.
Backporting notes:
- Only take UNUSED from upstream
---
include/tradstdc.h | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
Index: nethack-3.4.3/include/tradstdc.h
===================================================================
--- nethack-3.4.3.orig/include/tradstdc.h
+++ nethack-3.4.3/include/tradstdc.h
@@ -263,11 +263,18 @@ typedef genericptr genericptr_t; /* (voi
*/
#ifdef __GNUC__
# if __GNUC__ >= 2
-#define PRINTF_F(f,v) __attribute__ ((format (printf, f, v)))
+# define PRINTF_F(f,v) __attribute__ ((format (printf, f, v)))
+# endif
+# if __GNUC__ >= 3
+# define UNUSED __attribute__ ((unused))
# endif
#endif
+
#ifndef PRINTF_F
-#define PRINTF_F(f,v)
+# define PRINTF_F(f,v)
+#endif
+#ifndef UNUSED
+# define UNUSED
#endif
#endif /* TRADSTDC_H */