This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Subject: [patch] PR 30058, inline fixincludes for NetBSD 4.x


Krister Walfridsson wrote:
> The attached patch fix the remaining C99 inline lossage for NetBSD
> (This applies to NetBSD 4.x; a similar fix for NetBSD 2.x and 3.x was
> committed in March).
> 
> Bootstrapped and tested on i386-unknown-netbsdelf4.0.
> 
> OK to commit?

With a formatting change.  All computer screens are the width of a
hollerith card (80 characters).

Thanks. - Bruce
Index: inclhack.def
===================================================================
--- inclhack.def	(revision 126823)
+++ inclhack.def	(working copy)
@@ -2608,6 +2608,25 @@ fix = {
 };
 
 
+fix = {
+    hackname  = netbsd_c99_inline_2;
+    mach      = *-*-netbsd*;
+    files     = signal.h;
+    select    = "#define _SIGINLINE extern __inline";
+
+    c_fix     = format;
+    c_fix_arg = <<- _EOArg_
+	#ifdef __GNUC_STDC_INLINE__
+	#define _SIGINLINE extern __attribute__((__gnu_inline__)) __inline
+	#else
+	%0
+	#endif
+	_EOArg_;
+
+    test_text = "#define _SIGINLINE extern __inline";
+};
+
+
 /*
  * NetBSD has a semicolon after the ending '}' for some extern "C".
  */
Index: tests/base/signal.h
===================================================================
--- tests/base/signal.h	(revision 126823)
+++ tests/base/signal.h	(working copy)
@@ -18,3 +18,12 @@ __inline int
 sigaddset(sigset_t *set, int signo)
 {}
 #endif  /* NETBSD_C99_INLINE_1_CHECK */
+
+
+#if defined( NETBSD_C99_INLINE_2_CHECK )
+#ifdef __GNUC_STDC_INLINE__
+#define _SIGINLINE extern __attribute__((__gnu_inline__)) __inline
+#else
+#define _SIGINLINE extern __inline
+#endif
+#endif  /* NETBSD_C99_INLINE_2_CHECK */

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]