* ntdef.h: Remove extern qualifier from FORCEINLINE define for GNUC

This breaks static FORCEINLINE functions, for example in LAME 3.99:
FORCEINLINE static  float vec_max_c(const float * xr34, unsigned int bw)

* winnt.h: Bring duplicate FORCEINLINE definition in sync with ntdef.h

-- 
Rafaël Carré
Index: mingw-w64-headers/include/winnt.h
===================================================================
--- mingw-w64-headers/include/winnt.h	(révision 4571)
+++ mingw-w64-headers/include/winnt.h	(copie de travail)
@@ -146,11 +146,16 @@
 #endif
 #endif /* DECLSPEC_NOINLINE */
 
+/* Inlines */
 #ifndef FORCEINLINE
-#if !defined(_MSC_VER) || (_MSC_VER >=1200)
+#if defined(_MSC_VER) && (_MSC_VER >= 1200)
 #define FORCEINLINE __forceinline
-#else
+#elif defined(_MSC_VER)
 #define FORCEINLINE __inline
+#elif defined(__cplusplus) /* __GNUG__ */
+#define FORCEINLINE inline __attribute__((always_inline))
+#else /* __GNUC__ */
+#define FORCEINLINE __inline__ __attribute__((always_inline))
 #endif
 #endif /* FORCEINLINE */
 
Index: mingw-w64-headers/include/ntdef.h
===================================================================
--- mingw-w64-headers/include/ntdef.h	(révision 4571)
+++ mingw-w64-headers/include/ntdef.h	(copie de travail)
@@ -206,7 +206,7 @@
 #elif defined(__cplusplus) /* __GNUG__ */
 #define FORCEINLINE inline __attribute__((always_inline))
 #else /* __GNUC__ */
-#define FORCEINLINE extern __inline__ __attribute__((always_inline))
+#define FORCEINLINE __inline__ __attribute__((always_inline))
 #endif
 #endif /* FORCEINLINE */
 
------------------------------------------------------------------------------
RSA(R) Conference 2012
Save $700 by Nov 18
Register now
http://p.sf.net/sfu/rsa-sfdev2dev1
_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to